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

Local Player

Status
Not open for further replies.
Level 17
Joined
Mar 21, 2011
Messages
1,597
hi everyone,
i want to make a quest system where every player has to accept its own quests. so i need an attached special effect (a classic exclamation mark) above the unit that gives you the quest. now, if a player accepts the quest, the exclamation mark should just disappear for him. the other players, that have to accept the quest by their own, should still see it. what would be the best way to do that?
thanks
 
Level 17
Joined
Mar 21, 2011
Messages
1,597

EdgeOfChaos

E

EdgeOfChaos

Just do it the other way around. Set the string to the path outside the If, and if the GetLocalPlayer condition is true, set string to "".
 
Level 19
Joined
Aug 8, 2007
Messages
2,765
boolean b = true
if GetLocalPlayer() == GetTriggerPlayer() then
set b = false
endif
call SetUnitVisible(expPoint,b)

or what above said (units are better, more stable)

string s = pathToExpPoint
if GetLocalPlayer() == GetTriggerPlayer() or questAccepted[GetPlayerId(GetTriggerPlayer())] then
set s = ""
endif
call AttachEffect(s, ...)
 
Status
Not open for further replies.
Top