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

2013/6/4

Shooting Help

SWAG SWAG

2013/6/4

#
How can I make my bombs disappear after 5 seconds after I shot them.
SWAG SWAG

2013/6/5

#
I'm still having difficulty with this. Can anyone help me
steved steved

2013/6/5

#
Add a variable called count or timer or whatever and set it to like 500 (I don't know how many frames per second but thats 500 frames) then in act at the very bottom add this
if(count > 0)
{
    count--;
}
else
{
    getWorld().removeObject(this);
}
make sure that is the last thing in act or it wont work.
steved steved

2013/6/5

#
actually I think its 60frames per second so do 300 and adjust from there.
SWAG SWAG

2013/6/5

#
steved wrote...
actually I think its 60frames per second so do 300 and adjust from there.
Thank for the help.
steved steved

2013/6/5

#
No problem
You need to login to post a reply.