Hi, I am wanting to create an RPG games that basically involves people getting isekaied into their D&D champaign. And I want emulate some D&D components for the game.
Basically, what is that instead of using the basic Attack, Defence, etc stats, I want to use my own stats and to be able to adjust the formula for hitting and damage to be customizable in those stats, as well as having those skills be able to adjust when equipping and unequipping items.
For example you have skills for Strength, Dexterity , Constitution, Intelligence, Wisdom, and Charisma.
And I want the formula on if the attack hits or not, and for much dependent on your's and the enemies status.
For example:
The formula for a hit or miss would be
While a damage for a hit would be
While also leaving room for having different resistances and weakness depending on enemy or player types, such as undead monster turns the
And the formula may change depending on the weapon or skill used, such as bows using dexterity, holy spells goes against the monster's wisdom ability, etc.
Any suggestions would be helpful.
Basically, what is that instead of using the basic Attack, Defence, etc stats, I want to use my own stats and to be able to adjust the formula for hitting and damage to be customizable in those stats, as well as having those skills be able to adjust when equipping and unequipping items.
For example you have skills for Strength, Dexterity , Constitution, Intelligence, Wisdom, and Charisma.
And I want the formula on if the attack hits or not, and for much dependent on your's and the enemies status.
For example:
The formula for a hit or miss would be
(player.strength/2 + player.str_weapon_bonus - 10 + ceil(rand*20)) >= enemy.dexterity/2 + 10While a damage for a hit would be
player.strength/2 - 10 + weapon_damage_bonus + ceil(rand*6)While also leaving room for having different resistances and weakness depending on enemy or player types, such as undead monster turns the
ceil(rand*6) into a 2*ceil(rand^6)And the formula may change depending on the weapon or skill used, such as bows using dexterity, holy spells goes against the monster's wisdom ability, etc.
Any suggestions would be helpful.