chorhatarahuduketuri / gc

GalacticConquest
0 stars 0 forks source link

Battles and battle reports #56

Closed adrianlshaw closed 5 years ago

adrianlshaw commented 5 years ago

Added basic battle support with a detailed battle report appearing in the UI.

This is basic because:

Feel free to improve on this proof-of-concept.

chorhatarahuduketuri commented 5 years ago

Also note that we are totally violating this: https://docs.oracle.com/javase/8/docs/technotes/guides/language/static-import.html

chorhatarahuduketuri commented 5 years ago

Actually there is something wrong with this. When I have 2 ships against 1, 2 battles happen in the same turn. Due to there being 2 battles - which are reported out of order - 4 damage is done to HMS Douglas and it is destroyed at the same time as ISS Yuri, and then after that the ISS Yuri does damage again.

adrianlshaw commented 5 years ago

Thanks @chorhatarahuduketuri. Fixed issue where dead ships could attack alive ships, and vice-versa.

Haven't yet solved the issue of multiple battle reports per sector.

chorhatarahuduketuri commented 5 years ago

I fixed the merge errors by reverse-merging.