• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Movement for units

Status
Not open for further replies.
Level 3
Joined
May 24, 2008
Messages
53
I belive EVERYBODY knows the game World of Warcraft

Well i wanted to do the movement just like that..
when left-arrow-key is pressed, the hero moves left
same with the rest..
also when RIGHT-CTRL key is pressed, the hero attacks at the unit (if there is one) of the angle he's looking (If looking up and there's a unit, attack it)
I still want to use the mouse, for the skills..

any ideas on how to start doing that?
I mean which triggers should i use for that?

Anyway..
Thanks!

Nome
 
Level 3
Joined
May 24, 2008
Messages
53
awesome
now i need the hero to not auto engage a unit that's nearby
I want the hero to engage only when i press ctrl, and engage the unit in the sight of my hero
else if I need to engage only when i press ctrl and after hitting/killing the unit, to hold again until the next ctrl.. is it possible?
 
Last edited:
Level 13
Joined
Mar 4, 2009
Messages
1,156
you can make him a worker but i think best is to make him have acquisition range about 10 (i know if u set it on 0,1,2... it will act like 1000000,i think u need to set it about 10-50)

btw on both ways hero will attack the unit that attacks him
 
Level 12
Joined
Apr 15, 2008
Messages
1,063
CTRL press can not be detected by triggers, only arrows can be. Also, if you want to make such custom attack system, maybe create a hero without attack, and then on attack play heroe's attack animation and damage the unit (this way you could also calculate miss/crit/dodge chance, custom damage....).
You can use dummy abilities to detect lettered keys (create abilities with QWER as hotkeys, add them to hero and then detect their cast, or order)
 
Status
Not open for further replies.
Top