Page 1 of 1

[SOLVED] Problem with updating ruleset to 3.0: ExtraFlag

Posted: Sun Oct 10, 2021 11:14 am
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.

Re: Problem with updating ruleset to 3.0: ExtraFlag

Posted: Sun Oct 10, 2021 7:10 pm
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.

Re: Problem with updating ruleset to 3.0: ExtraFlag

Posted: Sun Oct 10, 2021 7:17 pm
by Corbeau
cazfi wrote:Is that "extra_flags" within [control] section?
It wasn't, now is, problem solved! Thanks!