Unit experience points

What would you like to see in Freeciv? Do you have a good idea what should be improved or how?
Post Reply
Ignatus
Elite
Posts: 644
Joined: Mon Nov 06, 2017 12:05 pm
Location: St.Petersburg, Russia
Contact:

Unit experience points

Post by Ignatus »

This idea is well known in the community but I have not found a topic dedicated to it, so: instead of random giving veteranship, make certain actions increase a counter of XP for a unit that will give a veteranship level after reaching some value. This way the veteranship comes more predictable and "fair". We can use the same counter another ways: e.g. introduce "Min_Experience" requirement and use it on "Convert" action enabler, that results in Battle for Wesnoth-like "level-ups". The more advanced promotions system from Civ4+ is not only more difficult to code, it can be controversial as making unit system effectively too complicated.

Gaining of the experience: for example, in Wesnoth you gain 1xp per enemy level for just surviving and 8xp/lvl for a kill. In Civ5, there are XP amounts gained from attack and defence in different types of combat (melee 5/4, ranged (~bombardment but answerable by another ranged unit) 2/2) , that are modified from buildings and policies, as well as starting XP bonuses; actions on barbarians can't increase XP over 30. We can introduce effects "Combat_against_xp" and "Defeat_xp" with requirements on the other side of the combat, and "Experience_build" for initial unit modifier. Also, we need to do something with xp after converting/upgrading a unit (at gaining veteranship, it continues to accumulate), maybe single game setting "Convert_experience_pct" is enough.
Ignatus
Elite
Posts: 644
Joined: Mon Nov 06, 2017 12:05 pm
Location: St.Petersburg, Russia
Contact:

Re: Unit experience points

Post by Ignatus »

My own idea of measuring experience for dangerous tasks is that ruleset authors may want a fraction f of novice units participating in them acquire promotion, then an action with survival probability p should give part of the XP required for the promotion proportional to log(p)/log(f) (since in some combats survival is very unlikely, this should be limited so that we won't get two upgrades at time, or a numeric overflow). So, a building that increase the effective first vet. rate to F should provide (log(F)/log(f)-1) part of the first threshold. In fact, this model does not take into account that a unit survived with low HP will often have more chances to be killed before it heals (and I don't know a mathematical model for it, probably it is highly ruleset and gaming style dependent), but keeping your units alive while using them is the skill the veteranship system is intended to reward. Thus, for battles
terminated by Combat_Rounds (even ones with participants effectively unkillable by each other) and for working on terrain there can also be deserved rewards.
Post Reply