CVAR Problem
I made a PCVar, and then when I try to get it's value, it always returns 0.
When I retrieve it as a stirng, it returns the modelname of something else I have in my plugin. PHP Code:
I never set the cvar to the modelname. |
Re: CVAR Problem
Try moving the server_print() to somewhere else like plugin_cfg() or something after declaring the cvar.
|
Re: CVAR Problem
Still zero. :(
I tried with a local variable in init and it works fine For some reason with the global variable taht I declared it does not work. |
Re: CVAR Problem
Quote:
Show your code. |
Re: CVAR Problem
I think initializations and init should be suffice.
PHP Code:
|
Re: CVAR Problem
Have you check pointer values? Have you tried with a global variable in a plugin all alone (nothing else, just one include, one function, one pointer, one cvar)?
|
Re: CVAR Problem
I have, and it works fine. I will send you the codde through a PM, if you could see what the problem is?
|
Re: CVAR Problem
More Info:
When I retrieve it as a string, I get this as the value: "plmodels/knife/p_katana.mdl" |
Re: CVAR Problem
Bizarre. I don't know where to go with that. Maybe someone else can figure it out.
|
Re: CVAR Problem
I tested your code:
Code:
#include <amxmodx>Quote:
|
| All times are GMT -4. The time now is 19:59. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.