[Freeciv-tickets] [freeciv] #41120: Counter requirement type

Back to archive index
OSDN Ticket System norep****@osdn*****
Fri Mar 4 23:52:35 JST 2022


#41120: Counter requirement type

  Open Date: 2021-01-08 06:24
Last Update: 2022-03-04 23:52

URL for this Ticket:
    https://osdn.net//projects/freeciv/ticket/41120
RSS feed for this Ticket:
    https://osdn.net/ticket/ticket_rss.php?group_id=12505&tid=41120

---------------------------------------------------------------------

Last Changes/Comment on this Ticket:
2022-03-04 23:52 Updated by: lachu

Comment:

Reply To alienvalkyrie
In ai/default/daieffects.c, dai_can_requirement_be_met_in_city(): The VUT_COUNTER case should probably be grouped together with the other cases without sensible handling at the bottom.
Thanks. It should and I made an mistake. Maybe if somebody else will change code in other part, it will causes error.

In common/requirements.c, universal_number(): Should return the unique ID of the counter, so it can be retrieved via universal_by_number()/counter_by_id(). It would probably be sensible to add a function called counter_id or counter_number to counters.[ch] for this purpose.

Thanks. Big my mistake. I decided to ask you, what do you mean, but while typing this ,message, I saw to code and repair bug.
I will send path in few seconds.

---------------------------------------------------------------------
Ticket Status:

      Reporter: cazfi
         Owner: (None)
          Type: Patches
        Status: Open
      Priority: 5 - Medium
     MileStone: S3_2 d3f
     Component: General
      Severity: 5 - Medium
    Resolution: None
---------------------------------------------------------------------

Ticket details:

Add a new requirement type 'Counter'. Name of the requirement is name of the counter. Requirement works only at City range for now.
Add new 'checkpoint' int field to struct counter, and set it e.g. 5 for the City Owned counter. Requirement is fulfilled if the value of the requirement is at least checkpoint.
Test for example by introducing a ruleset rule that when city has been owned less than those 5 turns, it suffers extra unhappiness.


-- 
Ticket information of Freeciv project
Freeciv Project is hosted on OSDN

Project URL: https://osdn.net/projects/freeciv/
OSDN: https://osdn.net

URL for this Ticket:
    https://osdn.net/projects/freeciv/ticket/41120
RSS feed for this Ticket:
    https://osdn.net/ticket/ticket_rss.php?group_id=12505&tid=41120



More information about the Freeciv-tickets mailing list
Back to archive index