Itâs hard not to start talking about turns when speed is discussed.
But it make things more complicated.
I will return to my original post I hope.
For now this is only about debug output X axis speed in wood 2 league.
I am also using 15% for friction. That is why I changed thrust from 85 to 88 so it wouldnât make things more confusing. And I didnât want to âspoilâ it for anyone.
And thrust 88 had the same situation to be discussed for the continuation of the original post.
When debug output calls it speed when itâs not, isnât that just a mistake?
Itâs printed in debug at a point when friction is added to it.
Itâs a preparation of speed before the next speed calculation.
So when next speed calculation is to be done, friction is already added and the game just adds thrust to it.
We canât move 88 at the speed of 74.
74 might be interesting for someone but speed must have been what was intended to print?
Consider friction a natural consequence of movements⌠Friction builds up while moving, so it happens during the current turn, not the next turn. And no matter you like it or not, this is the logic used by the game engine
Anyway, letâs not discuss whether it is right or wrong for the game engine to be coded that way. Letâs focus on playing the game based on the given rules.
And if you have done so, you will have the coordinates of all the checkpoints at the beginning. You have to store them for later use, because in this league, you are given the next checkpoint ID instead of the next checkpoint coordinates.
There is a bug in promotion. You may try submitting your code again, and if that still fails to promote you, please contact Thibaud of CodinGame to fix the issue for you.
I couldnât know how to beat the boss 2 in mad pod racing problem although i have followed the pseudo code as is, here is my code
...
if (nextCheckpointAngle > 90 || nextCheckpointAngle < -90)
{System.out.println(nextCheckpointX + " " + nextCheckpointY + "0");}
else
{System.out.println(nextCheckpointX + " " + nextCheckpointY + "100");}
// You have to output the target position
// followed by the power (0 <= thrust <= 100)
// i.e.: "x y thrust"
System.out.println(nextCheckpointX + " " + nextCheckpointY + " 80");
...end of class
You have missed the spaces before â0â and â100â. You should include add a space there, similar to how you include a space between nextCheckpointX and nextCheckpointY.
Hello,
I reached silver league . without using AI, but âordinaryâ code compensating drift and so , and I have 2 questions ?
Now I see than the angle parameter has changed , and I must be dumb or too tired because , I donât see how to use it ??
Second , do i need to code an AI to pass to gold league (in other words , did I missed the purpose of this challenge )?