Delete objects, such as weapons & explosions, that shouldn't stay between levels if clear_all is set, clear even proximity bombs
| 3223 | // Delete objects, such as weapons & explosions, that shouldn't stay between levels |
| 3224 | // if clear_all is set, clear even proximity bombs |
| 3225 | void ClearTransientObjects(int clear_all) { |
| 3226 | int objnum; |
| 3227 | object *objp; |
| 3228 | |
| 3229 | for (objnum = 0, objp = Objects; objnum <= Highest_object_index; objnum++, objp++) { |
| 3230 | if (((objp->type == OBJ_WEAPON) && !(Weapons[objp->id].flags & WF_COUNTERMEASURE)) || |
| 3231 | (objp->type == OBJ_FIREBALL) || (objp->type == OBJ_DEBRIS) || (objp->type == OBJ_SHARD) || |
| 3232 | (objp->type == OBJ_SHOCKWAVE) || (objp->type == OBJ_PARTICLE) || (objp->type == OBJ_SPLINTER) || |
| 3233 | ((objp->type != OBJ_NONE) && (objp->flags & OF_DYING))) { |
| 3234 | mprintf(0, "Clearing object %d type = %d\n", objnum, objp->type); |
| 3235 | ObjDelete(objnum); |
| 3236 | } |
| 3237 | } |
| 3238 | } |
| 3239 | |
| 3240 | // Remaps all static powerups,sounds,etc to their appropriate indices |
| 3241 | void RemapEverything() { |
no test coverage detected