I just saw this and got excited to implement scrolling through something such as a page vertically. But I don't see a way to also scroll horizontally. Don't know what that would consist of. On a track pad on my mac I can scroll vertically and horizontally with similar motions. And I believe on a typical mouse, when you press in the scroll wheel you can do the same thing.
Good work. Keep it up! You can make the tanks move in more precise direction when keeping a set of double's for its position in which case you do the following when provoked to move forward, and similarly applied to the shells:
private double x, y;
private int speed = 1;
public void act()
{
if (Greenfoot.isKeyDown("w")) // key for moving a tank forward
{
x += Math.cos(Math.toRadians(getRotation())) * speed;
y += Math.sin(Math.toRadians(getRotation())) * speed;
setLocation((int)x, (int)y);
}
}
public void addedToWorld(World world)
{
x = getX();
y = getY();
}
Excellent environment to test these variables. Ha I like sending 1 against 20 and making him superior, and how they will close in on the 1 and return to formation if they succeed.
Nice I like the running/jumping/throwing animations. Looking good! I think it would be better for the scrolling to keep the player more towards the center instead of the lower left corner though.
I would assume the image has the green background in the file. You need to edit the image with an image editing software that supports transparency. In which you select the green and delete. A white and faded gray checkered pattern is usually what indicates transparency. Don't know of any free pc softwares but I have this free PaintBrush program on my mac. I usually use macromedia fireworks for pc but I don't believe it's free. I remember photobucket giving transparency editing functionality. You could actually write code to do this, which actually is giving the motivation to write a full program =)
2011/11/12
Advanced Mouse Control
2011/11/12
Tanks
2011/11/12
Periodic Defense
2011/11/12
RTS Unit Tester
2011/11/12
RTS Unit Tester
2011/11/11
Periodic Defense
2011/11/10
MegaDude
2011/11/10
TMNT clone
2011/11/10
DrHorriblejr land