Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Attacking While Moving
#1
Well in Mirage when your walking you can press the arrow keys and attack and walk at the same time. I'm wanting to find a way to stop this.

I tried various things in CheckInput but nothing worked. Any ideas?
Reply
#2
Asrrin29 Wrote:There is code in there already to prevent you from casting while moving, take a look at that and see if you can adapt it to attacking as well.

Allright, I messed with it and it works, but its not great. Basicly They can still walk and attack, theres just a delay in between the attacking becuase canmove is false, But after the character attacks, it advances a step and attacks again. But, it looks better. Thanks.
Reply
#3
Or just 'Exit Sub' if control is down, and have the directional keys' checks below it.

So:

If ControlDown = True then
attack so on and so forth
exit sub
end if

If DirectionUp....

Something like that.
Quote:Robin:
Why aren't maps and shit loaded up in a dynamic array?
Jacob:
the 4 people that know how are lazy
Robin:
Who are those 4 people?
Jacob:
um
you, me, and 2 others?
Reply
#4
Dave Wrote:You could check if an arrow key is down at the same time control is down. Then you could ignore the appropriate key.

I tried that, It didn't work.

Robin, I'll try what you were saying in a moment.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)