Zzyxzz Posted January 21, 2017 Posted January 21, 2017 Hello, i got a small problem.... When i check in an onHit Event, on a hunting rifle that has been converted to .50 with: haskeyword(dn_HasReceiver_Converted50) it fails.I checked it ingame with the console/wornhaskeyword and it returns 1/true Seems like, keywords added by object mods, are not detected by haskeyword. Is there a workaround? Thanks,Zzyxzz
shavkacagarikia Posted January 21, 2017 Posted January 21, 2017 Have you tried using wornhaskeyword() instead?
Zzyxzz Posted January 21, 2017 Author Posted January 21, 2017 On 1/21/2017 at 5:20 PM, shavkacagarikia said: Have you tried using wornhaskeyword() instead? This works. Checking the weapon directly will return false, BUT you have to check the actor directly! Bad:(akaggressor as actor).getequippedweapon(0).haskeyword(KeywordAddedByObjectMod) Better:(akaggressor as actor).wornhaskeyword(KeywordAddedByObjectMod) As reference for others. Thanks
jags78 Posted November 21, 2019 Posted November 21, 2019 Was struggling with the same problem. Thx for the reference.
Recommended Posts