Fleet Movement Overhaul

Programmers discuss here anything related to FreeOrion programming. Primarily for the developers to discuss.

Moderators:Committer, Committer

Post Reply
Joined:Sat Dec 10, 2011 5:46 am
Fleet Movement Overhaul

#1 Post by o01eg » Wed Jan 01, 2020 3:34 pm

While trying to work on issue https://github.com/freeorion/freeorion/issues/2675 I found out current movement implementation is sensitive to order of fleets: https://github.com/freeorion/freeorion/pull/2220

I got an idea about order-independent fleet movement:
  1. Apply orders to each fleet's route independently.
  2. For each fleet in the star system check if it cannot move and mark it as stationary of other fleets routes.
  3. For each non-stationary fleet cut route if next turn will be blockaded independently of other non-stationary fleet.
  4. Move each non-stationary fleet according route independently.
I suppose such decomposition will simplify fleet movement code as well as solve https://github.com/freeorion/freeorion/issues/2675
Gentoo Linux x64, gcc-9.2, boost-1.72.0
Ubuntu Server 18.04 x64, gcc-7.4, boost-1.65.1
Welcome to the slow multiplayer game at freeorion-lt.dedyn.io.Version 0.4.10.
Donations are welcome: BTC:14XLekD9ifwqLtZX4iteepvbLQNYVG87zK

Joined:Tue Sep 30, 2014 10:01 am
Location:Wall IV

Re: Fleet Movement Overhaul

#2 Post by Ophiuchus » Mon Jan 06, 2020 5:37 pm

One issue which introduces order of orders is if considering a fleet with orders to move away to be non-blocking.
Not sure how this currently handled
Any code or patches in anything posted here is released under the CC and GPL licences in use for the FO project.

Furthermore, I propse... we should default to four combat rounds instead of three ...for the good of playerkind.

Post Reply