Raised This Month: $51 Target: $400
 12% 

how to get players IP?


Post New Thread Reply   
 
Thread Tools Display Modes
DigiSoft
BANNED
Join Date: Feb 2009
Old 01-06-2010 , 13:29   Re: how to get players IP?
Reply With Quote #11

OK so I've managed to debug it and I get this

utlmemory.h (322) : Assertion Failed: IsIdxValid(i)

Ok so I've debugged utlmemory.h and this is where it crashes;

Quote:
//-----------------------------------------------------------------------------
// Is element index valid?
//-----------------------------------------------------------------------------
template< class T >
inline bool CUtlMemory<T>::IsIdxValid( int i ) const
{
return (i >= 0) && (i < m_nAllocationCount);
}
But why? My index is wrong?

Last edited by DigiSoft; 01-06-2010 at 13:36.
DigiSoft is offline
frostschutz
Member
Join Date: Dec 2009
Old 01-06-2010 , 13:44   Re: how to get players IP?
Reply With Quote #12

not sure if this is of any help (beginner myself), but the ip is also given as a parameter in the player connect hook if I remember correctly. At least I got the IP without ever doing any netinfo->GetAddress()...
frostschutz is offline
DigiSoft
BANNED
Join Date: Feb 2009
Old 01-06-2010 , 13:54   Re: how to get players IP?
Reply With Quote #13

Quote:
Originally Posted by frostschutz View Post
not sure if this is of any help (beginner myself), but the ip is also given as a parameter in the player connect hook if I remember correctly. At least I got the IP without ever doing any netinfo->GetAddress()...
Yes I know but I have loop in GameFrame that runs on every 5 minutes and checks IPs on all players. That's why I am using this. And I still can't find solution.

Server crashes
DigiSoft is offline
Keeper
Senior Member
Join Date: Nov 2006
Old 01-06-2010 , 13:55   Re: how to get players IP?
Reply With Quote #14

Did you start at 1 or 0?
Keeper is offline
DigiSoft
BANNED
Join Date: Feb 2009
Old 01-06-2010 , 14:12   Re: how to get players IP?
Reply With Quote #15

Quote:
Originally Posted by Keeper View Post
Did you start at 1 or 0?
I've tried the loop with 1 and 0 and it is same

I am reinstalling VS 2005 to see if it helps
I have no other ideas
DigiSoft is offline
DigiSoft
BANNED
Join Date: Feb 2009
Old 01-06-2010 , 14:35   Re: how to get players IP?
Reply With Quote #16

I recompiled with clean CS C++ and I still get this f**** error.

I am getting very angry at this.
This code is same everywhere I checked but mine doesn't work.....
DigiSoft is offline
Keeper
Senior Member
Join Date: Nov 2006
Old 01-06-2010 , 14:47   Re: how to get players IP?
Reply With Quote #17

Can you paste the call stack? It should be one of the debugging windows open at the bottom. The state of your data before calling the IsIdxValid is what you need to look at.
Keeper is offline
DigiSoft
BANNED
Join Date: Feb 2009
Old 01-06-2010 , 15:01   Re: how to get players IP?
Reply With Quote #18

Quote:
Originally Posted by Keeper View Post
Can you paste the call stack? It should be one of the debugging windows open at the bottom. The state of your data before calling the IsIdxValid is what you need to look at.
Here you go my friend

Code:
>    tier0_s.dll!10553525()     
     [Frames below may be incorrect and/or missing, no symbols loaded for tier0_s.dll]    
     ntdll.dll!7c910202()     
     ntdll.dll!7c910202()     
     ntdll.dll!7c91017b()     
     ntdll.dll!7c9101bb()     
     kernel32.dll!7c8099fd()     
     msacm32.dll!77be17f6()     
     ntdll.dll!7c919d8a()     
     ntdll.dll!7c919d8a()     
     ntdll.dll!7c910ee4()     
     steamclient.dll!12554932()     
     steamclient.dll!12555f8f()     
     ntdll.dll!7c912d58()     
     kernel32.dll!7c80b54e()     
     ntdll.dll!7c912cae()     
     ntdll.dll!7c912ce4()     
     ntdll.dll!7c912d51()     
     ntdll.dll!7c912d58()     
     kernel32.dll!7c80ba4d()     
     ntdll.dll!7c912d58()     
     kernel32.dll!7c80b54e()     
     kernel32.dll!7c80b4fe()     
     ntdll.dll!7c90d96c()     
     kernel32.dll!7c80ba4d()     
     kernel32.dll!7c80ba76()     
     kernel32.dll!7c863aed()     
     ntdll.dll!7c91a43e()     
     ntdll.dll!7c91a684()     
     ntdll.dll!7c9118a0()     
     ntdll.dll!7c911a4d()     
     ntdll.dll!7c910098()     
     ntdll.dll!7c910098()     
     ntdll.dll!7c9101bb()     
     tier0_s.dll!1056ac84()     
     tier0_s.dll!105557f9()     
     steamclient.dll!12472520()     
     steamclient.dll!12461d4c()     
     steamclient.dll!125f5b27()     
     steamclient.dll!125f5b34()     
     steamclient.dll!1253cbc4()     
     steam_api.dll!01cb2c51()     
     engine.dll!20182355()     
     engine.dll!202a7edd()     
     engine.dll!202a7f61()     
     engine.dll!202a75bc()     
     engine.dll!202a76c8()     
     ntdll.dll!7c90118a()     
     ntdll.dll!7c923aba()     
     ntdll.dll!7c910415()     
     ntdll.dll!7c91041e()     
     ntdll.dll!7c923c68()     
     kernel32.dll!7c81ca96()     
     ntdll.dll!7c910961()     
     ntdll.dll!7c912cae()     
     ntdll.dll!7c90eb79()     
     kernel32.dll!7c81cb0e()     
     srcds.exe!00402917()     
     srcds.exe!00402a74()     
     srcds.exe!00402a9a()     
     srcds.exe!00402529()     
     kernel32.dll!7c80e46c()     
     ntdll.dll!7c91003d()     
     kernel32.dll!7c801bea()     
     srcds.exe!004023ad()     
     kernel32.dll!7c801d72()     
     kernel32.dll!7c817067()
I really don't have ideas anymore........

Last edited by DigiSoft; 01-06-2010 at 15:03.
DigiSoft is offline
Keeper
Senior Member
Join Date: Nov 2006
Old 01-06-2010 , 15:07   Re: how to get players IP?
Reply With Quote #19

Yeah, not too helpful there... My next step would be to set a breakpoint at the first line in the loop and step through it and see at what index it happens, and which line.
Keeper is offline
DigiSoft
BANNED
Join Date: Feb 2009
Old 01-06-2010 , 15:10   Re: how to get players IP?
Reply With Quote #20

Ok I must tell you that everything is working except GetAddress.

I tested pEntry by kicking myself and it works. So the player index IS OK.

The only think that doesn't work is GetAddress();
DigiSoft 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 03:38.


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