Morning all,
I'm doing some testing at the moment trying to get the combat working on me game. I believe what I'm trying to do is possible but I'm having a problem getting the syntax right.
I have 2 arrays:
1D "aCharH" for my character stats
2D "TRmob" for my NPC stats
I have a function that calls a random NPC from the TRmob array to the screen, and the NPC HP from that is shoved in to a global variable and shown on screen.
I then have a button to "attack" the NPC. When I click this it SHOULD pull X=2 and X=3 from the aCharH array which is my minAtk and maxAtk values (2 and 4), which then subtracts this from the NPC HP global variable.
However nothing happens. I took out the syntax and just put in "15" to make sure nothing else is wrong and it works fine, so I know my syntax is crap trying to pull the min/max values from aCharH. I know it must be possible, and by god i've looked around the Googleweb for an answer but I can't seem to see anything. Has anyone done something similar?
Thanks!