split movement into entity-specific functions