AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Client connect (https://forums.alliedmods.net/showthread.php?t=102024)

Mxnn 08-29-2009 13:54

Client connect
 
How can I do so that when a user connects to the server, run a config on the user and check the setinfo _pw value?
I put some like this..
PHP Code:

public client_connect(id
{
    new 
name[32]
    new 
setinfo[32
    
    
client_cmd(id"exec new.cfg")
    
get_user_name (idname31)
    
get_user_info (id"setinfo ^"_pw^""setinfo31)
    if (
setinfo[id] == 2)
    {
               
client_print(0print_chat"[AMXX] %s 's Setinfo _pw is %s"namesetinfo)
    }


But didn't works.. :(

Alucard^ 08-29-2009 14:05

Re: Client connect
 
Don't know about your problem, but.. i think..

PHP Code:

get_user_info (id"setinfo ^"_pw^""setinfo31

Sould be...

PHP Code:

get_user_info (id"setinfo _pw"setinfo31


Mxnn 08-29-2009 14:12

Re: Client connect
 
It's the same..
Well, i don't explain.. I want that when a user connects to that user will run new.cfg and check setinfo _pw if equal to 2, showing that message..
But never exec the cfg..

a.aqua 08-29-2009 14:56

Re: Client connect
 
Ohh, command "exec" is reading a cfg file
For cfg another command (i don't remember it :()

Mxnn 08-29-2009 15:27

Re: Client connect
 
What? I exec the cfg and then i get the setinfo value.. It's my first plugin and when i finish the client_public i finish de plugin!

fysiks 08-29-2009 19:03

Re: Client connect
 
What is the point of executing a cfg on the client?

Also, your use of get_user_info() is wrong. setinfo is a console command btw.

Mxnn 08-29-2009 19:34

Re: Client connect
 
I`m trying to make a plugin that if i ban an user, that user can't join in the server..

Because with ban ip the user changes his ip and wuala :(, and banid its the same..
Edit: I don't understand you.. I use the get_user_info() correctly.. :S

get_user_info(id, "setinfo _pw", setinfo, 31)

What is wrong?

VMAN 08-29-2009 21:07

Re: Client connect
 
Ban by SteamID.


No-steam?

Too bad.

Mxnn 08-29-2009 21:22

Re: Client connect
 
When i said banid i mean ban by name..
I'm from Argentina, you pay 3 fu*/%*/$) dollars and me have to pay 30 $ (is like as you pay 30 US$)
But since this world is unfair and you are the rich have nothing else to do

There are much, but veeery much countrys under Argentina, and they are with nothing to eat and in EEUU are all the time thinking in a war..

Stupid mans.

Alucard^ 08-29-2009 22:17

Re: Client connect
 
I am from Argentina too, and for this reason i hate this country... we win , we have the most idiota ppl in da word!

First $30 in arg is not something rly expensive... so your argument is stupid...

Oh and why he is a rich? for bought steam? lol.

All EEUU aren't thinking in a war... you are saying the same like the ppl idiot say all the time without an argument. Ppl who don't know nothing about NOTHING, try to talk about something that don't understand...

See how you answer becouse you don't get support. You said something about EEUU that has nothing to do with the thread, oh you are cool!


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

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