[SOLVED] Problem with updating ruleset to 3.0: ExtraFlag

Various topics about the game, the website, or anything else Freeciv related that doesn't fit elsewhere.
Post Reply
User avatar
Corbeau
Elite
Posts: 1291
Joined: Mon Jan 13, 2014 11:13 pm

[SOLVED] Problem with updating ruleset to 3.0: ExtraFlag

Post by Corbeau »

When starting the game, I get this:

Code: Select all

Invalid requirement ExtraFlag | Local |  | present | ParadropFrom: bad type or name
"data\SIM30\game.ruleset" [actionenabler_paradrop_not_forest_base] has invalid or unknown req: "ExtraFlag" "ParadropFrom".
However, everything seems to be fine in the ruleset, especially since I simply copied stuff from Sandbox:

fame.ruleset:

Code: Select all

[actionenabler_paradrop_not_forest_base]
action = "Paradrop Unit"
actor_reqs    =
    { "type",      "name",         "range", "present"
      "UnitFlag",  "Paratroopers", "Local", TRUE
      "UnitState", "Transporting", "Local", FALSE
      "ExtraFlag", "ParadropFrom", "Local", TRUE
    }
target_reqs    =
    { "type",   "name", "range", "present"
      "TerrainFlag", "DifficultLanding", "Local", FALSE
    }
terrain.ruleset:

Code: Select all

extra_flags =
  { "name", "helptxt"
    _("ParadropFrom"), _("Units can paradrop from this tile.")
    _("DiplomatDefense"),
        ; /* xgettext:no-c-format */
        _("Diplomatic units get a 25% defense bonus in diplomatic fights.")
    _("IrrigationSource")
    _("AllowsFarmlandOnDesert")
  }
Any ideas what's wrong?

Of course, the Sandbox ruleset I coped this from works fine.
Last edited by Corbeau on Sun Oct 10, 2021 7:17 pm, edited 1 time in total.
--
* Freeciv LongTurn, a community of one-turn-per-day players and developers
* LongTurn Blog - information nexus with stuff and stuff and stuff
* Longturn Discord server; real-time chatting, discussing, quarrelling, trolling, gaslighting...
cazfi
Elite
Posts: 3077
Joined: Tue Jan 29, 2013 6:54 pm

Re: Problem with updating ruleset to 3.0: ExtraFlag

Post by cazfi »

Is that "extra_flags" within [control] section?

If you don't already run with deprecation warnings enabled, it might be a good idea; use commandline parameter --warnings.
User avatar
Corbeau
Elite
Posts: 1291
Joined: Mon Jan 13, 2014 11:13 pm

Re: Problem with updating ruleset to 3.0: ExtraFlag

Post by Corbeau »

cazfi wrote:Is that "extra_flags" within [control] section?
It wasn't, now is, problem solved! Thanks!
--
* Freeciv LongTurn, a community of one-turn-per-day players and developers
* LongTurn Blog - information nexus with stuff and stuff and stuff
* Longturn Discord server; real-time chatting, discussing, quarrelling, trolling, gaslighting...
Post Reply