Alice Community

Alice Community (http://www.alice.org/community/index.php)
-   Questions and Comments (http://www.alice.org/community/forumdisplay.php?f=9)
-   -   How do i have a gun run out of ammo? (http://www.alice.org/community/showthread.php?t=4636)

GoGators 06-22-2010 07:24 AM

How do i have a gun run out of ammo?
 
Ok so i want my gun to run out of ammo and then be able to reload!
Could i please get some help?

Thanks,
GoGators:cool:

DensetsuNoKaboom 06-22-2010 07:34 AM

OK, time for a long explanation:

Make a variable that is called "ammo" and set it to whatever you want the ammo clip to be. Then you make a keypress that says "When key is pressed, if ammo>0, do gun fire, then ammo decrement by 1, else do nothing."

GoGators 06-22-2010 05:40 PM

Ok
 
ok but thenhow would i reload(and get bullets back in my gun)

DensetsuNoKaboom 06-23-2010 11:56 AM

Then you do "When (are you doing a button press to reload or an item that qwhen you get it reloads your gun?) happens, do ammo set value to (however many bullets were in the gun at the beginning)."

Watsamax1 06-25-2010 08:15 AM

if i look at my game it would be perfect i have all those implemented.

GoGators 07-08-2010 06:35 AM

Where
 
[QUOTE=Watsamax1;22612]if i look at my game it would be perfect i have all those implemented.[/QUOTE]

Where ?
:confused:


All times are GMT -5. The time now is 10:51 AM.

Copyright ©2020, Carnegie Mellon University
Alice 2.x 1999-2012, Alice 3.x 2008-2012, Carnegie Mellon University. All rights reserved.