Author: cazfi Date: Tue Jul 5 09:10:39 2016 New Revision: 33170 URL: http://svn.gna.org/viewcvs/freeciv?rev=33170&view=rev Log: By default, set extras 'buildable' property TRUE only if some of its causes indicate that units could build it.
See patch #6770 Modified: trunk/data/alien/terrain.ruleset trunk/data/civ1/terrain.ruleset trunk/data/civ2/terrain.ruleset trunk/data/civ2civ3/terrain.ruleset trunk/data/classic/terrain.ruleset trunk/data/experimental/terrain.ruleset trunk/data/multiplayer/terrain.ruleset trunk/data/ruledit/comments.txt trunk/data/sandbox/terrain.ruleset trunk/data/stub/terrain.ruleset trunk/server/ruleset.c Modified: trunk/data/alien/terrain.ruleset URL: http://svn.gna.org/viewcvs/freeciv/trunk/data/alien/terrain.ruleset?rev=33170&r1=33169&r2=33170&view=diff ============================================================================== --- trunk/data/alien/terrain.ruleset (original) +++ trunk/data/alien/terrain.ruleset Tue Jul 5 09:10:39 2016 @@ -645,7 +645,9 @@ ; rmreqs = requirements to remove the extra ; appearance_reqs = spontaneous appearance requirements ; disappearance_reqs = spontaneous disappearance requirements -; buildable = Can extra be built? Defaults to TRUE +; buildable = Can extra be built? Defaults to TRUE if extra has +; any causes indicating it can result from worker +; activity. ; build_time = how long it takes a unit to build this extra. ; Value of 0 (default) means that terrain- and ; build activity specific time is used instead. Modified: trunk/data/civ1/terrain.ruleset URL: http://svn.gna.org/viewcvs/freeciv/trunk/data/civ1/terrain.ruleset?rev=33170&r1=33169&r2=33170&view=diff ============================================================================== --- trunk/data/civ1/terrain.ruleset (original) +++ trunk/data/civ1/terrain.ruleset Tue Jul 5 09:10:39 2016 @@ -778,7 +778,9 @@ ; rmreqs = requirements to remove the extra ; appearance_reqs = spontaneous appearance requirements ; disappearance_reqs = spontaneous disappearance requirements -; buildable = Can extra be built? Defaults to TRUE +; buildable = Can extra be built? Defaults to TRUE if extra has +; any causes indicating it can result from worker +; activity. ; build_time = how long it takes a unit to build this extra. ; Value of 0 (default) means that terrain- and ; build activity specific time is used instead. Modified: trunk/data/civ2/terrain.ruleset URL: http://svn.gna.org/viewcvs/freeciv/trunk/data/civ2/terrain.ruleset?rev=33170&r1=33169&r2=33170&view=diff ============================================================================== --- trunk/data/civ2/terrain.ruleset (original) +++ trunk/data/civ2/terrain.ruleset Tue Jul 5 09:10:39 2016 @@ -850,7 +850,9 @@ ; rmreqs = requirements to remove the extra ; appearance_reqs = spontaneous appearance requirements ; disappearance_reqs = spontaneous disappearance requirements -; buildable = Can extra be built? Defaults to TRUE +; buildable = Can extra be built? Defaults to TRUE if extra has +; any causes indicating it can result from worker +; activity. ; build_time = how long it takes a unit to build this extra. ; Value of 0 (default) means that terrain- and ; build activity specific time is used instead. Modified: trunk/data/civ2civ3/terrain.ruleset URL: http://svn.gna.org/viewcvs/freeciv/trunk/data/civ2civ3/terrain.ruleset?rev=33170&r1=33169&r2=33170&view=diff ============================================================================== --- trunk/data/civ2civ3/terrain.ruleset (original) +++ trunk/data/civ2civ3/terrain.ruleset Tue Jul 5 09:10:39 2016 @@ -1042,7 +1042,9 @@ ; rmreqs = requirements to remove the extra ; appearance_reqs = spontaneous appearance requirements ; disappearance_reqs = spontaneous disappearance requirements -; buildable = Can extra be built? Defaults to TRUE +; buildable = Can extra be built? Defaults to TRUE if extra has +; any causes indicating it can result from worker +; activity. ; build_time = how long it takes a unit to build this extra. ; Value of 0 (default) means that terrain- and ; build activity specific time is used instead. Modified: trunk/data/classic/terrain.ruleset URL: http://svn.gna.org/viewcvs/freeciv/trunk/data/classic/terrain.ruleset?rev=33170&r1=33169&r2=33170&view=diff ============================================================================== --- trunk/data/classic/terrain.ruleset (original) +++ trunk/data/classic/terrain.ruleset Tue Jul 5 09:10:39 2016 @@ -1032,7 +1032,9 @@ ; rmreqs = requirements to remove the extra ; appearance_reqs = spontaneous appearance requirements ; disappearance_reqs = spontaneous disappearance requirements -; buildable = Can extra be built? Defaults to TRUE +; buildable = Can extra be built? Defaults to TRUE if extra has +; any causes indicating it can result from worker +; activity. ; build_time = how long it takes a unit to build this extra. ; Value of 0 (default) means that terrain- and ; build activity specific time is used instead. Modified: trunk/data/experimental/terrain.ruleset URL: http://svn.gna.org/viewcvs/freeciv/trunk/data/experimental/terrain.ruleset?rev=33170&r1=33169&r2=33170&view=diff ============================================================================== --- trunk/data/experimental/terrain.ruleset (original) +++ trunk/data/experimental/terrain.ruleset Tue Jul 5 09:10:39 2016 @@ -1008,7 +1008,9 @@ ; rmreqs = requirements to remove the extra ; appearance_reqs = spontaneous appearance requirements ; disappearance_reqs = spontaneous disappearance requirements -; buildable = Can extra be built? Defaults to TRUE +; buildable = Can extra be built? Defaults to TRUE if extra has +; any causes indicating it can result from worker +; activity. ; build_time = how long it takes a unit to build this extra. ; Value of 0 (default) means that terrain- and ; build activity specific time is used instead. Modified: trunk/data/multiplayer/terrain.ruleset URL: http://svn.gna.org/viewcvs/freeciv/trunk/data/multiplayer/terrain.ruleset?rev=33170&r1=33169&r2=33170&view=diff ============================================================================== --- trunk/data/multiplayer/terrain.ruleset (original) +++ trunk/data/multiplayer/terrain.ruleset Tue Jul 5 09:10:39 2016 @@ -1006,7 +1006,9 @@ ; rmreqs = requirements to remove the extra ; appearance_reqs = spontaneous appearance requirements ; disappearance_reqs = spontaneous disappearance requirements -; buildable = Can extra be built? Defaults to TRUE +; buildable = Can extra be built? Defaults to TRUE if extra has +; any causes indicating it can result from worker +; activity. ; build_time = how long it takes a unit to build this extra. ; Value of 0 (default) means that terrain- and ; build activity specific time is used instead. Modified: trunk/data/ruledit/comments.txt URL: http://svn.gna.org/viewcvs/freeciv/trunk/data/ruledit/comments.txt?rev=33170&r1=33169&r2=33170&view=diff ============================================================================== --- trunk/data/ruledit/comments.txt (original) +++ trunk/data/ruledit/comments.txt Tue Jul 5 09:10:39 2016 @@ -658,7 +658,9 @@ ; rmreqs = requirements to remove the extra\n\ ; appearance_reqs = spontaneous appearance requirements\n\ ; disappearance_reqs = spontaneous disappearance requirements\n\ -; buildable = Can extra be built? Defaults to TRUE\n\ +; buildable = Can extra be built? Defaults to TRUE if extra has\n\ +; any causes indicating it can result from worker\n\ +; activity.\n\ ; build_time = how long it takes a unit to build this extra.\n\ ; Value of 0 (default) means that terrain- and\n\ ; build activity specific time is used instead.\n\ Modified: trunk/data/sandbox/terrain.ruleset URL: http://svn.gna.org/viewcvs/freeciv/trunk/data/sandbox/terrain.ruleset?rev=33170&r1=33169&r2=33170&view=diff ============================================================================== --- trunk/data/sandbox/terrain.ruleset (original) +++ trunk/data/sandbox/terrain.ruleset Tue Jul 5 09:10:39 2016 @@ -1043,7 +1043,9 @@ ; rmreqs = requirements to remove the extra ; appearance_reqs = spontaneous appearance requirements ; disappearance_reqs = spontaneous disappearance requirements -; buildable = Can extra be built? Defaults to TRUE +; buildable = Can extra be built? Defaults to TRUE if extra has +; any causes indicating it can result from worker +; activity. ; build_time = how long it takes a unit to build this extra. ; Value of 0 (default) means that terrain- and ; build activity specific time is used instead. Modified: trunk/data/stub/terrain.ruleset URL: http://svn.gna.org/viewcvs/freeciv/trunk/data/stub/terrain.ruleset?rev=33170&r1=33169&r2=33170&view=diff ============================================================================== --- trunk/data/stub/terrain.ruleset (original) +++ trunk/data/stub/terrain.ruleset Tue Jul 5 09:10:39 2016 @@ -344,7 +344,9 @@ ; rmreqs = requirements to remove the extra ; appearance_reqs = spontaneous appearance requirements ; disappearance_reqs = spontaneous disappearance requirements -; buildable = Can extra be built? Defaults to TRUE +; buildable = Can extra be built? Defaults to TRUE if extra has +; any causes indicating it can result from worker +; activity. ; build_time = how long it takes a unit to build this extra. ; Value of 0 (default) means that terrain- and ; build activity specific time is used instead. Modified: trunk/server/ruleset.c URL: http://svn.gna.org/viewcvs/freeciv/trunk/server/ruleset.c?rev=33170&r1=33169&r2=33170&view=diff ============================================================================== --- trunk/server/ruleset.c (original) +++ trunk/server/ruleset.c Tue Jul 5 09:10:39 2016 @@ -3102,7 +3102,8 @@ } requirement_vector_copy(&pextra->disappearance_reqs, reqs); - pextra->buildable = secfile_lookup_bool_default(file, TRUE, + pextra->buildable = secfile_lookup_bool_default(file, + is_extra_caused_by_worker_action(pextra), "%s.buildable", section); pextra->build_time = 0; /* default */ _______________________________________________ Freeciv-commits mailing list Freeciv-commits@gna.org https://mail.gna.org/listinfo/freeciv-commits