• 🏆 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!

Uncontrollable unit

Status
Not open for further replies.
Level 3
Joined
Feb 11, 2013
Messages
28
How to make a player cannot control its own unit. The player still can select its own unit. The unit is selectable and can be targeted by enemies. I dont want to deselect the unit
 
Level 1
Joined
Dec 27, 2013
Messages
2
example lol?
  • Lol
    • Events
      • Unit - A unit owned by Player 1 (Red) Is issued an order targeting a point
    • Conditions
    • Actions
      • Unit - Order Footman 0000 <gen> to Stop
      • Selection - Clear selection
 
Level 5
Joined
May 12, 2013
Messages
70
Maybe something like,
  • Untitled Trigger 001
    • Events
      • Unit - A unit owned by Player 1 (Red) Is issued an order targeting an object
      • Unit - A unit owned by Player 1 (Red) Is issued an order targeting a point
      • Unit - A unit owned by Player 1 (Red) Is issued an order with no target
    • Conditions
    • Actions
      • Unit - Pause (Triggering unit)
Or maybe like,

  • Untitled Trigger 001 Copy
    • Events
      • Map initialization
    • Conditions
    • Actions
      • Unit - Pause (Random unit from (Units owned by Player 1 (Red) matching (((Matching unit) is A Hero) Equal to True)))
 
Level 3
Joined
Feb 11, 2013
Messages
28
In my map, few creeps are created via trigger and they are ordered to patrol to certain places. The creeps are owned by player. I dont want that player to control that creeps by ordering them to attack or move.
 
You can add the "ward" classification to those units. This hides the command card and only allows the player to use right-click ("smart") commands.
You can then prevent the player from using right-clicks by simply catching the smart order and cancelling it.

Btw, ward units can still cast spells through scripts and triggers.
 
Status
Not open for further replies.
Top