SA-MP Forums Archive
Players can't spawn! :( - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Players can't spawn! :( (/showthread.php?tid=619525)



Players can't spawn! :( - Thedya - 18.10.2016

Hi everyone.

I have one of old mod from 2013.. I decided to open and play with. I upgrade all files. Everything looks great.

But when i write my password, char connect to server but you can't do anything. you cant see your char. Its saying that 'you connected with Damien sinner.' At that moment i can use chat or all commends..



Why ? how can i fix it ?


Re: Players can't spawn! :( - Thedya - 18.10.2016

Код:
public SetPlayerSpawn(playerid)
{
	if(IsPlayerConnected(playerid))
	{
		if(PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pLeader] == 1 )
		{
			if(PlayerInfo[playerid][pBiggestFish] == 1)
			{
			    SetPlayerColor(playerid,POLIS_MAVI);
				OnDuty[playerid] = 1;
				SetPlayerSkin(playerid, PlayerInfo[playerid][pFishes]);
				return 1;
	 		}
	 		else
	 		{
	 		    SetPlayerSkin(playerid, PlayerInfo[playerid][pChar]);
			}
		}
 		else if(PlayerInfo[playerid][pTut] != 0)
 		{
	    	SetPlayerSkin(playerid, PlayerInfo[playerid][pChar]);
	    }
		SetPlayerInterior(playerid, PlayerInfo[playerid][pInt]);
		SetPlayerVirtualWorld(playerid, PlayerInfo[playerid][pVirWorld]);
	    if(PlayerInfo[playerid][pTut] == 0)
	    {
   			SetPlayerCameraPos(playerid, 500.0791,-1359.3954,16.2610);
			SetPlayerCameraLookAt(playerid, 1933.4393,-1196.2479,18.8163);
			gOoc[playerid] = 1; gNews[playerid] = 1; gFam[playerid] = 1;
			SetPlayerInterior(playerid, PlayerInfo[playerid][pInt]);
			SetPlayerVirtualWorld(playerid, PlayerInfo[playerid][pVirWorld]);
			SetPlayerPos(playerid, 671.5460,-519.8536,16.3359);
			SetPlayerFacingAngle(playerid, 280);
			TogglePlayerControllable(playerid, 0);
			RegistrationStep[playerid] = 1;
			ClearChatbox(playerid, 10);
			SendClientMessage(playerid, COLOR_WHITE, "Bu bцlьmde karakter detaylarını belirlemeniz gerekmektedir.Karakterinizin yaşını,uyruğunu ve başlangıз tiplemelerini seзerken dikkatli olunuz..");
			SendClientMessage(playerid, COLOR_WHITE, "Karakterinizin yaşı doğum tarihinize gцre belirlenecek ve statьsьne eklenecektir.");
			ShowPlayerDialog(playerid, 2, DIALOG_STYLE_INPUT, "Karakter yaşı: ", "GG/AA/YYYY şeklinde yazın.", "Devam","");
   return 1;
	    }
	    if(AdminSpec[playerid] == 1)
		{
		    return 1;
		}

	
		if(PlayerInfo[playerid][pJailed] == 1)
		{
		    SetPlayerInterior(playerid, 6);
		    PlayerInfo[playerid][pInt] = 6;
			SetPlayerPos(playerid,264.6288,77.5742,1001.0391);
			SendClientMessage(playerid, COLOR_RED, "Hapis sьreniz sona ermemiş.Tekrar hapishaneye dцnьyorsunuz.");
			return 1;
		}
		if(PlayerInfo[playerid][pJailed] == 2)
		{
		    SetPlayerInterior(playerid, 0);
		    PlayerInfo[playerid][pInt] = 0;
			SetPlayerPos(playerid,268.5777,1857.9351,9.8133);
			SetPlayerWorldBounds(playerid, 337.5694,101.5826,1940.9759,1798.7453); //285.3481,96.9720,1940.9755,1799.0811
			return 1;
		}

		    if(TutTime[playerid] == 0 && PlayerInfo[playerid][pTut] == 1 && RegistrationStep[playerid] == 0 && FirstSpawn[playerid] == 1)
		    {
		        SetPlayerVirtualWorld(playerid,PlayerInfo[playerid][pVirWorld]);
		        SetPlayerInterior(playerid,PlayerInfo[playerid][pInt]);
		    	SetPlayerPos(playerid, PlayerInfo[playerid][pPos_x], PlayerInfo[playerid][pPos_y], PlayerInfo[playerid][pPos_z] + 0);
		    	return 1;
			}
		//}
	}
	return 1;
}