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

JL235's Comments

Back to JL235's profile

>> This may be a bit random, but I love the new "This is mine!" button. :) Thank you!
@MathManiac: that's still not that high. At my personal site there is a version which includes a highscore board at:


There is more to it then this (because there are two types of walls, ghosts and pills to check for too). But essentially: when PacMan moves he first stores it's current location. Then he moves to the location where it is going to and uses getOneIntersectingActor to check for a wall. If a wall is returned, PacMan moves back to his original stored the location. If null is returned then he does nothing and stays at his new location.
If I get time later today (or tomorrow), I'll comment and then upload the source code.


The _original_ version was built using SDL and Ruby and didn't involve Java at all. At the time I had not used SDL before and that was partly why I built it.
The angle is found through triginomety. You can create a triangle from the shooter to the mouse cursor. One side is the difference between both points on the x-axis, another side is the difference along the y-axis. These allows you to find the angle from the shooter to the mouse cursor. This is the code: double angle = Math.atan2(mouseY-getY(), mouseX-getX()); setRotation((int)Math.toDegrees(angle)); I also have my own class that wraps around the Mouse interface to offer an interface which I much prefer (and performs some internal error check for me). I also use the angle for setting the angle of the shot it creates.


I didn't find it too fast, I found it really slow on my machine. But I do have a few suggestions: first my lives never went below 3 no matter how many times I died, it's quite annoying that you have to click three buttons (the dialog, run and restart) in order to restart the game after you've died and it'd be nice if you could move backwards too.


I really like the idea and gameplay behind this. I think the look and interface though is letting it down. It could be a really nice proper web game if had a better look.


A really good first game, but I have a few suggestions. First put the speed bar up to about 3/4 of the way up, it's a lot smoother. Second improve the ships movement so it's more like proper asteroids. The forward and back buttons could increase or decrease speed and the player is constantly moving by this speed. You could then try to make the players movement seperate from the direction of the ship. For example I could press forward, build up speed and start in that direction, then release forward, continue moving, then press left and turn 90 degrees but I continue moving in the original direction.