I'm just calling the function (Target X/Y of current camera view), which should just have one and only one output value, not one per player. It's going to store one value, not one per player. Whose camera position will it store?
Some values, such as camera coordinates, behave a bit differently than you'd expect. They are
unsynchronized, which means that each player has his own camera coordinates and
knows only his own camera coordinates.
Synchronization is just a matter of keeping values consistent between computers ("clients"). For example, let's say you have a map with two players, and some unit "Bob" is being attacked. When Bob takes damage, his hit points should be kept in sync between the two players. If he is at 300 hp for player 1, then he should be at 300 hp for player 2. If that isn't kept in sync, then weird things can happen. Let's say Bob has 10 hp left on player 1's client and 100 hp left on player 2's client. If he takes 10 damage, then he'll die for player 1 but not for player 2. Obviously, that can make for some really weird gameplay. Wc3 has all sorts of communication in the background to ensure that that doesn't happen. If it does happen, it will kick players (desync).
Anyway, certain things need to be kept in sync. For example, whether Bob is dead should be kept in sync between all players. If Bob is dead for player 1, he should be dead for player 2, 3, 4, etc.. If he is alive for player 1, he should be alive for player 2, 3, 4, etc..
However, keeping all this in sync is expensive and difficult, so wc3 only does a limited number of checks and tries to send as little info as possible. For example, wc3 doesn't bother syncing certain visual stuff like animations, special effect rendering, UI stuff, etc. Same applies for the camera. There isn't any reason that player 2 needs to know where player 1's camera is, so they don't send that. And cameras moved around a
ton, so syncing it "properly" is difficult. That is why the GUI action doesn't allow you to choose which player's coordinates you want to retrieve. Normally we think of a variable as having one, universal value. But with unsynchronized values, it can have a different value depending on whose computer is running it. For example, if you had variables X and Y and wanted to set it to the
(Target X/Y of current camera view), this is how it would actually be set:
X = 500 for player 1, X = 400 for player 2, X = 200 for player 3, etc. This is really similar to the way that GetLocalPlayer() allows you to run a particular code
only on one person's computer.
GetLocalPlayer()
is also unsynchronized!
In your case, this is just fine. You only need to get a player's camera coordinates, add a number, and update the camera for that specific player. No other player needs to know about the update. So the code I posted should work just fine.
If you, for some reason, need other players to know about other player's camera coordinates, then you'll need to synchronize the data yourself manually. It is pretty advanced though, and most people will use scripts like TriggerHappy mentioned.