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

mass dark conversion

Status
Not open for further replies.
Level 5
Joined
Aug 24, 2010
Messages
133
im trying to make dark conversion a aoe effect
but for some reason its not working properly
ive made sure the dummy has mana and vision
and there shouldnt be a problem with base order id

here my triggers
  • dark conversion
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Dark Conversion (custom)
    • Actions
      • Set temp_point = (Target point of ability being cast)
      • Unit Group - Pick every unit in (Units within (400.00 + (100.00 x (Real((Level of Dark Conversion (custom) for hero_picks[(Player number of (Triggering player))]))))) of temp_point) and do (Actions)
        • Loop - Actions
          • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
            • If - Conditions
              • ((Picked unit) is A Hero) Equal to False
              • ((Picked unit) is Mechanical) Equal to False
              • ((Picked unit) is An Ancient) Equal to False
              • ((Picked unit) is Magic Immune) Equal to False
              • ((Picked unit) belongs to an ally of (Owner of (Triggering unit))) Equal to False
            • Then - Actions
              • Unit - Create 1 Dummy for (Owner of (Triggering unit)) at temp_point facing Default building facing degrees
              • Unit - Add Dark Conversion (Malganis, Fast) to (Last created unit)
              • Unit - Set level of Dark Conversion (Malganis, Fast) for (Last created unit) to (Level of Dark Conversion (custom) for hero_picks[(Player number of (Triggering player))])
              • Unit - Order (Last created unit) to Special Miscellaneous - Dark Conversion (Fast) (Picked unit)
              • Unit - Add a 3.00 second Generic expiration timer to (Last created unit)
            • Else - Actions
          • Custom script: call RemoveLocation (udg_temp_point)
 

Bribe

Code Moderator
Level 50
Joined
Sep 26, 2009
Messages
9,456
What isn't working properly about it? I see that your location is removed after only the first unit is "Picked", so that would definitely cause problems.

Perhaps the problem is that your dummy ability is a hero ability. I think it needs to be a regular ability in order to be added to a dummy unit.

  • dark conversion
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Dark Conversion (custom)
    • Actions
      • Set temp_point = (Target point of ability being cast)
      • Custom script: set bj_wantDestroyGroup = true
      • Unit Group - Pick every unit in (Units within (400.00 + (100.00 x (Real((Level of Dark Conversion (custom) for hero_picks[(Player number of (Triggering player))]))))) of temp_point) and do (Actions)
        • Loop - Actions
        • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If - Conditions
            • ((Picked unit) is A Hero) Equal to False
            • ((Picked unit) is Mechanical) Equal to False
            • ((Picked unit) is An Ancient) Equal to False
            • ((Picked unit) is Magic Immune) Equal to False
            • ((Picked unit) belongs to an ally of (Triggering Player) Equal to False
          • Then - Actions
            • Unit - Create 1 Dummy for (Triggering Player) at temp_point facing (Picked unit)
            • Unit - Add Dark Conversion (Malganis, Fast) to (Last created unit)
            • Unit - Set level of Dark Conversion (Malganis, Fast) for (Last created unit) to (Level of Dark Conversion (custom) for hero_picks[(Player number of (Triggering player))])
            • Unit - Order (Last created unit) to Special Miscellaneous - Dark Conversion (Fast) (Picked unit)
            • Unit - Add a 1.00 second Generic expiration timer to (Last created unit)
          • Else - Actions
      • Custom script: call RemoveLocation (udg_temp_point)
 
Level 5
Joined
Aug 24, 2010
Messages
133
i tried making it a normal unit skill but that didnt help
i think the dummy unit is made cause i had an idle worker icon appear when i set the expiration timer really long
it just doesnt cast the actual spell
ill try copying a mass aoe spell out a tutorial and see what happens
cause i tried making the warstomp one from the other post but that didnt work too
 
Level 5
Joined
Aug 24, 2010
Messages
133
yea
heres a small map
maybe you can find the problem
i left the shadow on in this one so you can see the unit get created
theres also a random glitch where the cursor disappears when you click ranged stomp if that was the last skill you learnt and you havent used any other skills yet
 

Attachments

  • stomp.w3x
    18.9 KB · Views: 55
Level 33
Joined
Mar 27, 2008
Messages
8,035
Based on my experience, in "Unit - Order (Last created unit) to Special Miscellaneous - Dark Conversion (Fast) (Picked unit)" MUST use a base spell to activate it
Like if you order the unit to Human Mountain King - Storm Bolt, you MUST use the ORIGINAL base spell, you CANNOT create a custom ability out of the original spell, and order the unit to Storm Bolt particular unit
 
Level 5
Joined
Aug 24, 2010
Messages
133
i managed to get it working
it has to be a unit skill
and the dummy has to be able to move
i read on the forum somewhere that the dummy shouldnt move so i had it as that

zzz now for some reason only some of the units it puts to sleep are turning into zombies
 

Bribe

Code Moderator
Level 50
Joined
Sep 26, 2009
Messages
9,456
You dont even create a unit, because when you create a unit you need to change (Triggering Player) to (Owner of (Triggering Unit)). And then the creation should be fixed.

EDIT: This was for bribe.

Wrong.

Unit - A unit Starts the effect of an ability

"Triggering Player" correctly returns the owner of the triggering unit.

Test it.


In JASS, Unit - Generic Unit Event is called TriggerRegisterAnyUnitEventBJ. Any event that uses that registry method always returns GetTriggerPlayer() as the correct owner. The event-type is called a playerunitevent. Player unit events factor in the player as well as the unit.

JASS:
constant playerunitevent    EVENT_PLAYER_UNIT_SPELL_EFFECT          = ConvertPlayerUnitEvent(274)

 
Level 11
Joined
Jan 25, 2009
Messages
572
I've tried to learn JASS but i just cant figure out all the stuffs because everyone who creates a tutorial uses HARD ENGLISH that we swedish people dont understand... I'm now searhing for someone who can TEACH me JASS personally. As you can see my english is very simple. Not that advanced as Bribe´s. I dont even know what "appropriate" means o_O xD
 
Status
Not open for further replies.
Top