you can't disable the ability to move by right click but there is ways around it. I will show the most easy way.
order unit to stop every time its ordered to move.
- Untitled Trigger 001
- Events
- Unit - A unit Is issued an order targeting a point
- Conditions
- Actions
- Unit - Order (Triggering unit) to Stop
This should do, BUT it will require JassNewGenPack.
If you already have it, then it's fine.
But units will STILL auto-acquire (auto-attack) enemies if they have attack enabled. I have no solution for that except for adding unit classification worker or setting Attack - Targets allowed to Self.
then the system i provided should cover all you need
The trigger i provided is in the map attached to the bottom my second post. Download the map and follow the instructions to copy and paste the triggers into your map.
Good Luck on your map!
You mean to say the unit still moves when targeting a location?
could you tell me what you did to put the system into your map?
Because the test map works for me.
ohh i see!
I have now implemented a variable that controls the unit moving.
it is called "StopMovement_Enabled" (in Jass, it is called udg_StopMovement_Enabled)
You must re-implement the system again.
When it is set to true by default. Whenever your movement system issues theaction, just set StopMovement_Enabled to false and then to True after that.
- Unit - Issue Order Targeting a Point
Example:
EDIT: forgot to attach the map, lol.
- Set StopMovement_Enabled = False
- Unit - Order (Your unit) to Move To (Your point)
- Set StopMovement_Enabled = True
ohh i see!
I have now implemented a variable that controls the unit moving.
it is called "StopMovement_Enabled" (in Jass, it is called udg_StopMovement_Enabled)
You must re-implement the system again.
When it is set to true by default. Whenever your movement system issues theaction, just set StopMovement_Enabled to false and then to True after that.
- Unit - Issue Order Targeting a Point
Example:
EDIT: forgot to attach the map, lol.
- Set StopMovement_Enabled = False
- Unit - Order (Your unit) to Move To (Your point)
- Set StopMovement_Enabled = True
oh no , is't vJASS?
No, no. This is just the GUI part you can do by yourself. The system will just do the rest.
Let me explain: The example i gave you is in GUI. By setting StopMovement_Enabled to [highlight]true/false[/code], it will [highlight]enable/disable[/code] my system, allowing your movement system to move your unit.
If you still don't understand I'll gladly make it simpler.