Server closed connection After Spawn Protection
#1

Hey Guys,

I have a Spawnprotection filterscript but if I use it, the server close the connection after spawnprotection is over.\

PHP код:
           //>          [FS] Spawn Protection - By HotStyle           <//
#include <a_samp>
#define PROTECTION 30 // Edit here the 'seconds' if you want
forward AntiSpawnkill(playerid);
public 
OnFilterScriptInit()
{
    print(
"\n__________________________________________");
    print(
"         Spawn Protection - loaded          ");
    print(
"          By: HotStyle                      ");
    print(
"__________________________________________\n");
    return 
1;
}
public 
OnPlayerSpawn(playerid)
{
    
SetPlayerHealth(playerid10000.0);
    new 
str[128];
    
format(strsizeof(str), "You can't be killed for %d second(s) - Spawn Protection"PROTECTION);
    
SendClientMessage(playerid0xFF0000AAstr);
    
SetPlayerChatBubble(playerid"Anti-Spawnkill protected player"0xFF0000AA100.05000);
    
SetTimerEx("AntiSpawnkill",PROTECTION*1000,0,"d",playerid);
    return 
1;
}
public 
AntiSpawnkill(playerid)
{
    
SetPlayerHealth(playerid100.0);
    
SendClientMessage(playerid0xFF0000AA"Spawn Protection Over - Move if you're unprotected");
    return 
1;

Reply
#2

You probably have an anti(health) hack script running falsely detecting the player as hacking the 100. What FS'es / GM are you running?
Reply
#3

I am running my own, and yes I have anti health hack.
Reply
#4

Could you please post your anti health script here because that may be causing the issues and kicking you
Reply
#5

It's fixed
Reply
#6

Okay nice to hear
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)