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

OnClientPostAdminCheck timer - error logs


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
krysteksulek
Member
Join Date: Aug 2013
Location: Poland
Old 11-20-2017 , 05:20   OnClientPostAdminCheck timer - error logs
Reply With Quote #1

Hello,
I have the following code:
Code:
public OnClientPostAdminCheck(client)
{
	CreateTimer(4.0, OnClientPostAdminCheck_Delay, GetClientUserId(client));
}
public Action OnClientPostAdminCheck_Delay(Handle timer, any client)
{	
	if(!IsClientInGame(client) || IsFakeClient(client) || IsClientReplay(client) || IsClientSourceTV(client))
	{
		return Plugin_Handled;
	}
//something here
        return Plugin_Handled
}
And im getting these errors:

Code:
L 11/20/2017 - 02:07:11: [SM] Call stack trace:
L 11/20/2017 - 02:07:11: [SM]   [0] IsClientInGame
L 11/20/2017 - 02:07:11: [SM]   [1] Line 28, C:\PawnStudio\playerscheck.sp::OnClientPostAdminCheck_Delay
Can anyone tell we what's wrong here?
krysteksulek is offline
Awigotsky
Junior Member
Join Date: Sep 2017
Location: N\A
Old 11-20-2017 , 05:25   Re: OnClientPostAdminCheck timer - error logs
Reply With Quote #2

Code:
public OnClientPostAdminCheck(client)
{
	CreateTimer(4.0, OnClientPostAdminCheck_Delay, GetClientUserId(client));
}
public Action OnClientPostAdminCheck_Delay(Handle timer, int data)
{	
        int client = GetClientOfUserId(data);
	if(!IsClientInGame(client) || IsFakeClient(client) || IsClientReplay(client) || IsClientSourceTV(client))
	{
		return Plugin_Handled;
	}
//something here
        return Plugin_Handled
}
Awigotsky 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 19:39.


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