A function added by MWSE.
XGetWeight returns the weight of the object for carriable objects. Returns the maximum capacity of a container and 0 for all other objects. (When the player places multiple copies of one item on the ground the stack is considered one item and this function will calculate the value for the group not just a single item of that type.)
In v0.9.4a it does not work for ammo and repair items. This is fixed in the MWSE update released by Merzasphor.
SyntaxEdit
weight (float): ref->xGetWeight
ExampleEdit
long weight long itemRef setx weight to itemRef->xGetWeight