Also ich kann sterben und krieg auch die Meldung die ich mache wenn er stirbt aber ich werd nicht Zurück geportet O.o
Hier mal alles was damit zu tun hat.
Deagle:
ocmd:deagle(playerid,params[])
{
ShowPlayerDialog(playerid,DIALOG_DEAGLE,DIALOG_STYLE_MSGBOX,"Deagle Event","Möchtest du wirklich zum Deagle Event?","Ja","Nein");
return 1;
}
Dialog:
if(dialogid==DIALOG_DEAGLE)
{
if(response==0)
{
SendClientMessage(playerid,ROT,"Du wolltest also nicht zum Event.");
}
if(response==1)
{
SetPlayerPos(playerid,-2433.1653,1548.9905,34.4020);
SetPlayerFacingAngle(playerid,269.1000);
ResetPlayerWeapons(playerid);
GivePlayerWeapon(playerid,24,900);
SetPlayerHealth(playerid, 200);
SendClientMessage(playerid,WEIß,"Du hast dich erfolgreich zum Deagle Event teleportiert.");
SendClientMessage(playerid,WEIß,"Um Herauszukommen musst zu /exitd machen.");
SpEvent[playerid][Deagle] = 1;
}
}
exit befehl:
ocmd:exitd(playerid,params[])
{
if(SpEvent[playerid][Deagle] == 0)
{
SendClientMessage(playerid,ROT,"Info: Du bist nicht im Deagle Event.");
return 1;
}
else if(SpEvent[playerid][Deagle] == 1)
{
SetPlayerPos(playerid, 1958.3783, 1343.1572, 15.3746);
SetPlayerCameraPos(playerid, 1958.3783, 1343.1572, 15.3746);
SetPlayerCameraLookAt(playerid, 1958.3783, 1343.1572, 15.3746);
GivePlayerWeapon(playerid,24,20);
SetPlayerHealth(playerid,100);
SpEvent[playerid][Deagle] = 0;
return 1;
}
return 1;
}
OnPlayerDeath
if(SpEvent[playerid][Deagle] == 1)
{
SetPlayerPos(playerid,-2433.1653,1548.9905,34.4020);
SetPlayerFacingAngle(playerid,269.1000);
GivePlayerWeapon(playerid,24,900);
SetPlayerHealth(playerid,200);
SendClientMessage(playerid,WEIß,"Du bist gestorben. Und wieder im Deagle Event. ");
GameTextForPlayer(playerid,"Um Herauszukommen musst zu /exitd machen.",5,1);
return 1;
}
return 1;
}