Page 1 of 1

Forget about hit chance

Posted: Mon Nov 05, 2018 11:53 am
by Liebranca
Hey people,

I reckon the title says it all; I want to bypass dicerolls -- have hit chance default to 100% and call it a day
This means replacing the formula with a constant and either disposing of the 97% cap or turning it up to a hundred
Now, I happen to be a programmer but I don't think that's even necessary here. This is just tweaking values
So if anyone can tell me which files I want to be looking at, that'd be great

Cheers

Re: Forget about hit chance

Posted: Mon Nov 05, 2018 12:52 pm
by pango
Hi Liebranca,
After some searching, my best bet would be
https://github.com/Interkarma/daggerfal ... er.cs#L757

Re: Forget about hit chance

Posted: Mon Nov 05, 2018 1:27 pm
by Hazelnut
Yeah mods can override most of the combat formula, I added that for InconsolableCellist a while back as he plans to do a combat tuning mod.

I'm really not sure why you would want to remove hit chance completely however, since DF is an RPG and not a action combat game. Success of actions in RPGs should always be based on the character skill, with player making decisions about what actions to take. (e.g. retreat, but at a speed based on character stats) Anyway, you can make it work however you want and should be able to tune damage etc to compensate for 100% hit chances.

An example of overriding one of the formula can be found in the Archaeologists mod on my github.

Code: Select all

        // Override default formula
        FormulaHelper.formula_1pe_1sk.Add("CalculateEnemyPacification", CalculateEnemyPacification);

        private static bool CalculateEnemyPacification(PlayerEntity player, DFCareer.Skills languageSkill)
        {
               Debug.Log("Pacification override!");
        }

Re: Forget about hit chance

Posted: Mon Nov 05, 2018 3:01 pm
by Liebranca
Lovely, thank you both. I'll see what I come up with.

Re: Forget about hit chance

Posted: Tue Dec 11, 2018 2:27 pm
by mtrredux
Hazelnut wrote: Mon Nov 05, 2018 1:27 pm Yeah mods can override most of the combat formula, I added that for InconsolableCellist a while back as he plans to do a combat tuning mod.

I'm really not sure why you would want to remove hit chance completely however, since DF is an RPG and not a action combat game. Success of actions in RPGs should always be based on the character skill, with player making decisions about what actions to take. (e.g. retreat, but at a speed based on character stats) Anyway, you can make it work however you want and should be able to tune damage etc to compensate for 100% hit chances.
There was a mod for morrowind that gave 100% hit chance but made damage variable based on skill.

That would a mix between action and RPG RNG