I think, that multipliers should be able to not just point to player's data, but also other entity, like cities. Way to use: Maximum work time. Increase will increase production, but decrease city's health and cause unhappiness.
So, multipliers should have range and store one's value inside counter. Also, checkpoint is something odd in this case, so we must though how to separate this. Multipliers will only points to special counter type, called user-setable or multiplier.
We also should change name of multipliers (read later).
We shall introduce value calculation vector, which should replace value field of effects and also be part of new entity, called restriction.
For example:
start_value is value set by previous calculation of effects of the same type or - if it is first effect we calculate - some predefined value (dependent on effect type or 0 for restriction)
none req is always evaluated as true
I place stop_calculation to demonstrate way to stop calculation if reqs are fulfilled. In this case it does nothing - just place it at bottom to demonstrate end of list.
After each step of calculation and after end, result is passed to special range of requirement, called Value. Value could have some new reqs, like isAbove, isBellow, changedFromPrevious (for value of counter, but before any processing takes place).
And restriction is a new entity. It will have three requirements vector (+ value vector as effect). First is processed with old value of counter to check if change is possible. Second is processed with new value (calculated from value vector) to check if change is possible. But before first, additional is processed to check if restriction should apply.
I think, that multipliers should be able to not just point to player's data, but also other entity, like cities. Way to use: Maximum work time. Increase will increase production, but decrease city's health and cause unhappiness.
So, multipliers should have range and store one's value inside counter. Also, checkpoint is something odd in this case, so we must though how to separate this. Multipliers will only points to special counter type, called user-setable or multiplier.
We also should change name of multipliers (read later).
We shall introduce value calculation vector, which should replace value field of effects and also be part of new entity, called restriction. For example:
start_value is value set by previous calculation of effects of the same type or - if it is first effect we calculate - some predefined value (dependent on effect type or 0 for restriction)none req is always evaluated as true
I place stop_calculation to demonstrate way to stop calculation if reqs are fulfilled. In this case it does nothing - just place it at bottom to demonstrate end of list.
After each step of calculation and after end, result is passed to special range of requirement, called Value. Value could have some new reqs, like isAbove, isBellow, changedFromPrevious (for value of counter, but before any processing takes place).
And restriction is a new entity. It will have three requirements vector (+ value vector as effect). First is processed with old value of counter to check if change is possible. Second is processed with new value (calculated from value vector) to check if change is possible. But before first, additional is processed to check if restriction should apply.
Imagine: