Gate Unit 'Open/Close' Spell Problems :(

maldruzard

Member
Reaction score
2
Hey there!

I have a buildable unit based on the Gate destructible, and I created a spell based on channel in order to make the gate open and close, being as you can't just make it open and close with destructible triggers.

The trigger for the spell is this:

Code:
    Events
        Unit - A unit Finishes casting an ability
    Conditions
        (Ability being cast) Equal to Open
        (Unit-type of (Triggering unit)) Equal to Fence Gate (Horizontal)
    Actions
        Set Temp_Point = (Position of (Triggering unit))
        Unit - Remove (Triggering unit) from the game
        Unit - Create 1 Fence Gate (Horizontal) - Open for Player 1 (Red) at Temp_Point facing Default building facing degrees
        Custom script:  call RemoveLocation(udg_Temp_Point)

For some reason, the new unit spawns nowhere near the location of the first one in some cases, and others it just moves a small distance away. However, every time the new open gate is not in the same position as the original closed gate. Can't figure out why :(
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top