adding in the type-object pattern for enemies and projectiles