An idea for the effects managing

What would you like to see in Freeciv? Do you have a good idea what should be improved or how?
Post Reply
User avatar
Alien Valkyrie
Elite
Posts: 513
Joined: Sun Feb 10, 2013 10:21 pm
Location: Stuttgart, Germany

An idea for the effects managing

Post by Alien Valkyrie »

This idea is something that would make things easier for ruleset creators when handling effects.
The plan is to make it possible to create custom values by defining something like "Barracks_Effect" in the beginning of the file and later setting it as effect_*.name(the "output" of an effect). It could be used as requirements for other effects. For example, instead of having Barracks, Barracks II and Barracks III each giving the Veteran_Build and HP_Regen effects, they would give Barracks_Effect, which would then give Veteran_Build and HP_Regen. This would of course be useless if there's only one building giving those specifc effects, but for larger numbers doing the same, it would reduce the number of effects required. And if you suddenly say "Hey, how about increasing the chance of becoming a veteran when defending a city with barracks", you wouldn't have to add effect_barracks_2, effect_barracks_ii_2 and effect_barracks_iii_2, but only effect_barracks_effect_2. All in all, it would reduce the number of effects required if multiple conditions cause the same things.
~ AVL
Post Reply