by Graf Zahl » Sat Jun 24, 2017 6:30 am
Damn. Then you have to give it an explicit type (i.e. replace 'let' with 'PlayerInfo'. There's a few issues in the entire system with global instance variables of native struct types because to the compiler their type is ambiguous.
I wish this had gone differently but when discussing these issues with Randi nothing came out of it. The mere idea of types that can both be used by value and by reference never was part of ZScript's design, although a necessity, so it led to some not so nice problems.
Damn. Then you have to give it an explicit type (i.e. replace 'let' with 'PlayerInfo'. There's a few issues in the entire system with global instance variables of native struct types because to the compiler their type is ambiguous.
I wish this had gone differently but when discussing these issues with Randi nothing came out of it. The mere idea of types that can both be used by value and by reference never was part of ZScript's design, although a necessity, so it led to some not so nice problems.