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

Report as inappropriate.

SamSkinner
SamSkinner presents ...

2009/11/18

Archerman

A work in progress.

Thanks for any help, feedback, or ideas. :)

*UPDATES*
-Added smoke effect to arrows.
-Added level 5 with a new background.
-Fixed some glitches.

LEFT/RIGHT ARROWS to move.
UP ARROW to jump.
F to shoot.

6829 views / 11 in the last 7 days

8 votes | 0 in the last 7 days

Tags: game demo arrow man archer archerman knight ranger castle guard

open in greenfoot
Your browser does not support the canvas tag.
ZergZerg

2009/11/21

so long as the arrow is removing itself at the end instead of resetting, you only need the direction and and a life time for the arrow. You can use MTK's code for the direction, and then add to the constructor public Arrow(double angle, int life){ this.life = life; this.angle = angle; } Then in the act method, have a timer variable increment each act and when it is the same as life, then remove the arrow.
MTKMTK

2009/11/21

Why do you need a life time?
ZergZerg

2009/11/21

You need a lifetime if you want the arrow to stop eventually! Otherwise you can just wait until it hits the edge of the world and remove it then. If there is no time at which it is removed, then you wind up with too many arrows :P
MTKMTK

2009/11/22

Isn't it supposed to stop only if it hits the edge or another object?
plcsplcs

2009/11/23

Minor error in level 3. The archer on top of the box can be killed but arrows still keep firing!
A new version of this scenario was uploaded on Wed Dec 09 20:27:59 UTC 2009
A new version of this scenario was uploaded on Mon Dec 14 01:37:44 UTC 2009
A new version of this scenario was uploaded on Thu Mar 04 22:43:46 UTC 2010
A new version of this scenario was uploaded on Sun Mar 28 19:54:44 UTC 2010
Yes a good game.

See all comments

Want to leave a comment? You must first log in.

Who likes this?

thegreencoolerman mik MathManiac ralf Tigrex kenshinakh Green-Foot