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

[Trigger] Only on water spell

Status
Not open for further replies.
Level 9
Joined
May 22, 2009
Messages
491
So I ended up just using a Windows operated machine to use my WE and Im loving it =D But I got a problem. I am trying to make it so that when someone casts a spell (Water Surge) It will fail unless they are in shallow water. Maybe its really easy to do and Im missing something but I cant find the condition to see if they are standing on water and (I know this is lame >.<) I cant find the effect to make the spell just stop. Thanks =)
 
  • Trigger
  • Events
    • Unit - A unit starts the effect of an ability
  • Conditions
    • (Ability being cast) Equal to x
  • Actions
    • Set Point1 = (Target Point of ability being cast)
    • If (All conditions are true) then do (Actions) else do (Actions)
      • If - Conditions
        • And - Multiple Conditions
          • (Terrain pathatbility at Point1 of type Floatability is Off) Equal to False
          • (Cliff level at (Point1)) Greater than 2
      • Then - Actions
        • //Actions here
      • Else - Actions
        • Game - Display to (PlayerGroup (Owner of (Triggering unit)) the text: "Wrong point"
    • Custom script: call RemoveLocation (udg_Point1)
The first condition is Boolean, under the Environment and the second is an integer comparison.
 
Level 9
Joined
May 22, 2009
Messages
491
(Sorry for long wait on my part)
I put this in and it still casts on water and land but says "Must be in water" on both also... I think the trigger works but I dont know if I didnt say some specific things. My initial cliff level is shallow the ability is modified war stomp and I want it so that it can only be cast in shallow water not land or deep =) Thanks
 
He also wants shallow water dependency, that is why I used that ;)

for my spell it worked on both shallow and deep water with just the floatability comparison... you can try it... BTW I made it about a year ago on version 1.21 so it would be better if you really try it and see if it would work...
 
You didn't understand. He asked for just Shallow water. So, he doesn't want the spell casted in the deep water. What's the difference between Shallow and Deep water? Their cliff level; that's why I added that extra comparison, to define the shallow water versus the deep one.

oh... okay... sorry for that, I thought he wanted both... sorry... but what if you have different heights? I mean a shallow water on level ground then another shallow water up in a cliff?
 
Status
Not open for further replies.
Top