06.09.2014, 01:10
hey out if no were i got ""Stay within the world bounderies "" problem i dont know whats wrong but since i got my new gaming computer my server keep doing that even on other pc, lmk what ya need to help me plz
|
Could it be that you've set the player spawn to some x/y/z which is bigger then 20000 or smaller then -20000?
|
|
Are you using a downloaded gamemode or did you make your own?
If it was a downloaded gamemode, click CTRL+F and search for SetPlayerWorldBounds Then delete it. |
SetPlayerWorldBounds
public OnPlayerSpawn(playerid)
{
if(IsPlayerNPC(playerid))
{
new npcname[MAX_PLAYER_NAME];
GetPlayerName(playerid, npcname, sizeof(npcname));
if(!strcmp(npcname, "PoliceOfficer", true))
{
if(IsPlayerInRangeOfPoint(playerid, 2.0, 1552.2175,-1673.1248,16.1783))
{
SetPlayerMarkerForPlayer(playerid,playerid,00);
SetPlayerColor(playerid, COLOR_RED);
ResetPlayerWeapons(playerid);
SetPlayerPos(playerid, 1552.2175,-1673.1248,16.1783);
TogglePlayerControllable(playerid,0);
print("NCP PoliceOfficer Spawned!");
//
}
}
if(!strcmp(npcname, "Medic", true))
{
SetPlayerMarkerForPlayer(playerid,playerid,00);
SetPlayerColor(playerid, 0xFFFFFF00);
ResetPlayerWeapons(playerid);
TogglePlayerControllable(playerid,0);
print("NCP Medic Spawned!");
}
if(!strcmp(npcname, "Officer", true))
{
SetPlayerMarkerForPlayer(playerid,playerid,00);
SetPlayerColor(playerid, 0xFFFFFF00);
ResetPlayerWeapons(playerid);
TogglePlayerControllable(playerid,0);
print("NCP Officer Spawned!");
}
return 1;
}
// removed objects
RemoveBuildingForPlayer(playerid, 2252, 301.0703, 180.3672, 1007.4531, 0.25);
RemoveBuildingForPlayer(playerid, 14854, 296.6875, 184.5000, 1008.5938, 0.25);
RemoveBuildingForPlayer(playerid, 2252, 291.6563, 187.9844, 1007.4531, 0.25);
RemoveBuildingForPlayer(playerid, 2252, 231.5781, 158.7891, 1003.3594, 0.25);
RemoveBuildingForPlayer(playerid, 14855, 231.4688, 163.8516, 1006.5234, 0.25);
RemoveBuildingForPlayer(playerid, 2252, 233.9453, 168.5000, 1003.3594, 0.25);
//DrugAmountLoad(playerid);
SetTimerEx("WantedSpawnLoading", 2000, false, "i", playerid);
SetTimerEx("WantedDown", 85000, true, "i", playerid);
SetTimerEx("Donators", 2000, true, "i", playerid);
SetTimerEx("CheckMoney", 2000, true, "i", playerid);
SetTimerEx("CheckRobSkill",2000, true, "i", playerid);
// ed of saving inportan files
SetPlayerPos(playerid, 1481.2715,-1770.6609,18.7958);
SetPlayerInterior(playerid,0);
StopAudioStreamForPlayer(playerid);
TogglePlayerClock(playerid,1);
new name[MAX_PLAYER_NAME], file[256];
GetPlayerName(playerid, name, sizeof(name));
format(file, sizeof(file), scriptfiles, name);
SetPlayerSkin(playerid, dini_Int(file, "Skin"));
TextDrawShowForPlayer(playerid, Dollar[playerid]);
TextDrawShowForPlayer(playerid, Bank[playerid]);
TextDrawShowForPlayer(playerid, MBank[playerid]);
TextDrawShowForPlayer(playerid, RobSkillTD[playerid]);
TogglePlayerDynamicCP(playerid,Checkpoint[1],false);
CancelSelectTextDraw(playerid);
PlayerTextDrawHide(playerid, CF[playerid]);
//police officer td job
TextDrawHideForPlayer(playerid, PoliceO[playerid]);
TextDrawHideForPlayer(playerid, MainBoxC[playerid]);
TextDrawHideForPlayer(playerid, AsACop[playerid]);
TextDrawHideForPlayer(playerid, CanDoC[playerid]);
TextDrawHideForPlayer(playerid, PCStar[playerid]);
TextDrawHideForPlayer(playerid, CCMD[playerid]);
TextDrawHideForPlayer(playerid, CRules[playerid]);
TextDrawHideForPlayer(playerid, CAccept[playerid]);
TextDrawHideForPlayer(playerid, CDisagree[playerid]);
//hide death info
TextDrawHideForPlayer(playerid, DeathMainBox);
TextDrawHideForPlayer(playerid, DeathMainBox2);
TextDrawHideForPlayer(playerid, DeathA[playerid]);
TextDrawHideForPlayer(playerid, DeathInfo);
TextDrawHideForPlayer(playerid, KillsA[playerid]);
TextDrawHideForPlayer(playerid, MedsA[playerid]);
TextDrawHideForPlayer(playerid, Killedby[playerid]);
TextDrawHideForPlayer(playerid, IfDM);
new string[200];
format(string, 200, "[SPAWN] %s", PlayerInfo(playerid));
print(string);
AccountInfo[playerid][pSpawned] = 1;
AccountInfo[playerid][pTazed] = 0 ;
if(AccountInfo[playerid][pBanned] == 1)
{
format(string, sizeof(string), "[AUTO BAN] %s banned player name: ban evade", PlayerInfo(playerid));
SendClientMessageToAll(COLOR_PURPLE, string);
print(string);
format(string, sizeof(string), "Player %s has been banned for ban evasion (Banned player name)", PlayerInfo(playerid));
print(string);
Ban(playerid);
return 1;
}
if(gTeam[playerid] == Team_Cop) //team_cop
{
/*GivePlayerWeapon(playerid, 3, 1);
GivePlayerWeapon(playerid, 22, 100);
GivePlayerWeapon(playerid, 29, 500);
GivePlayerWeapon(playerid, 33, 10);*/
new rnd = random(sizeof(CopSpawnPoints));
SetPlayerPos(playerid, CopSpawnPoints[rnd][0], CopSpawnPoints[rnd][1], CopSpawnPoints[rnd][2]);
SetPlayerFacingAngle(playerid, CopSpawnPoints[rnd][3]);
SetPlayerArmour(playerid, 100.0);
SetCameraBehindPlayer(playerid);
RadioInfo[playerid][pCopRadio] = 1;
}
if(gTeam[playerid] == Team_FBI)
{
SendClientMessage(playerid, COLOR_DODGERBLUE, "**FBI Agent**");
SendClientMessage(playerid, COLOR_LIGHTBLUE, "[INFO]: "COL_VIOLET" Type "COL_LRED2"/commands "COL_VIOLET "for your available commands.");
SendClientMessage(playerid, COLOR_LIGHTBLUE, "[INFO]: "COL_VIOLET"Your job is to arrest and catch criminals in Los Santos and nearby areas.");
SendClientMessage(playerid, COLOR_LIGHTBLUE, "[INFO]: "COL_VIOLET "Read "COL_LRED2"/pc "COL_VIOLET" to find out which people you can and cannot shoot.");
/*GivePlayerWeapon(playerid, 3, 1);
GivePlayerWeapon(playerid, 22, 100);
GivePlayerWeapon(playerid, 29, 500);
GivePlayerWeapon(playerid, 31, 100);*/
SetPlayerArmour(playerid, 100.0);
SetPlayerToTeamColor(playerid);
SetCameraBehindPlayer(playerid);
RadioInfo[playerid][pCopRadio] = 1;
}
if(gTeam[playerid] == Team_Army)
{
SendClientMessage(playerid, COLOR_FORESTGREEN, "**Los Santos Army**");
SendClientMessage(playerid, COLOR_LIGHTBLUE, "[INFO]: "COL_LGREEN"Type "COL_LRED2"/commands "COL_LGREEN"for your commands");
SendClientMessage(playerid, COLOR_LIGHTBLUE, "[INFO]: "COL_LGREEN"Your job is to take down "COL_RED"MOST WANTED "COL_LGREEN"criminals by any means necessary.");
SendClientMessage(playerid, COLOR_LIGHTBLUE, "[INFO]: "COL_RED"YOU CANNOT SHOOT AT OTHER ARMY, POLICE, OR NON MOST WANTED PLAYERS.");
SendClientMessage(playerid, COLOR_LIGHTBLUE, "[INFO]: "COL_LGREEN"Read "COL_LRED2"/pc "COL_LGREEN"to find out the player colors.");
/*GivePlayerWeapon(playerid, 24, 50);
GivePlayerWeapon(playerid, 31, 500);
GivePlayerWeapon(playerid, 34, 20);
GivePlayerWeapon(playerid, 26, 25);*/
SetPlayerArmour(playerid, 100.0);
SetCameraBehindPlayer(playerid);
SetPlayerToTeamColor(playerid);
RadioInfo[playerid][pCopRadio] = 1;
}
if(gTeam[playerid] == Team_Civi)// team_civi
{
new rnd = random(sizeof(SpawnPoints));
SetPlayerPos(playerid, SpawnPoints[rnd][0], SpawnPoints[rnd][1], SpawnPoints[rnd][2]);
SetPlayerFacingAngle(playerid, SpawnPoints[rnd][3]);
SetCameraBehindPlayer(playerid);
GivePlayerWeapon(playerid, 22, 400);
SetPlayerToTeamColor(playerid);
}
if(gTeam[playerid] == Team_Guard) //team_guard
{
SendClientMessage(playerid, COLOR_FORESTGREEN, "**Los Santos Guard**");
SendClientMessage(playerid, COLOR_LIGHTBLUE, "[INFO]: "COL_GUARDG "Type "COL_LRED2"/commands "COL_GUARDG "for your commands");
SendClientMessage(playerid, COLOR_LIGHTBLUE, "[INFO]: "COL_GUARDG "Your job is to manage the jail cells, prisons, and etc.");
SendClientMessage(playerid, COLOR_LIGHTBLUE, "[INFO]: "COL_RED"YOU CANNOT SHOOT AT OTHER GUARDS, POLICE, OR NON MOST WANTED PLAYERS.");
SendClientMessage(playerid, COLOR_LIGHTBLUE, "[INFO]: "COL_GUARDG "Read "COL_LRED2"/pc "COL_GUARDG"to find out the player colors.");
GivePlayerWeapon(playerid, 3, 1);
GivePlayerWeapon(playerid, 24, 500);
GivePlayerWeapon(playerid, 25, 10);//
SetPlayerArmour(playerid, 100.0);
SetPlayerPos(playerid, 1803.9167,-1537.9795,5700.4287);
SetPlayerFacingAngle(playerid, 272.5791);
SetCameraBehindPlayer(playerid);
SetPlayerToTeamColor(playerid);
RadioInfo[playerid][pCopRadio] = 1;
}
if(gTeam[playerid] == Team_Medic) //team_guard
{
SendClientMessage(playerid, COLOR_FORESTGREEN, "**Medic**");
SetPlayerToTeamColor(playerid);
}
if(AccountInfo[playerid][pJailed] == 1)
{
new rnd = random(sizeof(PrisonSpawn)); SetPlayerPos(playerid, PrisonSpawn[rnd][0], PrisonSpawn[rnd][1], PrisonSpawn[rnd][2]);
SetPlayerInterior(playerid, 3);
format(string, sizeof(string), "[AUTO JAIL] %s (LEFT SERVER WHILE IN JAIL)",PlayerInfo(playerid));
print(string);
SetPlayerToTeamColor(playerid);
SetPlayerWantedLevel(playerid, 0);
WantedLevelColor(playerid);
AccountInfo[playerid][pJailed] = 1 ;
}
return 1;
}
|
If you are still scripting on it, then that means you changed something recently. Undo bits until this stops, then you will know the cause.
|
|
Make sure you have at least 1 AddPlayerClass line under OnGameModeInit.
Source: https://sampwiki.blast.hk/wiki/AddPlayerClass |