Implemented player colors, pause-intersection logic for time areas, and more!
- Added new player sprites, so things look like clones with direction, following each other in chains
- “Head” players have a controls overlay to show potential movement
- These player sprites have color masks to show which initial color the player is
- Long player chains on time areas (play & pause) will intersect the overrides to determine what state to override by
- Uses a request system that applies OR logic at the time of each request
- Fixed more bugs related to time travel and new player
- Tail being created on top of a time area - fixed with hybrid logic, using an active system for requesting pause state, and an exit event to reset.
- Bugs with created/destroyed entities, caused by isPaused not checking ‘valid’ component as override
Before, the process of splitting a player chain, would select a specific action to use to make the changes necessary for upgrading the following segment to a head entity, destroying the middle one, and updating the other group’s tail. There were different changes applied depending on the scenario and type of segment. Then, when you would pause one of the groups, and rewind, the destroyed entities would come back, headless, and would still be “following” the wrong group.
Now, I am currently working on an active “follow” system to validate, prune, and re-calculate follows/followedBy states for all followable entities. This also handles merging logic, mixing colors and paused states with OR logic, to stay consistent with the rest of the game. It runs on any state change, which includes time travel of different directions, so it should fix the split-pause-rewind bugs and more. I’ll be working on this for next week. After that, the camera positioning algorithm.