- Joined
- Apr 24, 2012
- Messages
- 9,797
Okay, that 522 max movement is killing me. I want to create a mount system that increases the hero's movement speed by a percentage. However, I encountered some problems as to what I would do when the hero is ordered to move.
a.) First solution would be to list all movement orders and calculate some mind burning things.
b.) Second solution would be moving ahead the unit's facing angle using SetUnitX/Y. (The unit would turn to where it wants to go)
It would be the easier solution B. However, there are cons. What if the hero is supposed to turn around 180 degrees.. and the movement system moved him in an arc instead of directly moving in the opposite direction, thus acquiring the aggro of nearby creeps.
What would be a solution?
Another question, if the movement speed is very high; let's say 1000(/33 = 30.30), and there was an impathable object within that 30 distance, how do I prevent the unit from going through that object?
a.) First solution would be to list all movement orders and calculate some mind burning things.
b.) Second solution would be moving ahead the unit's facing angle using SetUnitX/Y. (The unit would turn to where it wants to go)
It would be the easier solution B. However, there are cons. What if the hero is supposed to turn around 180 degrees.. and the movement system moved him in an arc instead of directly moving in the opposite direction, thus acquiring the aggro of nearby creeps.
What would be a solution?
Another question, if the movement speed is very high; let's say 1000(/33 = 30.30), and there was an impathable object within that 30 distance, how do I prevent the unit from going through that object?