• 🏆 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] WE can't detect if Flyability is Off?

Status
Not open for further replies.
Level 6
Joined
Oct 31, 2015
Messages
95
I don't know if this is some unknown bug of patch 1.29 (1.29.1 and 1.29.2 too) and I haven't seem people talking about this but if you place a Pathing Blocker (Air) or even a Pathing Blocker (Both) you cannot detect if flyability is off with triggers unless you trigger all points inside the region one by one by triggering it through:

Environment - Set terrain pathing at ("Target Point") of type Flyability to Off

I'm making a jump ability and I can't allow people to go jumping all around the map. It already can detect deep and shallow water but I need to figure out a way to detect flyability in order to simulate high walls (which you cannot jump over). Any ideas :p?
 
Level 6
Joined
Oct 31, 2015
Messages
95
It worked as intended but now I'm facing new problems. The more urgent one is that I'm not being able to reset the flying height of the jumping hero when the flying dummy detects a non-air pathable area (so the hero is still flying). I believe this problem is more with my triggering than with your suggestion @MyPad.
A question more related to you idea would be about memory usage (0.04 kb for each flying dummy). I will try to workaround this problem with @Flux's Dummy Recycler. I will be posting the triggers to help future readers and people which may want to aid me. I'm using @BPower's Missile System to emulate my trajectories. (I already use it for other stuff :))

  • Actions
    • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
      • If - Conditions
        • Missile__EventId Equal to EVENT_MISSILE_FINISH
      • Then - Actions
        • Unit - Remove Ability_FlyingCheckDummy[(Custom value of Missile__Source)] from the game
        • Unit - Add Crow Form to Missile__Source
        • Unit - Remove Crow Form from Missile__Source
        • Animation - Change Missile__Source flying height to (Default flying height of Missile__Source) at 0.00
        • Animation - Remove the attack walk stand spin animation tag to Missile__Source
        • Set Missile__WantDestroy = True
      • Else - Actions
    • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
      • If - Conditions
        • Missile__EventId Equal to EVENT_MISSILE_PERIODIC
      • Then - Actions
        • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If - Conditions
            • (Missile__Source is alive) Equal to True
          • Then - Actions
            • Set TempPoint_MSL[Missile__Index] = (Position of Missile__Dummy)
            • Set TempPoint_MSL2[Missile__Index] = (TempPoint_MSL[Missile__Index] offset by 25.00 towards (Angle from TempPoint_MSL[Missile__Index] to Missile__Impact) degrees)
            • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
              • If - Conditions
                • And - All (Conditions) are true
                  • Conditions
                    • (Terrain pathing at TempPoint_MSL2[Missile__Index] of type Walkability is off) Equal to True
                    • (Terrain pathing at TempPoint_MSL[Missile__Index] of type Floatability is off) Equal to False
              • Then - Actions
                • Unit - Remove Ability_FlyingCheckDummy[(Custom value of Missile__Source)] from the game
                • Unit - Add Crow Form to Missile__Source
                • Unit - Remove Crow Form from Missile__Source
                • Animation - Change Missile__Source flying height to (Default flying height of Missile__Source) at 0.00
                • Animation - Remove the attack walk stand spin animation tag to Missile__Source
                • Set Missile__WantDestroy = True
              • Else - Actions
                • Custom script: call SetUnitX(udg_Missile__Source, GetLocationX(udg_TempPoint_MSL[udg_Missile__Index]))
                • Custom script: call SetUnitY(udg_Missile__Source, GetLocationY(udg_TempPoint_MSL[udg_Missile__Index]))
                • Unit - Move Ability_FlyingCheckDummy[(Custom value of Missile__Source)] instantly to TempPoint_MSL[Missile__Index]
                • Set Ability_FlyingCheckPoint[(Custom value of Missile__Source)] = (Position of Ability_FlyingCheckDummy[(Custom value of Missile__Source)])
                • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
                  • If - Conditions
                    • (Distance between Ability_FlyingCheckPoint[(Custom value of Missile__Source)] and TempPoint_MSL[Missile__Index]) Not equal to 0.00
                  • Then - Actions
                    • Unit - Add Crow Form to Missile__Source
                    • Animation - Change Missile__Source flying height to 3000.00 at 0.40
                    • Unit - Remove Crow Form from Missile__Source
                    • Custom script: call SetUnitX(udg_Missile__Source, GetLocationX(udg_Ability_FlyingCheckPoint[GetUnitUserData(udg_Missile__Source)]))
                    • Custom script: call SetUnitY(udg_Missile__Source, GetLocationY(udg_Ability_FlyingCheckPoint[GetUnitUserData(udg_Missile__Source)]))
                    • Animation - Remove the attack walk stand spin animation tag to Missile__Source
                    • Set Missile__WantDestroy = True
                    • Unit - Remove Ability_FlyingCheckDummy[(Custom value of Missile__Source)] from the game
                  • Else - Actions
                • Custom script: call RemoveLocation (udg_Ability_FlyingCheckPoint[GetUnitUserData(udg_Missile__Source)])
                • Unit - Add Crow Form to Missile__Source
                • Unit - Remove Crow Form from Missile__Source
                • Animation - Change Missile__Source flying height to (Current flying height of Missile__Dummy) at 0.00
            • Custom script: call RemoveLocation (udg_TempPoint_MSL[udg_Missile__Index])
            • Custom script: call RemoveLocation (udg_TempPoint_MSL2[udg_Missile__Index])
          • Else - Actions
            • Unit - Remove Ability_FlyingCheckDummy[(Custom value of Missile__Source)] from the game
            • Unit - Add Crow Form to Missile__Source
            • Unit - Remove Crow Form from Missile__Source
            • Animation - Change Missile__Source flying height to (Default flying height of Missile__Source) at 0.00
            • Animation - Remove the attack walk stand spin animation tag to Missile__Source
            • Set Missile__WantDestroy = True
      • Else - Actions
    • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
      • If - Conditions
        • And - All (Conditions) are true
          • Conditions
            • Missile__EventId Equal to EVENT_MISSILE_COLLIDE_DEST
      • Then - Actions
        • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If - Conditions
            • Or - Any (Conditions) are true
              • Conditions
                • (Destructible-type of Missile__DestructableHit) Equal to Massive Demonic Gate (Horizontal)
                • (Destructible-type of Missile__DestructableHit) Equal to Rolling Stone Door (Horizontal 1)
          • Then - Actions
            • Unit - Remove Ability_FlyingCheckDummy[(Custom value of Missile__Source)] from the game
            • Unit - Add Crow Form to Missile__Source
            • Unit - Remove Crow Form from Missile__Source
            • Animation - Change Missile__Source flying height to (Default flying height of Missile__Source) at 0.00
            • Animation - Remove the attack walk stand spin animation tag to Missile__Source
            • Set Missile__WantDestroy = True
          • Else - Actions
      • Else - Actions
At Event Finish and Event Collide Destructible the flying hero will stop as it should not cross gates, altough I'm facing issues when dealing with rolling doors. The part of Walkability off = true and Floatability off = false is a trick I use to detect deep water to avoid the unit to get stuck in water but I honestly don't like the idea of being not able to jump over deep water. I may change to something different like drowning the hero :D
 
Level 6
Joined
Oct 31, 2015
Messages
95
Thank you guys for repplying. Both solutions work well when it comes to detect non-flyable areas. But I will give up of the jump skill anyway because of the difficulty in detecting collisions with gates and I also concluded that jumping over cliffs and deep water would be an unfair advantage in my kind of map. Thank you for helping me with such good ideas, I will be using them in the future.
 
Status
Not open for further replies.
Top