Michalplyoutube
11-03-2014, 10:29
So I tried
public OnPlayerSpawn(Handle:event, const String:name[], bool:dontBroadcast)
{
PrintToChatAll("Triggered spawn.");
new client = GetClientOfUserId( GetEventInt( event, "userid" ) );
decl String:strName[32];
GetEntPropString(client, Prop_Data, "m_iName", strName, sizeof(strName));
if (bool:StrEqual(strName, "Bumper Scout")) //(strName) == Bumper Scout)
{
PrintToChatAll("addcond trigger.");
TF2_AddCondition(client, TFCOND_HalloweenKart, TFCondDuration_Infinite);
}
}That didn't worked how can i check bot name on spawn if the name equals scout then do stuff i would need an example
public OnPlayerSpawn(Handle:event, const String:name[], bool:dontBroadcast)
{
PrintToChatAll("Triggered spawn.");
new client = GetClientOfUserId( GetEventInt( event, "userid" ) );
decl String:strName[32];
GetEntPropString(client, Prop_Data, "m_iName", strName, sizeof(strName));
if (bool:StrEqual(strName, "Bumper Scout")) //(strName) == Bumper Scout)
{
PrintToChatAll("addcond trigger.");
TF2_AddCondition(client, TFCOND_HalloweenKart, TFCondDuration_Infinite);
}
}That didn't worked how can i check bot name on spawn if the name equals scout then do stuff i would need an example