Originally Posted by Magtheridon96
After realizing that calling a struct Player makes it impossible for me to call the function Player even inside the library itself, I changed my system to use:
function PlayerEx takes integer i returns player
I gave it TESH Highlighting too <:
It's true than you won't be allowed to use the native function Player anymore in "bottom" libraries, and scopes.
But if you really want to spell your struct Player, you can still use a second library used by your player library, where a global player array is filled with the 16 players.
And then, inside your player library you use this global variable.
Or if jasshelper memorize this struct name in the whole vJass scripts, you still can use a custom common.j or blizzard.j for this global array.
And if you use the Player native when there is now a great way to use a global instead
, it will even give you a nice
senseless error on compilation to prevent this heresy to happen