fixed a couple bugs where I iterated over a dictionary's keys and deleted keys while still looping
fixed a couple bugs where I iterated over a dictionary's keys and deleted keys while still looping. Added timestamps before door events