| 06-10-2006, 04:37 AM | #1 |
Is it possible? I assume you'd be able to use some form of local thingy, but i'm hoping theres a way to play a sound so that only 1 player hears it instead of everyone. |
| 06-10-2006, 04:41 AM | #2 |
Yes, use this trigger. Player(0) is the player you want to run it for. 0-11 are players 1-12 and 13-15 are the neutral players. Trigger: ![]() Custom Script: if GetLocalPlayer() == Player(0) then![]() -- Run your sound actions in here --![]() Custom Script: endif |
| 06-10-2006, 07:27 AM | #3 |
I suggest you create the sound outside of the Local Player if/then/else and only start it inside. |
| 06-10-2006, 08:13 AM | #4 |
There is a search button uknow.. this has been asked at least 50 times. |
| 06-10-2006, 08:37 AM | #5 |
Or use WEU, it has that function. |
| 06-10-2006, 12:19 PM | #8 |
What i (intend) have is a string array for each player with as many places in it as possible. Each time the player sends a messenger bird, it stores the message in that array somewhere. What i need is some way to check if an array number is in use or if it can be overwritten. |
| 06-10-2006, 01:01 PM | #9 |
I would suggest setting all values in the array to "" (empty string) as an intial value. When you need to put one in the array, loop until you find an empty string and store it in that position. When you are finished using that string (ie. the messenger bird arrives), set the string in that position back to "". |
| 06-11-2006, 03:37 AM | #10 |
That'd work, cheers blu, i probably would have worked that out at some point, but you've just saved me at least several hours of screaming and smacking my head against the wall. Hmm, is there a way to reference different variables to different players without having to use a series of 12 "If/Then/Else" triggers? |
| 06-11-2006, 11:33 AM | #11 |
You can maybe use arrays and player numbers. |
| 06-11-2006, 12:10 PM | #12 |
What i need is some way to reference a String Array without actually using the array. For example, i take P1MessageArray(Custom Value of Casting Unit) i'm not actually referencing to any specific part of that array, it'd be great if i could do something like reference P(Player Number of owner of Casting Unit)MessageArray(Custom Value of Casting Unit) that'd work wonders. Is that possible? (I assume i'd need JASS, since i can't do it with GUI) |
