| Commit message (Collapse) | Author | Age |
| |
|
|
|
|
|
|
|
|
|
|
| |
When a unit arrived exactly MOVE_SPEED away from its destination, it would
move there via moveToward rather than snapping. On the next tick, its own
cell appeared blocked in the moveMap, triggering a repath to an adjacent
cell — causing infinite oscillation. Fix by excluding the unit's own current
cell from the blocked check before repathing. Also adds repath-to-adjacent
logic so units that arrive while the destination is genuinely occupied by
someone else settle next to it instead of stopping mid-journey.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
| |
Update UpdateMoveSystem to maintain the moveMap as entities move
within a tick. When an entity snaps to a grid cell:
- Block the new cell in the moveMap immediately
- Unblock the old cell
Before snapping, check if the target cell was already claimed by
another entity earlier in the same tick. If so, repath instead of
overlapping.
|
| |
|
|
|
|
|
| |
- Replace individual Entity structs with centralized component slices in Game struct (SoA layout).
- Implement bitmask-based component lookup (CM_Position, CM_Move, etc.).
- Convert logic from object-oriented Update() methods to standalone Systems (UpdateMoveSystem, UpdateGatherSystem, UpdateSpawnSystem).
- Update rendering, selection, and input handling to iterate over component arrays.
|
| | |
|
| | |
|
| |
|