- Joined
- Jul 14, 2011
- Messages
- 3,213
Hi, tested a RPG map i'm making for the first time, and noticed some interesting stuff... most of them associated with GetLocalPlayer. I use GUI mostly, not JASS, and i'm not pretty sure about how to use GetLocalPlayer to fix some problems.
I'm not having desyncs, since i'm not using GetLocalPlayer() right now xD It's just that other players triggers events that are supposed to trigger only for them.
In the map every NPC has a 'Talk' item. When units 'Talk' the 'BlaBlabla' sound should play only to the (Owner of(Buying Unit)).
I'll add more of these later. I haven't been able to test with other players =/
I'm not having desyncs, since i'm not using GetLocalPlayer() right now xD It's just that other players triggers events that are supposed to trigger only for them.
In the map every NPC has a 'Talk' item. When units 'Talk' the 'BlaBlabla' sound should play only to the (Owner of(Buying Unit)).
-
Chat sound
-
Events
- Unit - A unit Sells an item (from shop)
-
Conditions
-
Or - Any (Conditions) are true
-
Conditions
- (Item-type of (Sold Item)) Equal to Talk
- (Item-type of (Sold Item)) Equal to Beach Monk Talk 1
- (Item-type of (Sold Item)) Equal to Beach Monk Talk 2
-
Conditions
- ((Buying unit) is A Hero) Equal to True
-
Or - Any (Conditions) are true
-
Actions
- Sound - Play Blablabla <gen> at 100.00% volume, skipping the first 0.00 seconds
-
Events
- Custom script: if GetLocalPlayer() == GetOwningPlayer(GetBuyingUnit()) then
- - Actions -
- Custom script: endif
I'll add more of these later. I haven't been able to test with other players =/