Dear visitor, welcome to sourceserver.info.
If this is your first visit here, please read the Help. It explains in detail how this page works.
To use all features of this page, you should consider registering.
Please use the registration form, to register here or read more information about the registration process.
If you are already registered, please login here.
Code fehler?
Hallo liebe Community,
Ich habe ein kleines Problem.
public OnRoundStart(Handle:event, const String:name[], bool:dontBroadcast)
{
for(new i; i <= MaxClients; i++)
{
if(IsClientValid(i) && GetClientTeam(i) == CS_TEAM_T)
{
ShowPanel(i);
}
}
}
Error den ich bekomme:
test.sp<26> : error 017: undefined symbol "IsClientValid"
Bitte um schnelle Hilfe.
Mfg
Greetz
Rechtschreibfehler sind voll normal
Greetz
Rechtschreibfehler sind voll normal
Die Funktion "IsClientValid" existiert in SM sowie in deinem Code nicht.
Die grundlegende Funktion ist, dass client > 0 & client ingame.
gruß
Kann mir des bitte jemand richtig fixen?
public OnPluginStart()
{
HookEvent("round_start", OnRoundStart);
}
public OnRoundStart(Handle:event, const String:name[], bool:dontBroadcast)
{
for(new i; i <= MaxClients; i++)
{
if(IsClientValid(i) && GetClientTeam(i) == CS_TEAM_T)
{
ShowPanel(i);
}
}
}
Greetz
Rechtschreibfehler sind voll normal
|
Source code
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
#include <sourcemod>
#include <cstrike>
public OnPluginStart()
{
HookEvent("round_start", OnRoundStart);
}
public OnRoundStart(Handle:event, const String:name[], bool:dontBroadcast)
{
for(new i; i <= MaxClients; i++)
{
if(IsClientValid(i) && GetClientTeam(i) == CS_TEAM_T)
{
// ShowPanel(i);
}
}
}
stock bool:IsClientValid(client)
{
if (client > 0 && client <= MaxClients)
{
if (IsClientInGame(client))
{
return true;
}
return false;
}
return false;
}
|