patchFreeciv - Patches: patch #1234, more than one build slot for units

 
 
Show feedback again

patch #1234: more than one build slot for units

Submitted by:  Matthias Pfafferodt <syntron>
Submitted on:  Sat 08 Aug 2009 08:58:41 PM UTC  
 
Category: generalPriority: 1 - Later
Status: DonePrivacy: Public
Assigned to: Matthias Pfafferodt <syntron>Open/Closed: Closed
Planned Release: 2.3.0

Add a New Comment (Rich MarkupRich Markup):
   

You are not logged in

Please log in, so followups can be emailed to you.

 

(Jump to the original submission Jump to the original submission)

Sat 27 Mar 2010 11:14:44 AM UTC, SVN revision 17166:

more than one build slot for units

  • only for units with pop_cost = 0

see gna patch #1234

(Browse SVN revision 17166)

Matthias Pfafferodt <syntron>
Project MemberIn charge of this item.
Sun 08 Nov 2009 07:44:40 PM UTC, comment #8:

a city with more build slots is shown in file #7252

Matthias Pfafferodt <syntron>
Project MemberIn charge of this item.
Sun 08 Nov 2009 07:29:46 PM UTC, comment #7:

updated patch; changes:

  • add effect to give at least one build slot to each city
  • cleanup; patch is independent from the variable city radii patch series
  • small changes to the gtk client
Matthias Pfafferodt <syntron>
Project MemberIn charge of this item.
Mon 02 Nov 2009 10:59:37 PM UTC, comment #6:

[in private mail by Goswin]

> Not a unit and putting 2 space ship components into the list
> would be the same as clicking the "2" box in your system. I'm
> not arguing about changing what gets build. Just how to
> account for/coordinat that with the build list.
>
> I'm perfectly fine with building just one Diplomat if you have
> a Diplomat and an Armor in the build list. But if you have 2
> Diplomats and then an Armor and enough shields it should build
> 2 and remove 2 from the build list.
>
> Lets explain it this way: The unit type build can only be
> changed once a turn but it will produce as many units as are
> queued up and shields allow.
>
> "Diplomat, Armor, Diplomat, Armor" takes always >= 4 turns.
> "Diplomat, Diplomat, Armor, Armor" takes >= 2.
> "Armor, Coinage" builds exactly one armor and coinage the next > turn.
> "Freight" will build as many Freights as possible each turn.


The above listed rules for build slots are considered in the updated version of the patch. Furthermore the number of build slots is given in the city dialog and the city report. It is listed as

  • Have/Cost: for buildings or only one unit
  • Have/{x*Cost}: for x < available build slots
  • Have/[x*Cost]: for x = available build slots

see city_production_cost_str() in ./client/citydlg_common.c

(file #7207)

Matthias Pfafferodt <syntron>
Project MemberIn charge of this item.
Wed 28 Oct 2009 07:56:27 PM UTC, comment #5:

> What is wrong with building the next unit in the list and
> possibly showing the number of turns required as 0 for all but
> the first of a set?


I think this would be to powerfull (space ship?).

> And in your mode what would happen if I set it to 3 and it
> only completes 2? Would one remain on the list?


As one can estimate the amount of shields available (stock + production) only the max. number you could reach with the shields available would be active. This number would further be restricted by the number of build slots.

Matthias Pfafferodt <syntron>
Project MemberIn charge of this item.
Wed 28 Oct 2009 05:48:29 PM UTC, comment #4:

> The problem I see is that this makes it rather unpredictable
> how many units will be build. Even if you have 2 or 3 build
> slots that does not mean you will build 2 or 3 units of each
> type. That depends on the surplus of shield.


This was planned as a possibility to use the production of big cities. Without this, these cities would accumulate shields with no possibility to use them. I restricted the possibility to units without population cost so that you can expect that will happen.

Would a checkbox, which is only active if such a unit is build be OK? Using the checkbox you could choose if 1,2,3...x units should be (tried to) build next turn. This would also be the visual indicator for this feature.

Matthias Pfafferodt <syntron>
Project MemberIn charge of this item.
Mon 26 Oct 2009 09:24:01 PM UTC, comment #3:

rebased to current trunk; fix call to notify_player()

(file #7123)

Matthias Pfafferodt <syntron>
Project MemberIn charge of this item.
Thu 22 Oct 2009 07:26:46 AM UTC, comment #2:

The problem I see is that this makes it rather unpredictable how many units will be build. Even if you have 2 or 3 build slots that does not mean you will build 2 or 3 units of each type. That depends on the surplus of shield.

So to build 10 armors I have to count the shields for each turn to see if 1, 2 or 3 armors will be build and put accordingly less armors into the build list. It also can become impossible to build just one of a unit. What am I to do with the surplus? Disband them again?

I think it would be simpler to use if the build slots where filled from the build list, advance the build list after every single unit build. At a minimum the list should advance if the same unit is present multiple times. E.g. if 3 armors are in the list and 3 armors are build the list should advance 3 units, not just one.

MfG
Goswin

Anonymous
Tue 20 Oct 2009 07:04:01 AM UTC, comment #1:

comment to patch #1235:

> About: [10/11] patch #1234 - more than one build slot for
> units
>
> When I add an Engineer, an Armor and Coinage to a big cities
> build list then I get 3 Engineers and 2 Armors. That is not
> what I would expect from the multiple build slots. I would
> expect it to build an Engineer in the first slot and an Armor
> in the second and then Coinage.


This patch is an experiment. Big cities have a large production. Even expensive buildings are finished in less than 5 turns. To use the production I added this feature. If a unit (without population cost) is in the production line, more than one unit of this type can be finished within the turn if there is enough production. This should only apply to the first item in the production line and only if this is a unit.

If you got 3 Engineers and 2 Armors something is wrong. In your example I would expect the following

Production line:

Engineer
Armor
Coinage

Production:

turn +1: up to 3 Engineers (depending on the production of the city)
turn +2: up to 3 Armors (depending on the production of the city)
turn +3: Coinage

(considering the experimental ruleset in patch #1236 and a city of size > 30)

For this patch, a display of the available production slots within the city dialog of the different clients is needed.

Matthias Pfafferodt <syntron>
Project MemberIn charge of this item.
Sat 08 Aug 2009 08:58:41 PM UTC, original submission:

more than one build slot for units

  • only for units with pop_cost = 0

As a city grows it can build more than one unit per turn (if there are enough shields)

=> compensates the reduced build capacity compared to the city size

Matthias Pfafferodt <syntron>
Project MemberIn charge of this item.

 

(Note: upload size limit is set to 1024 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by syntron (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 8 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Sat 27 Mar 2010 11:15:29 AM UTCsyntronStatusNone=>Done
      Open/ClosedOpen=>Closed
    Fri 26 Feb 2010 10:38:05 PM UTCsyntronAttached File-=>Added 20100226-trunk-more-than-one-build-slot-for-units.patch, #8305
      Assigned toNone=>syntron
      Planned Release=>2.3.0
    Mon 02 Nov 2009 10:59:37 PM UTCsyntronAttached File-=>Added build_slots20091102-0012-more-than-one-build-slot-for-units.diff, #7207
    Mon 26 Oct 2009 09:24:01 PM UTCsyntronAttached File-=>Added cityradius_sq20091026-0010-more-than-one-build-slot-for-units.diff, #7123
    Sat 08 Aug 2009 08:58:41 PM UTCsyntronAttached File-=>Added 0014-more-than-one-build-slot-for-units.patch, #6390
    Show feedback again

    Back to the top


    Powered by Savane 3.1-cleanup