Latest addon is not correct

in
Subscribe to Latest addon is not correct 1 post, 1 voice

yamahabest User
FirefoxWindows

The statement below is not correct. If milesToGo is less than 10, the newSpeed is set to 10, else the newSpeed is set to milesToGo. milesToGo can be way to fast for the truck!

//finally, check whether we are already within range of the destination to save fuel
if(milesToGo < 10) { newSpeed = 10} else { newSpeed = milesToGo };

It should be changed to this:

//finally, check whether we are already within range of the destination to save fuel
if(milesToGo < newSpeed) newSpeed = milesToGo;

//the newSpeed should not be less then 10. 10 is the lowest value accepted by Trukz.
if(newSpeed < 10) newSpeed = 10;

Cross
Presentational HTML allowed.
Use <code> for inline code and <pre> for code blocks. Use &lt; and &gt; for literal < and >.
We help break paragraphs and link your links.
or cancel