This site requires JavaScript, please enable it in your browser!
Greenfoot back

mjrb4's Comments

Back to mjrb4's profile

Not that bad! Unless you know Java pretty well already I wouldn't expect you to get most of them right, they're confusing deliberately!
You don't really need to use the vector class (you can, but personally I wouldn't implement it that way.) True it is trickier to implement realistic gravity, but it is possible - basically the method I use has involved using getObjectAtOffset to look "ahead" so to speak and restrict the movement if the object is just about to approach the ground. "great excuse for not having gravity" Of course Mars has gravity! Everything with mass does technically speaking, but Mars definitely has enough mass to have a noticeable amount of gravity. It's only about 38% of earth's, but it's still there!
What about the getColorAt / setColorAt methods in GreenfootImage? As long as the car colour is constant and isn't used in any other part of the picture (though you could alter it to a unique colour if that's not the case already) it'd be pretty trivial to loop through, check for a given colour and replace it with whatever colour you want. Unless my head's not working properly and there's some logic I'm missing!
One minor point, "power" seems a bit unclear as to what it means - it seems it determines acceleration, so would it be better labelled thus?
Nice! I haven't seen this game before but it looks well written and nicely playable. Good job :)
Oops. You'll definitely need that...!
Woah, it's quite fast! Any chance of including the speed slider so we can slow things down and look at what's happening more clearly? (If you want to include the speed slider, just un-check "lock scenario.")
mjrb4mjrb4

2009/5/7

Hi, You need to add objects in the world's constructor before you export it to the gallery, because we can't add them in the applet! If you're not sure how to go about doing it, have a look at this: http://www.greenfoot.org/greenroom/images/1/12/Adding_objects.pdf.
mjrb4mjrb4

2009/5/6

Nice game - a classic that's been rewritten simply but well!