die Feder {l Wrote}:1. How to create different formulas for different requirements, which are balanced?
It is a problem of math. I can use different formulas and show the range of values for balanced damage calculation. There have to be one or more values in the formule, which make the calculation scalable. If not i will add one.
At the end i want to have one or more formulas for diffenrent grow rates of values like defence or attack.
Mathematically in general case you get a vector function of a vector variable.
I.e. you have 'input vector' of character's stats, skills and choosen attack style/spell & other conditions (like amount of light in the dungeon), enemy stats and resistances, etc.
And you have the output vector of effective damage to enemy health & armor, cost in stamina/mana/etc, damage to attacker's weapon.
The problem of balance is:
a) to match the stats & items curve to the enemy strenghts (i.e. that the game would be hard according to some difficulty curve, but not easy or impossible in the end).
b) to make the game interesting (i.e. not 'click him to death' but choosing the right strategy whether turn-based or in realtime action) - to make the game of skill and knowledge, but not of simply 'math matching' of the player's level and monster's level.
2. How to integrate the calculation.
At the beginning I can start using excel so I can easily test the formulas.
Then I want to create a kind of code generator. This generator creates the code depending on the diffenrent parameters (attack, defense...), the growth rate and other information. This code can be integrated in the game and changed es you want. Therefore I have to create the code in different languages.
Alternatively I use an IPC protocol or any other technique for the communication to my tool. The integration might be easier this way, but you can't modify the calculation, so I have to cover all the different requirements.
Excel/LibreOfficeCalc is a good stuff. But it is very limited in case of a complex system development.
I.e. in Decoherence I have 6 perks per each action, which add an effect or modify the efficiency of the primary action. Each action has a different set of perks. I can't imagine how this stuff can be done in excel - only calculating the basic damage.
On the other hand, if you speak of an universal system - then it's not going to be too complex, so a single formula (with little if-s case-s) would be fine.
Just an advice - avoid % resistances which lead to 'possible cheating' (like getting 120% resistance to damage). It's fine for poison resistance, but 100% fire resistance would eliminate threat from fire-breathing enemies at volcano map, and: a) make the player collect a set of m% resistance armor and b) reduce the value of those maps meant to be hard to zero if the player 'knows in advance' what waits for him and collects an appropriate armor set.