任务单 #41813

"PlayerState" requirement

开放日期: 2021-03-19 23:07 最后更新: 2024-01-04 07:39

报告人:
属主:
状态:
关闭
组件:
里程碑:
优先:
5 - Medium
严重性:
5 - Medium
处理结果:
Fixed
文件:
2

Details

Would be good to have a new req type for player-wide special states. Possible state names:

  • "RevoltedThisTurn" - ​some governments provide turn-end bonuses (e.g. increased trade) and another mid-turn ones (e.g. increased veteran chances). Player that has Statue of Liberty or just have finished revolen this turn can change governments for free and exploit it a lot, so let some bonuses be available only when the dust settles (note: AI democracy regulary "fails" for city mismanagement, as long as AI has handicap for it we should not test this req to it in these cases.)
  • "HasCapital" - for mandatory reqs for certain actions but might be used in other cases. BTW primary capital site worth caching.
  • "IsBarbarian" (and/or "IsLandBarbarian", "IsSeaBarbarian", "IsAnimal") - ​to replace unreliable "NationGroup", "Barbarian" req for testing if a player is a barbarian, since in Longturn people who take cool Pirates flag regulary suffer from unwanted effects.
  • "ScienceNonNegative" - ​for combining with bulbs cost of tech stealth, disable tech stealth when you have yet to sort out what you have stolen before.

edit: Also, considering civil war effect for civ1/civ2 rulesets compatibility, we should make local ranged requirement "HasMore(Less)Cities" and "HasMore(Less)Score" (that tests if the capital conqueror passed as other_player is in range), and similar local range variant for "IsBarbarian" (maybe other values also should test other_player when applied as "Local")

任务单历史 (3/16 Histories)

2021-03-19 23:07 Updated by: ihnatus
  • New Ticket ""PlayerState" requirement" created
2021-03-23 05:05 Updated by: ihnatus
  • Details Updated
2021-03-23 05:18 Updated by: cazfi
评论

Longturn people who take cool Pirates flag regulary suffer from unwanted effects.

I think that is intentional local modification by LT to make Pirates playable while they still are barbarians.

2021-11-08 09:41 Updated by: cazfi
评论

Reply To ihnatus

Player that has Statue of Liberty or just have finished revolen this turn can change governments for free and exploit it a lot, so let some bonuses be available only when the dust settles

I think that for this the engine should enforce some rules, and not leave it to ruleset to plug every possible exploit. This could work similar to multiplier changes that can be chosen during the turn freely, but are activated only at turn change (it has two variables; one that is the really active value, and second that tells what value user wants to activate in the next turn change)
2022-01-12 02:16 Updated by: cazfi
评论

Reply To cazfi

Reply To ihnatus

Player that has Statue of Liberty or just have finished revolen this turn can change governments for free and exploit it a lot, so let some bonuses be available only when the dust settles

I think that for this the engine should enforce some rules, and not leave it to ruleset to plug every possible exploit. This could work similar to multiplier changes that can be chosen during the turn freely, but are activated only at turn change (it has two variables; one that is the really active value, and second that tells what value user wants to activate in the next turn change)

-> #43604

2022-01-12 02:17 Updated by: cazfi
2022-08-27 23:25 Updated by: cazfi
评论

Somewhat overlapping (but not replacement) idea would be "PlayerFlag" requirement type. The benefit of PlayerFlag over PlayerState would be that requirement system would automatically gain access to each new flag added (no further implementation needed once we have the generic flag checking in place). Each PlayerState type would need to be implemented separately.

2023-10-01 14:07 Updated by: cazfi
评论

Reply To cazfi

Somewhat overlapping (but not replacement) idea would be "PlayerFlag" requirement type.

-> #45666

2023-10-16 13:51 Updated by: cazfi
  • 属主 Update from (无) to cazfi
  • 处理结果 Update from to Accepted
评论

Attached patch that supports just "Barbarian" state. Other states to be added in separate tickets.

2023-10-16 14:01 Updated by: cazfi
评论

New version, with README.effects changes added.

2023-10-22 18:53 Updated by: cazfi
  • 状态 Update from 开启 to 关闭
  • 处理结果 Update from Accepted to Fixed
2023-10-22 19:03 Updated by: cazfi
评论

"HasCapital" -> #48886
"PlayerState" "Barbarian" ruleset changes -> #48887

2023-12-29 06:57 Updated by: cazfi
评论

Reply To ihnatus

* "ScienceNonNegative" - ​for combining with bulbs cost of tech stealth, disable tech stealth when you have yet to sort out what you have stolen before.

Maybe separate "MinAccumulatedBulbs" requirement type would be more generally usable?

2024-01-04 07:39 Updated by: cazfi
评论

Reply To cazfi

Reply To ihnatus

* "ScienceNonNegative" - ​for combining with bulbs cost of tech stealth, disable tech stealth when you have yet to sort out what you have stolen before.

Maybe separate "MinAccumulatedBulbs" requirement type would be more generally usable?

-> https://redmine.freeciv.org/issues/122

编辑

Please login to add comment to this ticket » 登录名