• 🏆 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!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

Order Command not working. Again.

Status
Not open for further replies.
Level 2
Joined
Mar 31, 2004
Messages
21
Code:
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
    If - Conditions
        (Unit-type of (Target unit of ability being cast)) Equal to Become a Doctor
    Then - Actions
        If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            If - Conditions
                (Number of items carried by (Casting unit)) Less than 6
            Then - Actions
                Game - Display to (All players) the text: ((Name of (Owner of (Casting unit))) +  is now a doctor.)
                Unit - Change ownership of Become a Doctor 0027 <gen> to (Owner of (Casting unit)) and Change color
                Game - Display to (Player group((Owner of (Casting unit)))) the text: Nurse: Okay, you're...
                Set DiseaseManActive = True
                Unit - Create 1 Villager (Diseased) for Player 9 (Gray) at (Random point in (Playable map area)) facing (Position of (Casting unit))
                Set Patient = (Last created unit)
                Cinematic - Ping minimap for (Player group((Owner of (Casting unit)))) at (Position of (Last created unit)) for 1.00 seconds, using a Flashy ping of color (0.00%, 60.00%, 0.00%)
                Wait 0.20 seconds
                Unit - Order Disease Man 0029 <gen> to Night Elf Keeper Of The Grove - Entangling Roots Patient
            Else - Actions
    Else - Actions

Everything works, except the last Order. I know I'm forgetting something, I haven't made maps in ages. :roll:
 
Level 6
Joined
Feb 18, 2005
Messages
263
the command will only work, if the unit ordered to do anything can see the target. and reach it.
with spells there is sometimes the bug that in can only cast on targets within the range of the spell...

you might try out these. Hope it works then
 
Level 2
Joined
Mar 31, 2004
Messages
21
Oh. I put the reach of the spell to 99999.00 or something, but not his Line of Sight.

EDIT: Well, it can see the target, reach the target, even attack the target (which it won't do either), but it's not doing anything. Not even moving.
 
Level 2
Joined
Mar 31, 2004
Messages
21
Um, using iseedeadpeople and some other stuff, I figured out that the problem was that "You can't target your own units". You could target allies, neutrals, and enemies, but not units beloning to the same player. Fixed that now, thanks. :p
 
Status
Not open for further replies.
Top