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

[Solved] Flying Height Not Changing.

Status
Not open for further replies.
Level 11
Joined
Aug 6, 2009
Messages
697
Well this is embarrassing, minimum height was set to 700. SOLVED.


I am using a dummy that uses the 'none' movement type, and has a default flying height of 700. It also has the storm crow form ability as a default spell. When I change the height of the unit, it does not change. Even when I changed the movement type from 'none' to 'fly' nothing changed.

SB_Dummy3 is set, because it moves, but the flying height does not change.

The triggers are unfinished.
  • Actions
    • Set TempInt = (Player number of (Owner of (Triggering unit)))
    • Set SB_Casting[TempInt] = False
    • Set SB_Caster[TempInt] = (Triggering unit)
    • Set SB_Delay[TempInt] = 0
    • Set SB_AOE[TempInt] = (SB_Size[TempInt] + 200.00)
    • Set SB_Cancelable[TempInt] = False
    • Set TempPoint = (Position of SB_Caster[TempInt])
    • Set TempPoint2 = (Target point of ability being cast)
    • Custom script: call SetUnitAnimationByIndex(udg_SB_Caster[udg_TempInt], 13)
    • Set SB_Angle[TempInt] = (Angle from TempPoint to TempPoint2)
    • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
      • If - Conditions
        • (Distance between TempPoint and TempPoint2) Greater than 5000.00
      • Then - Actions
        • Set SB_Distance[TempInt] = 5000.00
        • Set SB_Offset[TempInt] = (0.03 x (SB_Distance[TempInt] / 10.00))
        • Set SB_FlyOffset[TempInt] = (0.03 x (700.00 / 10.00))
      • Else - Actions
        • Set SB_Distance[TempInt] = (Distance between TempPoint and TempPoint2)
        • Set SB_Offset[TempInt] = 20.00
        • Set TempReal = (0.03 x (SB_Distance[TempInt] / SB_Offset[TempInt]))
        • Set SB_FlyOffset[TempInt] = (0.03 x (700.00 / TempReal))
    • Custom script: call RemoveLocation(udg_TempPoint)
    • Custom script: call RemoveLocation(udg_TempPoint2)
Loop Trigger

  • Actions
    • For each (Integer SB_Loop3) from 1 to 12, do (Actions)
      • Loop - Actions
        • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If - Conditions
            • SB_Distance[SB_Loop3] Greater than 0.00
          • Then - Actions
            • Set SB_Distance[SB_Loop3] = (SB_Distance[SB_Loop3] - SB_Offset[SB_Loop3])
            • Set TempPoint = (Position of SB_Dummy[SB_Loop3])
            • Set TempPoint2 = (TempPoint offset by SB_Offset[SB_Loop3] towards SB_Angle[SB_Loop3] degrees)
            • Custom script: call SetUnitXY(udg_TempPoint2,udg_SB_Dummy[udg_SB_Loop3])
            • Set TempReal = ((Current flying height of SB_Dummy[SB_Loop3]) - SB_FlyOffset[SB_Loop3])
            • Custom script: call SetUnitFlyHeight(udg_SB_Dummy[udg_SB_Loop3],udg_TempReal,0)
            • Game - Display to (All players) the text: (String((Current flying height of SB_Dummy[SB_Loop3])))
          • Else - Actions

The three attachments are pictures of the object editor data for the dummy unit.
 

Attachments

  • 1.png
    1.png
    57 KB · Views: 84
  • 2.png
    2.png
    55.5 KB · Views: 70
  • 3.png
    3.png
    53.4 KB · Views: 64
Last edited:
Status
Not open for further replies.
Top