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

[General] SUICIDE SQUAD???

Status
Not open for further replies.
Hey, I have vendor units and when you buy 3 items from one I want to mae teh unit suiide kill itself with effect. I need this, because the unit is invisible and only visible to the player! and when it disappears I Want to effect to be also invisible! :D So.... is there any suicide ability?
Else I know there is local special effect, but someone told me they cause desynchronization.... in multiplayer...
 
Last edited:
Level 20
Joined
Aug 13, 2013
Messages
1,696
It will not cause desync if you've only set it's string model path.
JASS:
local string model = " "
if GetLocalPlayer() == GetTriggerPlayer() then
    set model = "war3\some\Model.mdx"
endif
call DestroyEffect(AddSpecialEffect(model,0,0))
 
Level 20
Joined
Aug 13, 2013
Messages
1,696
They are coordinates and ( 0, 0 ) centers the map. It is a real variable not a point. It is just an example btw :)

Yes you can use a variable to reference them as long as you repeated twice or more than twice it's function call.
 
Status
Not open for further replies.
Top