It works (mostly) right with NPCs, who have a bonus HP data field that can be manipulated. Oddly, nMax + 10 was adding 11 HPs to the NPC I tested it with though. I couldn't get it to work at all with a PC.
NWNXFuncs_SetHitPointsByLevel(object oCreature, int iHP, int iLevel) -- that one will work for PCs, but I'm not sure you can use that to raise the HPs beyond what their max was at a given level without issues.
I think the particular check I'm thinking of is only done at level ups though, so with a level 40 character that might not ever become an issue.
Edit: This one might be useful as well, but I've never tried it.
void NWNXFuncs_ModHitPointsByLevel(object oCreature, int iHPMod, int iLevel);
Modifié par Failed.Bard, 23 septembre 2011 - 09:29 .