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

Comments for Dodge

Return to Dodge

A new version of this scenario was uploaded on Thu Nov 10 02:37:00 UTC 2011 Made screen taller, added a background.
A new version of this scenario was uploaded on Thu Nov 10 02:37:56 UTC 2011 Made screen taller, added a background.
Royalblue64Royalblue64

2011/11/10

Great suggestions, here's the deal: - Any source code for a rock counter is great, I don't know how - The fact that the rocks don't spawn exactly at the top is intended, just the way I made the code makes this necessary - Health is a little bit beyond me at this point. I'm not that experienced and not enough people put up their source code :( ANY recommendations always welcome though :P
Mr.SandboxMr.Sandbox

2011/11/10

Possibly vertical movement? Maybe also different size rocks.
The123HammerThe123Hammer

2011/11/10

Great, this reminds me of Ragdoll Avalanche, but this one doesnt give you insulting comments when you lose
darkmist255darkmist255

2011/11/10

I've never done counters, but I'm sure it can't be too hard, I'll try it out some time. Health would be easy (once again, a health counter I don't know). Just add a variable: int healthLevel = 10; then under the function for where the guy gets hit with a rock: rockHit() { getNeighborblehbleh...(player) if { blah blah rock hit him healthLevel = (healthLevel - 1) if (healthLevel < 1) { game over blah... { } }
A new version of this scenario was uploaded on Mon Nov 14 21:45:20 UTC 2011 - Tweaked spawning for rocks - Made a dead guy picture for when you lose :P
A new version of this scenario was uploaded on Thu Nov 17 02:25:53 UTC 2011 Changed despawn time for Rocks, makes it look cooler.
A new version of this scenario was uploaded on Thu Nov 17 02:44:45 UTC 2011 Added simple falling physics to the rocks, so their speed increases as they fall.
A new version of this scenario was uploaded on Thu Nov 17 22:04:52 UTC 2011 Game came up with an error message when the page loaded, trying to republish to fix.
Royalblue64Royalblue64

2011/11/18

@Mr.Sandbox I made a version of this with vertical motion, but I published it as a different scenario called 'Dodge Flier'. In that game, you also have three lives.
A new version of this scenario was uploaded on Fri Nov 25 20:25:05 UTC 2011 Made Rocks a little faster.
A new version of this scenario was uploaded on Fri Nov 25 21:59:25 UTC 2011 - Changed the Character's look - Added a speed-boost
A new version of this scenario was uploaded on Sat Nov 26 20:01:31 UTC 2011 Added back the rocks that i accidentally deleted :P
rjl8789rjl8789

2011/11/28

Nice job! Could you complete the Acquarium one. I wouldd really like to see what I'm doing wrong. I have all the code done, but my fish don't move like I want them too!
Royalblue64Royalblue64

2011/11/29

@rjl8789 I published the simulation with the source, at the webpage http://www.greenfoot.org/scenarios/3855 I left comments in some classes explaining how it works. The classes that I did not put comments in were the Animal class second and third fish classes. The Animal class was not my creation, so try to understand that as best as you can. The first fish has comments, and you can understand the other fish with those.
Royalblue64Royalblue64

2011/12/6

Soon I'm going to be updating this scenario again with a scoreboard! Only problem is that I'm not 100% sure where on the screen I can put it... any suggestions?
darkmist255darkmist255

2011/12/6

Maybe just make a new World class for the scoreboard?
A new version of this scenario was uploaded on Wed Dec 07 00:57:59 UTC 2011 - Have lightning instead of rocks - Changed background picture - Made person get electrocuted when he dies
A new version of this scenario was uploaded on Wed Dec 07 00:59:31 UTC 2011 Changed screenshot
Royalblue64Royalblue64

2011/12/7

I think i got it... I'm looking to have the score up the whole game, but with this last update I made a space in the cloud that won't get blocked.
A new version of this scenario was uploaded on Wed Dec 07 23:12:58 UTC 2011 Added grounded lightning for when you die
A new version of this scenario was uploaded on Thu Dec 08 02:02:42 UTC 2011 Tried to change dying animations, migh break the game D: be prepared
A new version of this scenario was uploaded on Thu Dec 08 02:15:41 UTC 2011 Added Game Over pop-up - forgot to add this in last update :P
A new version of this scenario was uploaded on Fri Dec 09 01:26:56 UTC 2011 Changed the way the speedboost works, extra speed now temporary
A new version of this scenario was uploaded on Fri Dec 16 01:07:36 UTC 2011 Finally added a score counter! Yay!
cooldudecooldude

2011/12/16

whoop, high score of 183!!
Royalblue64Royalblue64

2011/12/16

@cooldude hehe you know, I basically had to become a pro at my own game so that I could test it properly, so that seems kinda funny to me :P
A new version of this scenario was uploaded on Fri Dec 16 02:38:35 UTC 2011 Added the "Red Zone" for the players who think they are too good for the game :P
Royalblue64Royalblue64

2011/12/16

Right now, I think I hold the record with: 1187 points
A new version of this scenario was uploaded on Fri Dec 16 03:10:25 UTC 2011 Made The Red Zone a little harder-sorry :P
A new version of this scenario was uploaded on Fri Dec 16 23:02:36 UTC 2011 - Changed the speed that the lightning falls at - Got rid of The Red Zone in favor of gradual build-up of difficulty - Added jumping with 'up' arrow key, speed burst now 'down' arrow key
A new version of this scenario was uploaded on Sun Dec 18 19:18:50 UTC 2011 - Changed jumping height - Added a flipping animation
DutaDuta

2011/12/18

@Royalblue64 yeah i had to do that with my new zombies game :P
Royalblue64Royalblue64

2011/12/19

my high score has dropped to 1055 in light of recent updates :P
Royalblue64Royalblue64

2011/12/19

Correction: high score 1100 If you want to see a video of me doing this, go to: http://www.youtube.com/watch?v=8CBrb49--zI
A new version of this scenario was uploaded on Mon Dec 19 20:28:29 UTC 2011 Added slow-motion power-ups (collect then use with spacebar)
A new version of this scenario was uploaded on Wed Dec 21 22:00:54 UTC 2011 Changed speed burst, you no longer slow down but have a constant speed for a short burst
A new version of this scenario was uploaded on Thu Dec 22 15:09:24 UTC 2011 Added lives, you have three lives. When you lose a life 200 points and all power-ups lost. Life counter at top
A new version of this scenario was uploaded on Sat Dec 24 00:19:30 UTC 2011 Changed score losses when you die to 10% of your score
jdemshkijdemshki

2011/12/25

how do you do the lives?
A new version of this scenario was uploaded on Sat Dec 31 23:27:14 UTC 2011 Added 1ups
A new version of this scenario was uploaded on Sun Jan 01 19:26:02 UTC 2012 Game now continues at a slower speed when you lose instead of stopping
A new version of this scenario was uploaded on Sun Jan 01 22:40:35 UTC 2012 - Made score counter more efficient - Added a no-edge function, toggleable - Fixed negative slow-motions glitch
Royalblue64Royalblue64

2012/1/8

For lives, you have to have a Counter class of some sort (at least in my experience). In the world class, you do the following: public MyWorld() { public Counter lifeCounter = new Counter("Lives: "); addObject(lifeCounter, x coordinate, y coordinate); } public Counter getLifeCounter() { return lifeCounter; } Now, with other classes you can use getLifeCounter to add and subtract. In the Counter class that I use, there is an add(int score) method, so if I was adding a life, I could do ((MyWorld)getWorld()).getLifeCounter().add(1); and that would add one. Also, if I lose a life, I would do ((MyWorld)getWorld()).getLifeCounter().add(-1); You can do this now from any other Actor you like. The key is the Counter class though.
Royalblue64Royalblue64

2012/1/8

Also, if you want to see the code, you can open it in Greenfoot at the top of the page
Royalblue64Royalblue64

2012/1/9

To see me make my current record score of 3482 points, go to: http://www.youtube.com/watch?v=iysfpl0kEaw
A new version of this scenario was uploaded on Thu Feb 02 04:58:09 UTC 2012 - Changed speed boost to ninja roll thing - Changed Lightning fall speed equation
Royalblue64Royalblue64

2015/8/9

Hello y'all, I haven't been active on this site for a while, but I recently took a look through the code for this game and almost vomited... So, I decided that I will remake this game following all the proper programming conventions to make the code as easy and sensible as possible.
A new version of this scenario was uploaded on 2015-11-20 06:55:36 UTC - Changed the sprite for the lightning to something much more appealing - SlowMotion power-ups no longer spawn while you are already in slow motion