[Ajuda] Bug ao morrer
#1

Fala galera. Estou editando uma GM, a Brasil Games, [BG].

Quando alguйm morre, a tela do player aparece a de login, e aparece tambйm os botoes (<) (>) (Spawn)

Alguйm sabe resolver isso??
Obrigado.

PHP код:
public OnPlayerDeath(playeridkilleridreason)
{
new 
kname[MAX_PLAYER_NAME];
GetPlayerName(killeridknameMAX_PLAYER_NAME);
format(file2sizeof(file2), PASTA_CONTASkname);
new 
aname[MAX_PLAYER_NAME];
GetPlayerName(playeridanameMAX_PLAYER_NAME);
format(filesizeof(file), PASTA_CONTASaname);
GameTextForPlayer(playerid,"~r~voce morreu.."25005);
dini_IntSet(file"usoudroga"1);
algemado[playerid] = 0;
GPS_Spawned[playerid] = 0;
autoescola[playerid] = 0;
sequestro[playerid] = 0;
prefls[playerid] = 0;
prefsf[playerid] = 0;
preflv[playerid] = 0;
nobarls[playerid] = 0;
nobarsf[playerid] = 0;
nobarlv[playerid] = 0;
nobarfc[playerid] = 0;
nautlls[playerid] = 0;
dini_IntSet(file"convitent"0);
dini_IntSet(file"Entrevista"0);
dini_IntSet(file2"DM"1);
dini_IntSet(file"usoudroga"0);
if(
GetClosestHospital(playerid) == 0){
SetSpawnInfo(playerid,1,dini_Int(file"Skin"),-2651.6501634.451014.4531180.0000000000);
}
else if(
GetClosestHospital(playerid) == 1){
SetSpawnInfo(playerid,1,dini_Int(file"Skin"),1173.5842,-1324.5615,15.1953,278.4624,0,0,0,0,0,0);
}
else if(
GetClosestHospital(playerid) == 2){
SetSpawnInfo(playerid,1,dini_Int(file"Skin"),2031.9415,-1404.3578,17.2614,165.8180,0,0,0,0,0,0);
}
else if(
GetClosestHospital(playerid) == 3){
SetSpawnInfo(playerid,1,dini_Int(file"Skin"),1582.5615,1768.7921,10.8203,93.7454,0,0,0,0,0,0);
}
if(
DMlb == 1){
new 
string[256];
format(stringsizeof(string), "(INFO) O jogador %s nгo foi preso porque o DM estava liberado!",kname);
SendClientMessageToAll(msgdm3string);
return 
1;
}
if(
dini_Int(file"Preso") == 1){
SetPlayerPos(playerid263.8820,77.4002,1001.0391);
SetPlayerInterior(playerid6);
SetPlayerHealth(playerid,99999);
ResetPlayerWeapons(playerid);
TogglePlayerControllable(playerid1);
SendClientMessage(playeridmsgdm"(INFO) Vocк estб preso, para ser solto consulte um advogado ou pague fianзa pelo saldo bancario. /fianca");
preso[playerid] = 1;
dini_IntSet(file2"ofmaconha"0);
dini_IntSet(file2"ofcocaina"0);
dini_IntSet(file2"ofcrack"0);
dini_IntSet(file"usoudroga"0);
dini_IntSet(file"tmaconha"0);
dini_IntSet(file"tcrack"0);
dini_IntSet(file"tcocaina"0);
dini_IntSet(file"Maconha"0);
dini_IntSet(file"Crack"0);
dini_IntSet(file"Cocaina"0);
}
if(
DMLiberado2[playerid] == 1){
new 
string[256];
format(stringsizeof(string), "* %s matou %s na favela e nгo foi colocado na lista de procurados!",knameaname);
SendClientMessageToAll(0xA80000AAstring);
SetSpawnInfo(playerid0,dini_Int(file"Skin"), 2122.4463, -1212.484023.964493.7454000000);
ClearAnimations(playerid);
SetPlayerSpecialAction(playerid,SPECIAL_ACTION_NONE);
TogglePlayerControllable(playerid1);
return 
1;
}
if(
noevento[playerid] == 1){
new 
string[256];
format(stringsizeof(string), "* %s matou alguem no Evento e nгo foi colocado na lista de procurados!",kname);
SendClientMessageToAll(msgdm3string);
return 
1;
}
if(
dini_Int(file2"DM") == 1){
new 
string[256];
format(stringsizeof(string), "* %s matou  %s e estб sendo procurado pela Policia!",knameaname);
SendClientMessageToAll(0x007CF9AAstring);
dini_IntSet(file2"Procurado"1);
Procurados[killerid] = 1;
//SetPlayerWantedLevel(killerid, 1);
}
return 
1;

(sim, ja botei SpawnPlayer(id); mais nada adiantou.)

PHP код:
public OnPlayerSpawn(playerid)
{
if(
dini_Int(file"Lutas") == 1)
{
SetPlayerFightingStyle (playeridFIGHT_STYLE_ELBOW);
}
if(
dini_Int(file"Lutas") == 2)
{
SetPlayerFightingStyle (playeridFIGHT_STYLE_BOXING);
}
if(
dini_Int(file"Lutas") == 3)
{
SetPlayerFightingStyle(playeridFIGHT_STYLE_GRABKICK);
}
if(
dini_Int(file"Lutas") == 4)
{
SetPlayerFightingStyle (playeridFIGHT_STYLE_KNEEHEAD);
}
if(
dini_Int(file"Lutas") == 5)
{
SetPlayerFightingStyle (playeridFIGHT_STYLE_KUNGFU);
}
if(
dini_Int(file"Lutas") == 6)
{
SetPlayerFightingStyle (playeridFIGHT_STYLE_NORMAL);
}
emcasa[playerid] = 0;
new 
aname[MAX_PLAYER_NAME];
GetPlayerName(playeridanameMAX_PLAYER_NAME);
format(filesizeof(file), PASTA_CONTASaname);
TextDrawHideForPlayer(playeridtopblack);
TextDrawHideForPlayer(playeridbackblack);
TextDrawHideForPlayer(playeriddrogas1);
TextDrawHideForPlayer(playeriddrogas2);
TextDrawShowForPlayer(playeridRelogio);
TextDrawShowForPlayer(playeridoakley);
SetPlayerInterior(playerid,0);
PlayerPlaySound(playerid11840.00.00.0);
GangZoneShowForPlayer(playerid,favela,0xFF0000AA);
GangZoneShowForPlayer(playeridareadmlv0xFF000096);
GangZoneShowForPlayer(playeridAreaDrogas0xFF8040AA);
//variavel
gmod[playerid] = 0;
noevento[playerid] = 0;
GPS_Spawned[playerid] = 1;
nogame[playerid] = 0;
Logarprof(playerid);
autoescola[playerid] = 0;
prefls[playerid] = 0;
prefsf[playerid] = 0;
preflv[playerid] = 0;
nobarls[playerid] = 0;
nobarsf[playerid] = 0;
nobarlv[playerid] = 0;
nobarfc[playerid] = 0;
nautlls[playerid] = 0;
algemado[playerid] = 0;
sequestro[playerid] = 0;
vercmds[playerid]=0;
verpms[playerid]=0;
dini_IntSet(file"convitent"0);
dini_IntSet(file"Entrevista"0);
dini_IntSet(file"MN"0);
dini_IntSet(file"LC"0);
//fim
if(NaFaculdade[playerid] == 1)
{
new 
Float:X,Float:Y,Float:Z;
GetPlayerPos(playerid,X,Y,Z);
PlayerPlaySound(playerid,1076,X,Y,Z);
SetPlayerHealth(playerid,999999);
SetPlayerPos(playerid,1494.4003,1304.2990,1093.2891);
SetPlayerInterior(playerid3);
TogglePlayerControllable(playerid1);
}
if(
pAdmin[playerid] == 0)
{
admin[playerid] = 0;
dini_IntSet(file"aAdmin"0);
}
if(
dini_Int(file"Procurado") == 1)
{
Procurados[playerid]= 1;
}
if(
dini_Int(file"Procurado") == 0)
{
Procurados[playerid]= 0;
}
if(
pAdmin[playerid] == 1)
{
admin[playerid] = 1;
}
if(
pAdmin[playerid] == || pAdmin[playerid] == || pAdmin[playerid] == || pAdmin[playerid] == 5)
{
admin[playerid] = 1;
dini_IntSet(file"aAdmin"1);
}
if(
dini_Int(file"VIP") == 1)
{
vip[playerid] = 1;
SetPlayerMapIcon(playerid11568.0254,-1896.3612,13.5605230); //Bar Vip LS
SendClientMessage(playeridverdel"[~] Parabйns! Vocк й um jogador VIP!");
}
if(
dini_Int(file"VIP") == 0)
{
vip[playerid] = 0;
}
if(
dini_Int(file"Lutas") == 1)
{
SetPlayerFightingStyle (playeridFIGHT_STYLE_ELBOW);
}
if(
dini_Int(file"Lutas") == 2)
{
SetPlayerFightingStyle (playeridFIGHT_STYLE_BOXING);
}
if(
dini_Int(file"Lutas") == 3)
{
SetPlayerFightingStyle(playeridFIGHT_STYLE_GRABKICK);
}
if(
dini_Int(file"Lutas") == 4)
{
SetPlayerFightingStyle (playeridFIGHT_STYLE_KNEEHEAD);
}
if(
dini_Int(file"Lutas") == 5)
{
SetPlayerFightingStyle (playeridFIGHT_STYLE_KUNGFU);
}
if(
dini_Int(file"Lutas") == 6)
{
SetPlayerFightingStyle (playeridFIGHT_STYLE_NORMAL);
}
if(
dini_Int(file,"novato") == 1)
{
SendClientMessage(playerid, -1"");
SendClientMessage(playerid, -1"");
SendClientMessage(playerid, -1"");
SendClientMessage(playerid, -1"");
SendClientMessage(playerid, -1"");
SendClientMessage(playerid, -1"");
SendClientMessage(playerid, -1"");
SendClientMessage(playerid, -1"");
SendClientMessage(playerid, -1"");
SendClientMessage(playerid, -1"");
SendClientMessage(playerid, -1"");
SendClientMessage(playerid, -1"");
SendClientMessage(playerid, -1"");
SendClientMessage(playerid, -1"");
new 
string22[256];
format(string22sizeof(string22), "[~] Parabйns, %s [%d]! Vocк foi registrado com sucesso."aname,playerid);
SendClientMessage(playerid0xC92DE5AAstring22);
dini_IntSet(file"novato"2);
SetPlayerSkin(playerid,115);
dini_IntSet(file"Skin"115);
new 
TiiP[1500];
strcat(TiiP,"{9F23B5}Seja bem vindo ao Lost Players!\n");
strcat(TiiP,"{9F23B5}Obrigado por se registrar em nosso servidor.\n");
strcat(TiiP,"{58ACFA}[~] Quer ver o tutorial? {C92DE5}/tutorial\n");
strcat(TiiP,"{58ACFA}[~] Precisa de ajuda? {C92DE5}/relatorio\n");
strcat(TiiP,"{58ACFA}[~] Mais informaзхes: {C92DE5}/informacoes");
ShowPlayerDialog(playeridaviso2DIALOG_STYLE_MSGBOX"{C92DE5}•{9F23B5} Fim!"TiiP"Fechar""");
}
if(
dini_Int(file"Preso") == 1)
{
SetPlayerPos(playerid263.8820,77.4002,1001.0391);
SetPlayerInterior(playerid6);
SetPlayerHealth(playerid,99999);
ResetPlayerWeapons(playerid);
TogglePlayerControllable(playerid1);
SendClientMessage(playeridmsgdm"[~] Vocк estava preso ao deslogar do servidor. Contrate um advogado ou pague /fianca");
preso[playerid] = 1;
dini_IntSet(file2"ofmaconha"0);
dini_IntSet(file2"ofcocaina"0);
dini_IntSet(file2"ofcrack"0);
dini_IntSet(file"usoudroga"0);
dini_IntSet(file"tmaconha"0);
dini_IntSet(file"tcrack"0);
dini_IntSet(file"tcocaina"0);
dini_IntSet(file"Maconha"0);
dini_IntSet(file"Crack"0);
dini_IntSet(file"Cocaina"0);
}
return 
1;

Reply
#2

cara eu vi esse bug em varios server atй servidor grande como brasil playfaster ( de vez inquando acontece ) sу clikar em " SPAWN " q volta normal ....
Reply
#3

Quote:
Originally Posted by ScripterInicianteBR
Посмотреть сообщение
cara eu vi esse bug em varios server atй servidor grande como brasil playfaster ( de vez inquando acontece ) sу clikar em " SPAWN " q volta normal ....
Acontece que fica feio, alйm de chato..
Eu queria alguma coisa que eu possa fazer para nгo acontecer mais isso.
:/
Reply
#4

Alguйm ai sabe?

Precisando muito de um HELP ;/
Reply
#5

pawn Код:
TogglePlayerSpectating(playerid, 1);
Reply
#6

Quote:
Originally Posted by Jimmmy
Посмотреть сообщение
pawn Код:
TogglePlayerSpectating(playerid, 1);
Onde coloco isso? OnPlayerDeath ou OnPlayerSpawn?
Reply
#7

O tempo de alguйm responder, vocк poderia ter testado no OnPlayerDeath e no Spawn e saberia qual era '-'
nгo e mais facil ? '-'
Reply
#8

Quote:
Originally Posted by Madhrer
Посмотреть сообщение
O tempo de alguйm responder, vocк poderia ter testado no OnPlayerDeath e no Spawn e saberia qual era '-'
nгo e mais facil ? '-'
Amigo, olha a data desse post.
Eu jб estou atй desenvolvendo um Gamemode do 0
kkkkk

Atenciosamente,
TiiP
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)