UCC Reference

UI_update_last_created

bool UI_update_last_created(int pos[])

Pops the last object pushed in the 'last created' stack and places it in the game map at the supplied position.

Parameters

Parameter / value Description
pos The location where the new object is to be placed.

The location can be specified by arrays ranging from 1 to 4 components. The meaning of these components is as follows:

Return

For the 1-element version, false if the 'last created' stack is empty or true if the object was deleted. Otherwise, returns true if object was successfully placed on the map, false otherwise.

NOTES ABOUT ORIGINAL GAMES

In the original games, the function could fail to place the item in the map. In this case, it would try to delete an unrelated on-screen object flagged with the TEMPORARY flag to make room for the updated object and retry. The retry could fail again, in which case the update fails; otherwise, it would succeed. This means that, on occasion, using this function could cause objects to be deleted in the original.

Related intrinsics

Full intrinsic reference | Reference definitions