MySQL -
smiiir - 30.10.2012
#Resolvido
Re: Evento x1 -
Vinicius_TroLL - 30.10.2012
Mande a dialog EventoC
Re: Evento x1 -
smiiir - 30.10.2012
Tinha Mandando o Cуdigo Errado, /\
Re: Evento x1 -
Vinicius_TroLL - 30.10.2012
Manda as cordenadas do evento x1 ae
Re: Evento x1 -
smiiir - 30.10.2012
pawn Код:
-2325.8257,-1637.0542,483.7031
Re: Evento x1 -
Vinicius_TroLL - 30.10.2012
Код:
public OnPlayerCommandText(playerid, cmdtext[]) {
if(!strcmp("/eventox1", cmdtext, true)) {
if(PlayerInfo[playerid][pAdmin] >= 4) {
if(!eventoIniciado) {
new name[24];
GetPlayerName(playerid, name, sizeof(name));
format(buffer, sizeof(buffer), "{FFFFFF}O admin rcon %s criou um evento x1, deseja comparecer?", name);
for(new i = GetMaxPlayers() - 1; i > -1; --i) {
ShowPlayerDialog(i, DIALOG_EVENTOX1, DIALOG_STYLE_MSGBOX, "x1", buffer, "Sim", "Nгo");
}
eventoIniciado = true;
}
}
return 1;
}
if(!strcmp("/finalizarevento", cmdtext, true)) {
if(IsPlayerAdmin(playerid)) {
if(eventoIniciado) {
for(new i = GetMaxPlayers() - 1; i > -1; --i) {
SpawnPlayer(i);
}
eventoIniciado = false;
}
}
}
return 0;
}
Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]) {
if(DIALOG_EVENTOX1 == dialogid) {
eventoX1[playerid] = true;
SetPlayerVirtualWorld(playerid, 0);
SetPlayerInterior(playerid, 10); // troque de acordo com seus interesses
SetPlayerPos(playerid, 0.0, 0.0, 0.0); // troque de acordo com seus interesses
GivePlayerWeapon(playerid, 24, 99999);
SetPlayerPos(playerid,-2325.8257,-1637.0542,483.7031);
}
return 1;
}
Espero ter ajudado
Re: Evento x1 -
smiiir - 30.10.2012
Pawn Parou de Funcionar,
Tem Algo Errado -'
Re: Evento x1 -
Vinicius_TroLL - 30.10.2012
Код:
if(!strcmp("/eventox1", cmdtext, true))
{
if(IsPlayerConnected(playerid))
{
if(PlayerInfo[playerid][pAdmin] >= 1)
{
if(!eventoIniciado)
{
new name[24];
GetPlayerName(playerid, name, sizeof(name));
format(buffer, sizeof(buffer), "{FFFFFF}O admin rcon %s criou um evento x1, deseja comparecer?", name);
for(new i = GetMaxPlayers() - 1; i > -1; --i) {
ShowPlayerDialog(i, DIALOG_EVENTOX1, DIALOG_STYLE_MSGBOX, "x1", buffer, "Sim", "Nгo");
}
eventoIniciado = true;
}
}
return 1;
}
Tenta ae
Re: Evento x1 -
smiiir - 30.10.2012
FAIL ainda,
Eu Tirei o Cуdigo lб do OnDialogResponse
Ai deu uns erros
Axo que o erro й no OnDialogResponse
quando eu tirei e coloquei o seu Novo Cуdigo /\
deu esse erro:
pawn Код:
C:\Users\Admin\Desktop\TESTE\gamemodes\new.pwn(22553) : warning 202: number of arguments does not match definition
C:\Users\Admin\Desktop\TESTE\gamemodes\new.pwn(24868) : warning 202: number of arguments does not match definition
CC:\Users\Admin\Desktop\TESTE\gamemodes\new.pwn(37871) : error 017: undefined symbol "eventoIniciado"
C:\Users\Admin\Desktop\TESTE\gamemodes\new.pwnn(37875) : error 017: undefined symbol "buffer"
C:\Users\Admin\Desktop\TESTE\gamemodes\new.pwn(37875) : error 017: undefined symbol "buffer"
C:\Users\Admin\Desktop\TESTE\gamemodes\new.pwn(37875) : error 029: invalid expression, assumed zero
C:\Users\Admin\Desktop\TESTE\gamemodes\new.pwn(37875) : fatal error 107: too many error messages on one line
Re: Evento x1 -
Vinicius_TroLL - 30.10.2012
Код:
if(!strcmp("/eventox1", cmdtext, true))
{
if(IsPlayerConnected(playerid))
{
if(PlayerInfo[playerid][pAdmin] >= 1)
{
if(!eventoIniciado)
{
new name[24];
GetPlayerName(playerid, name, sizeof(name));
format(buffer, sizeof(buffer), "{FFFFFF}O admin rcon %s criou um evento x1, deseja comparecer?", name);
for(new i = GetMaxPlayers() - 1; i > -1; --i) {
ShowPlayerDialog(i, DIALOG_EVENTOX1, DIALOG_STYLE_MSGBOX, "x1", buffer, "Sim", "Nгo");
}
eventoIniciado = true;
}
}
}
return 1;
}