AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Get ip in orpheu (https://forums.alliedmods.net/showthread.php?t=185438)

Stereo 05-17-2012 13:39

Get ip in orpheu
 
Hi, i'm trying lately how to get the ip of the user when orpheu call Sv_ClientConnect but I searched a lot and I don't found how, i have this:

PHP Code:

#include <amxmodx>
#include <orpheu>
public plugin_init()    
OrpheuRegisterHookOrpheuGetFunction"SV_ConnectClient" ), "OnSV_ConnectClient" );

public 
OrpheuHookReturn:OnSV_ConnectClient( )
{
//Hello


Someone know? Thanks

Napoleon_be 05-17-2012 13:45

Re: Get ip in orpheu
 
why using orpheu if you just can use client_connect or client_putinserver?

Stereo 05-17-2012 13:47

Re: Get ip in orpheu
 
Because I need to check the connection as soon as possible

Liverwiz 05-17-2012 15:04

Re: Get ip in orpheu
 
does get_user_ip ( index, ip[], len, [ without_port ] ) not work?

I've never heard about Orpheu.....but you're using amxmodx

<VeCo> 05-17-2012 15:22

Re: Get ip in orpheu
 
I think this is called before sending client data like ip to the server, so it's not possible to get player's ip. (I'm not really sure, though)

ConnorMcLeod 05-17-2012 15:31

Re: Get ip in orpheu
 
Then, hook FM_ClientConnect

Args are : ClientConnect(index, const szName[], const szAddress[], szRejectReason[128])

where szAddress is IP

Stereo 05-18-2012 08:52

Re: Get ip in orpheu
 
Don't work, fakemeta runs later thank orpheu :S

Liverwiz 05-18-2012 08:58

Re: Get ip in orpheu
 
Wait a second....if orpheu is meant to run before everything else....wouldn't it have a get IP function built in? One would hope so......but i don't have a clue.

Or get awesome and write the inc youreself! :twisted:

ConnorMcLeod 05-18-2012 10:21

Re: Get ip in orpheu
 
Quote:

Originally Posted by Stereo (Post 1711322)
Don't work, fakemeta runs later thank orpheu :S

It's at the same time.

Stereo 05-19-2012 05:50

Re: Get ip in orpheu
 
Don't work for me, something else?


All times are GMT -4. The time now is 00:22.

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