Fix for IndexOutOfBoundException when an entity is removed from the EntityList while it is being ticked.

Fixes IndexOutOfBoundsException caused when an entity is removed (such as when teleported through a portal) during an entities tick by splitting into two loops.

Should have no other side effects or edge cases.