• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

Telling a unit to face a unit...and he won't

Status
Not open for further replies.
Level 14
Joined
Aug 30, 2004
Messages
909
This is odd... I have a series of quests offered to the player in my campaign. To select a quest, they walk up to a region with their hero, and select the guy with the "!" over his head. The quest giver is in a variable called qg_Something. The player's hero is Tirshata.

For some reason (and as far as I can tell for the first time now) when I select the quest giver, the unit Tirshata does not turn to face him! Instead he turns away.

The trigger is firing, meaning that the unit he is meant to face is actually stored as: qg_Ogriphant. The Tirshata unit does exist in that region, and when I tell the quest giver to face Tirshata it actually works. So all the variables are set correctly...and yet the Tirshata unit doesn't turn to face him.

The Tirshata unit does actually turn slowly, just to a different point. So the unit is being given the command. I looked at other triggers that use this command to see if another trigger overrides it, but I can't find that.

I don't think it's an error with the code, I suspect it's just a terrible bug. My question to you:

Is anyone aware of a bug with the "Make unit face unit" action?


  • initiate Orgriphant mission
    • Events
      • Player - Player 12 (Brown) Selects a unit
    • Conditions
      • (Triggering unit) Equal to qg_Ogriphant
      • (Ogriphant Address <gen> contains Tirshata) Equal to True
      • questingBoolean Equal to False
    • Actions
      • Trigger - Turn off (This trigger)
      • Player - Make Player 12 (Brown) treat Player 9 (Gray) as an Ally
      • Set Game = 6
      • Set ogriphantInteger = 0
      • Set questingBoolean = True
      • Set BGspawnPoint1 = (Center of OgriphantEnemySpawn <gen>)
      • Set BGspawnPoint2 = (Center of OgriphantEnemySpawn2 <gen>)
      • Set tempPoint4 = (Center of OgriphantAlly <gen>)
      • Set CinematicTrigger = initiate Orgriphant cinematic OVER <gen>
      • Unit - Make Tirshata face qg_Ogriphant over 2.00 seconds
      • Unit - Make qg_Ogriphant face Tirshata over 2.00 seconds
      • Trigger - Run Cinematic Start Immediate <gen> (checking conditions)
      • Camera - Apply Ogriphant1 <gen> for Player 12 (Brown) over 0.00 seconds
      • Camera - Apply Ogriphant2 <gen> for Player 12 (Brown) over 25.00 seconds
      • Set tempString = Krall the Leash-holder
      • -------- -------- --------
      • -------- make ogriphants --------
      • -------- -------- --------
      • Set tempPoint = (Center of Ogriphant1 <gen>)
      • Unit - Create 1 _Orgriphant for Player 9 (Gray) at tempPoint facing 245.00 degrees
      • Unit Group - Add (Last created unit) to unitGroup
      • Custom script: call RemoveLocation (udg_tempPoint)
      • Set tempPoint = (Center of Ogriphant2 <gen>)
      • Unit - Create 1 _Orgriphant for Player 9 (Gray) at tempPoint facing 15.00 degrees
      • Unit Group - Add (Last created unit) to unitGroup
      • Custom script: call RemoveLocation (udg_tempPoint)
      • Set tempPoint = (Center of Ogriphant3 <gen>)
      • Unit - Create 1 _Orgriphant for Player 9 (Gray) at tempPoint facing 105.00 degrees
      • Unit Group - Add (Last created unit) to unitGroup
      • Custom script: call RemoveLocation (udg_tempPoint)
      • -------- -------- --------
      • Cinematic - Send transmission to (All players) from qg_Ogriphant named tempString: Play No sound and display So ya want to breed.... Modify duration: Set to 18.00 seconds and Wait
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Skip Equal to True
        • Then - Actions
          • Skip remaining actions
        • Else - Actions
      • Cinematic - Send transmission to (All players) from Tirshata named La'Shanta: Play No sound and display You best be speakin.... Modify duration: Set to 5.00 seconds and Wait
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Skip Equal to True
        • Then - Actions
          • Skip remaining actions
        • Else - Actions
      • Cinematic - Send transmission to (All players) from qg_Ogriphant named tempString: Play No sound and display Meta whats?. Modify duration: Set to 4.00 seconds and Wait
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Skip Equal to True
        • Then - Actions
          • Skip remaining actions
        • Else - Actions
      • Cinematic - Send transmission to (All players) from Tirshata named La'Shanta: Play No sound and display Nevermind. What is.... Modify duration: Set to 7.00 seconds and Wait
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Skip Equal to True
        • Then - Actions
          • Skip remaining actions
        • Else - Actions
      • Cinematic - Send transmission to (All players) from qg_Ogriphant named tempString: Play No sound and display My grazing field is.... Modify duration: Set to 16.00 seconds and Wait
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Skip Equal to True
        • Then - Actions
          • Skip remaining actions
        • Else - Actions
      • Cinematic - Send transmission to (All players) from Tirshata named La'Shanta: Play No sound and display Sounds simple.. Modify duration: Set to 3.00 seconds and Wait
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • Skip Equal to True
        • Then - Actions
          • Skip remaining actions
        • Else - Actions
      • Trigger - Run Cinematic Over <gen> (checking conditions)
 
Level 14
Joined
Aug 30, 2004
Messages
909
What do you mean "qg_Something turns away"? It may be a property of the unit, so you can try to control it yourself. Or check if they quest giver has incoming orders.

I'm sorry, maybe I wasn't specific enough. I have two lines that are meant to make two units face each other so they can have a conversation:

  • Unit - Make Tirshata face qg_Ogriphant over 2.00 seconds
  • Unit - Make qg_Ogriphant face Tirshata over 2.00 seconds
One of them, qg_Ogriphant turns just fine and faces Tirshata.
But Tirshata turns away very slowly.

Tirshata doesn't run away so I don't think he has any orders. What kind of order would make him turn but not run? It's during a cinematic as well, so the player isn't doing anything.

I tried changing "qq_Ogriphant" to "triggering unit" and I'll see if that works. It's so odd though, because the trigger only fires if I select qg_Ogriphant, so the unit is clearly set correctly to that guy.
 
Level 28
Joined
Sep 26, 2009
Messages
2,520
That is an animation order that rotates their head/torso to face the other unit? It is not an actual game play order and only certain models support it.
Nah, rotating head/torso is this action:
  • Animation - Lock UnitA's Head to face UnitB, offset by (0.00, 0.00, 90.00)

What about the properties of the unit? Namely its movement speed, turning rate and so on? Maybe it doesn't turn because it cannot turn at all?
 
Level 14
Joined
Aug 30, 2004
Messages
909
I think I found it: the problem appears when the player orders the unit to walk right before the trigger begins. The unit appears to be turning to face the other unit as if it were in the target location.

For example, if I click behind the qq_ogriphant unit, then select it the trigger fires. My guy stops moving, but he turns around as if he were behind the qg_ogriphant unit.

I now added a line to order Tirshata to stop before rotating him. That seems to work, but I'll keep testing.

Thanks for all the help, + rep all around.
 
Status
Not open for further replies.
Top