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

If statement?

Status
Not open for further replies.
Level 12
Joined
Dec 2, 2016
Messages
733
Gyazo - 4af6728c7a108c2775db5f2b8cd57730.png

Even though my picked unit is a vampire minion, if I have the if statement run the action if the picked unit is the vampire. It will not change him to hostile, yet if I have the if statement run the action if the vampire is not the picked unit it will make him hostile. It's like this thing is backwards.

If unit type of picked unit = vampireminion then
make hostile


Output: vamp is not made hostile

if unit type of picked unit ~= vampireminion then
make hostile

Output: vamp is made hostile
 
Status
Not open for further replies.
Top