Fixed some bugs in handling objects mid-update, but not fully fixed
Added additional changes to help with premature remove/erase operations, may cause segfaults later