Lua struct obj improvements
If the core frees the obj struct referred by lua, don't free it, just mark it as OBJ_LUAFREE - lua will free it in gc once all the references to it are gone.
This commit is contained in:
@@ -66,7 +66,8 @@ struct obj {
|
||||
#define OBJ_MIGRATING 5 /* object sent off to another level */
|
||||
#define OBJ_BURIED 6 /* object buried */
|
||||
#define OBJ_ONBILL 7 /* object on shk bill */
|
||||
#define NOBJ_STATES 8
|
||||
#define OBJ_LUAFREE 8 /* object has been dealloc'd, but is ref'd by lua */
|
||||
#define NOBJ_STATES 9
|
||||
xchar timed; /* # of fuses (timers) attached to this obj */
|
||||
|
||||
Bitfield(cursed, 1);
|
||||
|
||||
Reference in New Issue
Block a user