I’ve restarted the RTS4 project and made a lot of progress very quickly thanks to pulling in existing code from the previous attempts. It’s not quite up to where I was in the previous attempt but getting close.
Currently the following is implemented:
- Parsing the AOM format of proto.xml, terraintypes.xml, clifftypes.xml, forest.xml, waterbodies.xml (partial), techtree.xml
- Parsing and executing random map .xs files
- Primary unit actions (Move, Gather, GatherDrop, Attack, Build)
- Building placement
- Networking (only direct IP, no punch-through)
To speed up development, I’ve pulled in code for the following
- Parser logic comes from ReGE (PhD project)
- XScript runtime is (a modified version of) what was used in XNA RTS4
- Math and Networking is based on that used in Unity RTS4
- Simulation has been completely recoded and is implemented in Unity ECS
It’s not much to look at, but here is how it looks currently
There is currently no pathfinding and technologies cannot be activated, and there are several bugs. Food amount starts as -1. Ranged attacks work but are instant and do not use projectiles, and all attacks work off of the global clock instead of per-unit timers. Something is wrong with random map constraints and water decorations (purple boxes) are being spawned in base, and the starting forest rarely spawns correctly.
(Started 20 Feb 2020)