xHeraklinesx Posted May 25, 2020 Share Posted May 25, 2020 I am trying to detect poison damage being done by the player to another NPC. The SKSE function GetResistance() doesnt seem to return PoisonResist as a possible value (although I cant seem to find the source code to check, and the creation kit wiki has no entry for it) Right now I am trying to detect via Keywords during an OnHit Event, but it only seems to work if I poison a bow and shoot. Doesnt work for melee attacks. Int Type = akSource.GetType()if Type == 46 || akAggressor.HasEffectKeyword(VendorItemPoison) Debug.Notification("IsPoison")endIfPotion TempPotion = akSource as Potionif TempPotion.IsPoison() || TempPotion.IsHostile() || akAggressor.HasEffectKeyword(VendorItemPoison) Debug.Notification("The enemy has " + Resistances[2] as Int + "% PoisonResist.")endIf I am just trying to test a bunch of conditions to see what sticks right now. Is there a specific reason why this wouldnt work for poisoned melee weapons? Or is there an alternative way to check for poison damage being done to an NPC by the player without Keywords or GetResistance() ? I am new to modding,so pardon my ignorance if there is something very obvious I am missing. Link to comment Share on other sites More sharing options...
Recommended Posts