Making a custom race have double damage with any melee weapon?

Started by zloiiojik, December 25, 2018, 10:07:03 AM

Previous topic - Next topic

zloiiojik

Greetings everyone who bothered enough to look into this question =D

     Im rather inexperienced in modding, aside from flat modification of Xml files to my liking, but im trying to remedy that (rather poorly though...) and one of the problems I came across while learning about race creation was that no matter what I did, i couldnt give the race a melee damage modifier.

     The essence of what im trying to do is: the race, generally, is almost twice the size of humans and it really bothered me that, with all else being equal, they actually do exactly the same ammount of weapon damage as a regualr human. So what I want to do is, I want to give the entire race a boost in melee that is applied to any tool they are using, be it bare fists, a club, or a pike. Like, a simple club does 5 damage, but in their hands it does 10.

     So far I have hit a brick wall. I tried modifing StatBases, no effect. I tried changing race-specific traits - no effect. I tried using hedifs, but that  failed catastrofically one the very first attempt, so I decided to leave that alone for now  ;D. The closest thing I found to what Im tryin to do is the global world scenario modifier that boosts all melee damage persentage. But I failed to find a way to make it modify one race only.

     So ... If thats not all too much of a bother, I would humbly ask for help and some new ideas regarding the matter.

BrokenValkyrie

If I remember correctly, its not possible due to way melee is calculated. Melee damage is only affected by base weapon damage and material quality. Melee skills and brawler trait only affect chance of hitting.

In the past, I wanted to rewrite melee damage. Because prosthetic does not enhance it. There probably a reason behind the set melee damage.

You'll most likely have to write harmony code and intercept the melee damage calculation.

zloiiojik

I see... well, I suspected as much.

Thanks for the reply, guess ill have to look into how the harmony works when I have time then.

Mehni


public float meleeDamageFactor = 1f;

In the LifeStageDefs.

zloiiojik

Wow... I actually never thought about the LifeStagesDefs modifications! Thanks alot for the advice, gona test it out as soon as possible!

P.S. Well... my joy was short-lived... tried it out - no effect so far. A few more tests are needed though...