Change the Haste percent

Was just wondering if anyone knew how to modify the haste percent of melee, ranged and spell?

I know the code is here. I’ve tried this but it didn’t work…


void ApplyPercentModFloatValue(uint16 index, float val, bool apply) { float value = GetFloatValue(index); ApplyPercentModFloatVar(value, val, apply); if(apply && (index == 17 || index == 18 || index == 19) && value > 130.86f) value = 130.86f; SetFloatValue(index, value); }

4th post asking for help and no one wants to help?

Random guess, I am pretty sure you want to change “130.86f”. Even if I have no idea what index is supposed to do.

Index is supposed to call the Enum. So 17 is CR_HASTE_MELEE. In order for me to use the Enum though I need to call “Unit.h”, but then I get loads of errors.