MCPcopy Create free account
hub / github.com/DescentDevelopers/Descent3 / ObjSetPosAndMarkMoved

Function ObjSetPosAndMarkMoved

Descent3/DllWrappers.cpp:174–183  ·  view source on GitHub ↗

ObjSetPos, that automatically sets the OF_MOVED_THIS_FRAME

Source from the content-addressed store, hash-verified

172
173// ObjSetPos, that automatically sets the OF_MOVED_THIS_FRAME
174void ObjSetPosAndMarkMoved(object *obj, vector *pos, int roomnum, matrix *orient, bool f_update_attached_children) {
175 if (obj) {
176 ObjSetPos(obj, pos, roomnum, orient, f_update_attached_children);
177 if (Demo_flags == DF_RECORDING)
178 DemoWriteChangedObj(obj); // using this instead of setting the flag, since the flag
179 // has a good chance of getting cleared before it is
180 // written
181 // obj->flags |= OF_MOVED_THIS_FRAME;
182 }
183}
184
185// SetObjectDeadFlag that automatically writes out demo data
186void dSetObjectDeadFlagWDemo(object *obj, bool tell_clients_to_remove, bool tell_clients_to_play_sound) {

Callers

nothing calls this directly

Calls 2

ObjSetPosFunction · 0.85
DemoWriteChangedObjFunction · 0.85

Tested by

no test coverage detected