Thread: [Solved] amxx 1.9 crash
View Single Post
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 10-17-2018 , 03:43   Re: amxx 1.9 crash
Reply With Quote #2

You misunderstand the use of bind_pcvar_* natives.
They bind a cvar to a variable. Meaning that variable will contain the actual cvar's value in real time. This is NOT a cvar handle. You can't set a value from that.

To set a cvar with set_pcvar_num(), you still need to retrieve the handle from create_cvar() and using that value.
You can also use set_cvar_num(), it doesn't matter.
__________________

Last edited by Arkshine; 10-17-2018 at 03:45.
Arkshine is offline