SA-MP Forums Archive
Help with if(MedicBill[playerid] == 1 && PlayerInfo[playerid][pJailed] == 0 && - 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)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Help with if(MedicBill[playerid] == 1 && PlayerInfo[playerid][pJailed] == 0 && (/showthread.php?tid=140933)



Help with if(MedicBill[playerid] == 1 && PlayerInfo[playerid][pJailed] == 0 && - Keeboo13 - 11.04.2010

I have a problem player dies when he logs in and when hes in hospital the camera is looking a diffrent way from which i got it heres my code..

Code:
		if(MedicBill[playerid] == 1 && PlayerInfo[playerid][pJailed] == 0 && PlayerPaintballing[playerid] == 0)
		{
			if(FirstSpawn[playerid] != 1)
  			{
				PlayerInfo[playerid][pDeaths] += 1;
				SetPlayerHealth(playerid, 50.0);
				SetPlayerInterior(playerid, 18);
  			PlayerInfo[playerid][pInt] = 18;
  				SetPlayerVirtualWorld(playerid, random(8999));
				PlayerInfo[playerid][pVirWorld] = 1;
				rand = random(sizeof(gMedicSpawns));
				SetPlayerPos(playerid, gMedicSpawns[rand][0], gMedicSpawns[rand][1], gMedicSpawns[rand][2]); // Warp the player
				SetPlayerFacingAngle(playerid, 0);
 				TogglePlayerControllable(playerid, 0);
    		GameTextForPlayer(playerid, "~n~~n~~n~~n~~n~~n~~n~~n~~n~~w~You need to rest now ...", 5000, 3);
    		ApplyAnimation(playerid, "CRACK", "crckdeth2", 4.0, 1, 0, 0, 0, 0);
    		SetTimerEx("ReleaseFromHospital", 8000, 0, "d", playerid);
    		PlayerPlaySound(playerid, 1062, 0.0, 0.0, 0.0);
  			return 1;
			}
		}