I'd like to propose that a .type property gets added to the following "object types":
* player objects in the playerData array: .type == PLAYER (new const required)
* derrick objects in the derrickPositions array: .type == POSITION
* position objects in the startPositions array: .type == POSITION
* research objects from findResearch(), enumResearch(), etc: .type == RESEARCH (new const required)
The reason for this is to allow greater standardisation of helper/wrapper functions in scripts, basically to make passing objects around and working with them easier and more consistent.
As an overly-simplified example, I could have a helper function for building a structure - I could pass in an object defining where to build and have it work out how to get the x,y co-ords, so if it sees PLAYER it knows it needs to go look in startPositions to get a POSITION object and so on.
The change should hopefully be trivial to implement, even for 3.1 branch, as its adding a static property to those object definitions, and two new constants, in qtscriptfuncs.cpp. A cursory look at the C++ code shows good centralisation of the object definitions, however I'm not quite confident enough to submit a patch as my C++ skills are decidedly novice.

