Jo, ich konnte nichts finden.
public OnPlayerSpawn(playerid)
{
Attach3DTextLabelToPlayer(AFKLabel[playerid], playerid, 0.0, 0.0, 0.7);
if(tot[playerid] == 1)
{
if(sInfo[playerid][wanted]>0)
{
ocmd_krankenhausjail(playerid,"");
}
if(sInfo[playerid][wanted]==0)
{
switch (GetPVarInt(playerid, "i"))
{
case 0:
{
SetPlayerPos(playerid, 2034.1149,-1414.9154,16.9922);
SetPlayerFacingAngle(playerid, 133.3335);
}
case 1:
{
SetPlayerPos(playerid, 1182.1077,-1324.0918,13.5815);
SetPlayerFacingAngle(playerid, 270.4434);
}
case 2:
{
SetPlayerPos(playerid, 1244.3423,331.9934,19.5547);
SetPlayerFacingAngle(playerid, 335.6859);
}
case 3:
{
SetPlayerPos(playerid, 1607.6090,1821.0934,10.8280);
SetPlayerFacingAngle(playerid, 0.7354);
}
case 4:
{
SetPlayerPos(playerid, -317.0090,1056.6217,19.7422);
SetPlayerFacingAngle(playerid, 358.9579);
}
case 5:
{
SetPlayerPos(playerid, -1514.7358,2527.0601,55.7455);
SetPlayerFacingAngle(playerid, 359.0611);
}
case 6:
{
SetPlayerPos(playerid, -2661.2441,633.7098,14.4531);
SetPlayerFacingAngle(playerid, 180.1544);
}
case 7:
{
SetPlayerPos(playerid, -2198.7803,-2306.5793,30.6250);
SetPlayerFacingAngle(playerid, 320.6338);
}
}
SetPlayerInterior(playerid,0);
SetPlayerVirtualWorld(playerid,0);
SetPlayerSkin(playerid,sInfo[playerid][skin]);
tot[playerid] = 0;
return 1;
}
return 1;
}
Hunger[playerid] = 100, hbHealth[playerid] = 100;
HungerBar[playerid] = CreatePlayerProgressBar(playerid, 547.5, 58.0, 59.0, 5, COLOR_GREEN, 100.0);
ShowPlayerProgressBar(playerid, HungerBar[playerid]);
SetPlayerProgressBarValue(playerid, HungerBar[playerid], 100);
UpdatePlayerProgressBar(playerid, HungerBar[playerid]);
progressUpdater[playerid] = SetTimer("HungerProgressBar", 90000, true);
if(sInfo[playerid][jailed])
{
sInfo[playerid][jail]=0;
new jailid = GetFreeJail();
SetPlayerPos(playerid,jailInfo[jailid][jail_x],jailInfo[jailid][jail_y],jailInfo[jailid][jail_z]);
SetPlayerFacingAngle(playerid,jailInfo[jailid][jail_angle]);
TogglePlayerControllable(playerid,0);
SetTimerEx("Freezzer",350,0,"i",playerid);
SetTimerEx("UpdatePlayerJail",60000,false,"i",playerid);
sInfo[playerid][jail]=jailid;
return 1;
}
PlayerTextDrawShow(playerid, UhrzeitText[playerid]);
PlayerTextDrawShow(playerid, hpanzeige[playerid]);
EnableBoast[playerid] = 0;
//NPC/Skin
if(IsPlayerNPC(playerid))
{
new botname[MAX_PLAYER_NAME];
GetPlayerName(playerid,botname,sizeof(botname));
if(!strcmp(botname,"[NPC]Herbert",true))
{
SetPlayerSkin(playerid,26);
}
if(!strcmp(botname,"[NPC]Manfred",true))
{
SetPlayerSkin(playerid,26);
}
if(!strcmp(botname,"[NPC]xxSevenxx",true))
{
SetPlayerSkin(playerid,26);
}
}
if(IsPlayerNPC(playerid))return 1;
SetPlayerSkin(playerid,sInfo[playerid][skin]);
SetPlayerColor(playerid, 0xFFFFFF00);
printf("[OnPlayerSpawn]-[Vor Schleife] sInfo[playerid][spawnpunkt] == %d",sInfo[playerid][spawnpunkt]);
sInfo[playerid][spawnpunkt] = 1;
//sInfo[playerid][spawnpunkt] = 20;
if(sInfo[playerid][spawnpunkt] > 0)
{
for(new i=0; i<sizeof(hInfo); i++)
{
printf("hInfo[i][h_id] == %d",hInfo[i][h_id]);
printf("sInfo[playerid][spawnpunkt] == %d",sInfo[playerid][spawnpunkt]);
if(hInfo[i][h_id]==sInfo[playerid][spawnpunkt])
{
if(!hInfo[i][h_id])continue;
if(!strlen(hInfo[i][h_besitzer]))continue;
if(strcmp(hInfo[i][h_besitzer], getPlayerName(playerid), true))continue;
if(hInfo[i][ih_x] != 0.0)
{
//Im Haus spawnen
SetPlayerPos(playerid, hInfo[i][ih_x], hInfo[i][ih_y], hInfo[i][ih_z]);
SetPlayerInterior(playerid, hInfo[i][h_interior]);
SetPlayerVirtualWorld(playerid, hInfo[i][h_id]);
}
else
{
//Vorm Haus Spawnen
SetPlayerPos(playerid, hInfo[i][h_x], hInfo[i][h_y], hInfo[i][h_z]);
SetPlayerInterior(playerid, 0);
SetPlayerVirtualWorld(playerid, 0);
}
}
}
}
/*if(!isPlayerInFrakt(playerid, 0)){
if(sInfo[playerid][spawnchange]==1)
{
new fID;
fID = sInfo[playerid][fraktion];
SetPlayerPos(playerid, fInfo[fID][f_x],fInfo[fID][f_y],fInfo[fID][f_z]);
SetPlayerFacingAngle(playerid, fInfo[fID][f_r]);
SetPlayerInterior(playerid, fInfo[fID][f_inter]);
SetPlayerVirtualWorld(playerid, fInfo[fID][f_world]);
SetPlayerColor(playerid, fInfo[fID][f_color]);
}
}*/
return 1;
}