Raised This Month: $ Target: $400
 0% 

Was I fault ? it's can't work ?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
rosetattoo
Junior Member
Join Date: Mar 2007
Old 10-19-2007 , 05:08   Was I fault ? it's can't work ?
Reply With Quote #1

/*
*
* lock ex_interp 0.01 when client cavr ex_interp >0.01
*
* Version: 1.0
*
*
* Purpose: Flashhh! wants it.
*
*/
#include <amxmodx>
#include <amxmisc>
public plugin_init()
{


register_plugin("SetCommands", "ak-47", "1.1")
}

public client_putinserver(id)

{
if (! is_user_bot (id) && ! is_user_hltv (id))
{
new exinterp[32]
get_user_info(id,"ex_interp",exinterp,31)
//
//when print exinterp , find it's null ,I don't konw why
//so it will not work at if (str_to_float(exinterp) > 0.01) ,why
if (str_to_float(exinterp) > 0.01)
{
console_cmd(id, "ex_interp 0.01")
return PLUGIN_HANDLED
}

}


return PLUGIN_HANDLED
}
rosetattoo is offline
rosetattoo
Junior Member
Join Date: Mar 2007
Old 10-19-2007 , 05:13   Re: Was I fault ? it's can't work ?
Reply With Quote #2

I don't know why I can't get the value of client ex_interp setting, why the exinterp[32] is null, can somebody tell me ?
rosetattoo is offline
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 10-19-2007 , 05:16   Re: Was I fault ? it's can't work ?
Reply With Quote #3

Use query_client_cvar native instead.
ConnorMcLeod is offline
rosetattoo
Junior Member
Join Date: Mar 2007
Old 10-20-2007 , 03:38   Re: Was I fault ? it's can't work ?
Reply With Quote #4

ok I'll have a try !
rosetattoo is offline
rosetattoo
Junior Member
Join Date: Mar 2007
Old 10-20-2007 , 04:40   Re: Was I fault ? it's can't work ?
Reply With Quote #5

#include <amxmodx>

public plugin_init()
{
register_plugin("test", "1", "PM");
}

public client_connect(id)
{
if (!is_user_bot(id))
query_client_cvar(id, "rate", "cvar_result_func");
}

public cvar_result_func(id, const cvar[], const value[])
{
new name[32];
get_user_name(id, name, 31);

log_amx("Client %d(%s)'s rate is ^"%s^"", id, name, value);
}

the plugin can't run . console_chat say " debug error ~!"

Last edited by rosetattoo; 10-20-2007 at 05:11.
rosetattoo is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 01:23.


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