• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

[JASS] GetConvertedPlayerId()

Status
Not open for further replies.
Level 4
Joined
May 4, 2008
Messages
113
I have some GUI triggers and some JASS triggers. Global variables have been set which use arrays 1, 2, 3 and 4 for players 1, 2, 3, 4.

I understand that when doing something like the following action:
Code:
Set MyVar[Player number of (Owner of (Triggering unit))] = 1
in GUI, the 'player number of owner of triggering unit' if the player was player 1 would be 0, and so it uses "GetConvertedPlayerId" to change it to 1.

My question is, if I am setting the SAME global variable in a JASS trigger, do I have to add that 1 to the array value, or do I just use "GetPlayerId" and it will work?

Hope that makes sense. Thanks in advance.
 
Status
Not open for further replies.
Top