You can get the user's current knife name:
PHP Code:
new szKnife[32]
crxknives_get_attribute_str(id, "NAME", szKnife, charsmax(szKnife))
if(equal(szKnife, "Drednova"))
{
// your code here...
}
Actually now that I looked at my code again, I found out I did actually include the native you originally needed. It's the same one as above, but setting the last argument to "false" will treat the id as a knife index instead of player index. Check the documentation here -
https://amxx-bg.info/api/crxknives/c..._attribute_str
But for your case it's better to directly get the user's knife name just like shown in the code above.
PS: you might wanna consider checking if the knife has a certain attribute instead of hardcoding the abilities. This way you can use the same ability on other knives and/or with different values.
__________________