The Daily Click ::. Forums ::. Klik Coding Help ::. Alittle Help please with Bullets ( sorry if this has been asked before )
 

Post Reply  Post Oekaki 
 

Posted By Message

Test_Tube_Games



Registered
  29/03/2004
Points
  45
30th June, 2007 at 06:23:33 -

Tried searching the forums but could find an answer to my question, so here it is:-

I want to make my hero cast spells, he would shoot different spells from his wand. Want to have quite a few different spells from different schools of magic also, with different effects.

Now I am a complete newbie when it comes to coding, so I am wondering what the best way to do this would be?

in testing I have been using a different key for each spell, which is just plain silly, what I need is to have a key for casting the spell and another to choose which spell to cast, is there an easy way for me to do this.

thank you for your help and if this has been answered before please just point me to the right forum / example

thanks for your time and help!

(( ohh just ordered MMF2 so I will be using that program, not use if it makes a difference ))

 
Be gentle I am a complete newbie!

axel

Crazy?

Registered
  05/02/2005
Points
  4766

Game of the Week WinnerYou've Been Circy'd!
30th June, 2007 at 06:58:17 -

One way to do it is to have a counter that says which weapon is selected, and then you have the "change weapon" key increment the counter. Like this:

* Upon pressing key: Tab
- Add 1 to Counter

* Counter > [total number of spells]
- Set Counter to 0

* Counter == 0
* Upon pressing [fire key]
- [fire spell 1]

* Counter == 1
* Upon pressing [fire key]
- [fire spell 2]

etc.

Hope this helps.

 
n/a
   

Post Reply



 



Advertisement

Worth A Click