FreeOrion

Forums for the FreeOrion project
It is currently Tue Dec 12, 2017 12:15 pm

All times are UTC




Post new topic Reply to topic  [ 22 posts ]  Go to page Previous  1, 2
Author Message
PostPosted: Wed May 31, 2017 4:43 pm 
Offline
Dyson Forest

Joined: Tue Sep 30, 2014 10:01 am
Posts: 213
I tried to modify the dynamic simulator to accomodate imperial projects and made the coroutines for inter-supply-group issues work without bigger refactoring. But now I hit a wall / need to change my strategy.

Also inside of a single supply group one has to iterate first by turns, then by elements (at the moment it is the opposite way round).
The case when this happens is when there is an element which is fundable takes more than one turn to finish and there is more than one fundable element.

E.g.
There are two scouts in the queue, both are VIP (very imperial projects; i.e. may be funded by imperial stockpile). There is no other production in that group so only imperial stockpile can build these scouts. There are 14.4 PP in the imperial stockpile, a scout costs 12.4 PP
After first turn both scouts get funded each 6.2 PP.
After the second round the first scout gets funded 2 PP, the imperial stockpile is empty, no scout is built.

If iteration goes turns first, then elements I get a wrong result: the first scout gets completely built and the second gets funded 2 PP.


Instead of changing to iterating first over the supply groups, then the elements, then the turns;
I guess one could go the whole way and go iterate first over the turns, then the different supply groups, then over the elements. In that case i guess one wouldnt need the coroutines anymore.

_________________
Any code or patches in anything posted here is released under the CC and GPL licences in use for the FO project.


Top
 Profile  
 
PostPosted: Fri Jun 09, 2017 8:36 am 
Offline
Dyson Forest

Joined: Tue Sep 30, 2014 10:01 am
Posts: 213
@Dilvish are you actively working on refactoring the queue simulation? If not I probably could give it again a stab next week.

_________________
Any code or patches in anything posted here is released under the CC and GPL licences in use for the FO project.


Top
 Profile  
 
PostPosted: Sat Jun 10, 2017 6:01 pm 
Offline
AI Lead, Programmer
User avatar

Joined: Sat Sep 22, 2012 6:25 pm
Posts: 4390
Ophiuchus wrote:
@Dilvish are you actively working on refactoring the queue simulation? If not I probably could give it again a stab next week.
Yes I am , I'll try to get something posted today or tomorrow.

_________________
If I provided any code, scripts or other content here, it's released under GPL 2.0 and CC-BY-SA 3.0


Top
 Profile  
 
PostPosted: Sat Jun 10, 2017 6:48 pm 
Offline
Dyson Forest

Joined: Tue Sep 30, 2014 10:01 am
Posts: 213
Dilvish wrote:
Ophiuchus wrote:
@Dilvish are you actively working on refactoring the queue simulation? If not I probably could give it again a stab next week.
Yes I am , I'll try to get something posted today or tomorrow.

Sorry, I am impatient. Very excited :)

_________________
Any code or patches in anything posted here is released under the CC and GPL licences in use for the FO project.


Top
 Profile  
 
PostPosted: Tue Jun 13, 2017 6:13 am 
Offline
AI Lead, Programmer
User avatar

Joined: Sat Sep 22, 2012 6:25 pm
Posts: 4390
Ophiuchus wrote:
Dilvish wrote:
Ophiuchus wrote:
@Dilvish are you actively working on refactoring the queue simulation? If not I probably could give it again a stab next week.
Yes I am , I'll try to get something posted today or tomorrow.

Sorry, I am impatient. Very excited :)
an update for you: as you may have noticed, I discovered a bug in the current projections code and I'm waiting on finalizing and merging the bugfix PR I have up before I post the follow-on reorg PR. I think we'll probably have that done within the next day or so.

_________________
If I provided any code, scripts or other content here, it's released under GPL 2.0 and CC-BY-SA 3.0


Top
 Profile  
 
PostPosted: Sat Aug 05, 2017 2:31 am 
Offline
AI Lead, Programmer
User avatar

Joined: Sat Sep 22, 2012 6:25 pm
Posts: 4390
I just wanted to note here that I just rebased the Basic Imperial Stockpile PR in order to clean up some conflicts that had arisen with ongoing developments in master....

Ophiuchus, have you had a chance to work with this, has it proven to be a suitable base for the rest of the Imperial Stockpile features you were working on?

_________________
If I provided any code, scripts or other content here, it's released under GPL 2.0 and CC-BY-SA 3.0


Top
 Profile  
 
PostPosted: Sun Aug 06, 2017 4:02 pm 
Offline
Dyson Forest

Joined: Tue Sep 30, 2014 10:01 am
Posts: 213
Dilvish wrote:
I just wanted to note here that I just rebased the Basic Imperial Stockpile PR in order to clean up some conflicts that had arisen with ongoing developments in master....

Ophiuchus, have you had a chance to work with this, has it proven to be a suitable base for the rest of the Imperial Stockpile features you were working on?

I tried some laenfa game combining with sneaky species trait, but the effects for stealthy intermixed expansion were not strong enough.
The stockpile in that basic version mostly worked as a buffer for the capital supply group. (Which is fun, but I dont think AI can use it at the moment and doesnt help with peaceful expansion).

That was some weeks ago. If i remember correctly, the basic mechanism was working, so i probably could add my stuff on top of that.

I still think that restricting the extraction from the stockpile makes more sense than restricting the total stockpile amount.

Also your choice of giving the stockpile a location leads to extra questions which have not been answered yet. E.g. what happens if somebody relocates the capital? Is the stockpile automatically relocated?

Im not sure how to proceed though. I got a new job and not so much free time to spare. Your code is not really based on mine, so i have to reimplement. I'll give it a shot tonight.

_________________
Any code or patches in anything posted here is released under the CC and GPL licences in use for the FO project.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 22 posts ]  Go to page Previous  1, 2

All times are UTC


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group