AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   General (https://forums.alliedmods.net/forumdisplay.php?f=7)
-   -   czero server still not fully working (https://forums.alliedmods.net/showthread.php?t=211276)

striker07 03-20-2013 07:59

czero server still not fully working
 
My czero servers are still not fully operating.
I have replaced metamod to 1.21-AM and amx tot 1.8.2.

Yet half of my plugins dont seem to work like they should or just dont work at all.

I have tried replacing my cstrike amx modules to the 1.76D version of amx but this didnt fix my problem.

server logs arent really clear about the problems neighter, altough some plugins give lots of problems.
also have problems with get_pcvar, something seems to be changed to it i think and its not working properly anymore:
Code:

L 03/20/2013 - 12:56:50: Invalid CVAR pointer
L 03/20/2013 - 12:56:50: [AMXX] Displaying debug trace (plugin "napalm_nades.amxx")
L 03/20/2013 - 12:56:50: [AMXX] Run time error 10: native error (native "get_pcvar_num")
L 03/20/2013 - 12:56:50: [AMXX] [0] napalm_nades.sma::event_round_start (line 289)

Spoiler

Help is grately appreciated

YamiKaitou 03-20-2013 08:00

Re: czero server still not op
 
Post in the plugin's thread

striker07 03-20-2013 08:10

Re: czero server still not op
 
Quote:

Originally Posted by YamiKaitou (Post 1916162)
Post in the plugin's thread

Are you sure its not my server?
green chat doesnt work anymore neighter at all and in many plugins get_pcvar isnt working properly.


and many other plugins dont work properly aswell, are you sure that its related to the plugin and not some config in my server or something else related to the server?

YamiKaitou 03-20-2013 08:11

Re: czero server still not fully working
 
Seeing as you have not provided anything about the other plugins and only that 1 error message, your issue is related to that plugin. We cannot answer other issues you have not made us aware of

striker07 03-20-2013 18:43

Re: czero server still not fully working
 
I think its a problem with amx becous it started showing this when i installed version 1.8.2,
Did something change with register_cvar || get_pcvar_... ?

It always happens on round start event:
console logs:


And the usage is correct:
PHP Code:

new Float:g_nade_give_time;
new 
cvar_spawn_nade_delay;
 
public 
plugin_init()
{
    
register_logevent("EventRoundStart"2"1=Round_Start");
 
    
cvar_spawn_nade_delay register_cvar("hnsxp_spawn_nade_delay""11.0");
}
 
public 
EventRoundStart()
{
    
g_nade_give_time get_pcvar_float(cvar_spawn_nade_delay); // line 705



YamiKaitou 03-20-2013 19:09

Re: czero server still not fully working
 
Does the cvar even exist?

^SmileY 03-21-2013 10:38

Re: czero server still not fully working
 
Its an normal problem, you used a get_cvar_pointer or get_pcvar_pointer its safe to use only in HLDS native cvars, like sv_restart and others..

For get a correctly cvars from anoter plugin, use a register_cvar with a same cvar in firt and others plugins.

I tested and concludes its better to use register_cvar("hnsxp_spawn_nade_delay") for example, and get_pcvar_num normally :)

striker07 03-21-2013 18:02

Re: czero server still not fully working
 
Quote:

Originally Posted by YamiKaitou (Post 1916605)
Does the cvar even exist?

No cvar isnt registered by server for some reason :s
Quote:

Originally Posted by ^SmileY (Post 1916933)
Its an normal problem, you used a get_cvar_pointer or get_pcvar_pointer its safe to use only in HLDS native cvars, like sv_restart and others..

For get a correctly cvars from anoter plugin, use a register_cvar with a same cvar in firt and others plugins.

I tested and concludes its better to use register_cvar("hnsxp_spawn_nade_delay") for example, and get_pcvar_num normally :)

What do you mean? i'm only getting cvars in the plugin, from the same plugin, not an external plugin or hlds server cvar.
Look at the example i posted in my previous post, thats how its used when the error shows.

In the napalm_nades or nade modes plugin, the native is used with clamp:
PHP Code:

new variable;
 
public 
blabla(thisthatwhatever)
{
    
variable clamp(get_pcvar_num(my registered cvar from same pluginminimum cvar valluemaximum cvar vallue);


There is also a problem with making colored text, with register_clcmd and some cvars are not being registered for some reason,
when i go ingame and check the cvar it sais:
[AMXX] Unknown cvar: my_cvar
Spoiler

And when i recompiled my plugin, the size of the plugin was downsized from 42kB to 20kB so I'm pretty sure there are many other things that stopped working since the update.
The evidence is undeniable imo

DS 03-21-2013 22:29

Re: czero server still not fully working
 
I can't seem to reproduce the issues you're describing. The code you gave for registering a cvar and using get_pcvar_float when a round starts works fine here on a Linux CZ server.

Could you please show the output of amxx plugins and and amxx version?

Also, the smaller plugin size that you are seeing is very much intentional and shouldn't be a problem. The compiler used to produce 32-bit and 64-bit code (for AMD64 servers). With 1.8.2, we decided to finally remove the 64-bit code generation since AMD64 servers haven't been supported in a long time. So the compiled plugin size is going to be much smaller.

^SmileY 03-22-2013 07:17

Re: czero server still not fully working
 
Quote:

L 03/20/2013 - 12:56:50: Invalid CVAR pointer
Its a get_cvar_pointer for me.

>> g_iMaxPlayers ?

Post full code please :P

ps. i had a similar problem but after the amxmodx removes amd 64 support, its solved using a stable version of amxmodx, try to not use amxmodx HG builds

http://forums.alliedmods.net/showthread.php?t=211047


All times are GMT -4. The time now is 13:03.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.