15.12.2012, 14:41
Iae gente blza ?
Bom , eu sou novato em PAWN e mtooo noob aiinda ... Aii eu to criando o meu primeiro Filterscript , qe й sistema de Farmacia que o player vai em determinado ponto , faz um comando e abre uma dialog com opзхes de cura pra ele escolher ... Maiis ta dando erro euu nao sei porque , eu fiz certinho po ):
E OS ERROS QUE DAO SAO ESSES AKI :
Queria que voces me falassem ae porque ta acontecendo isso , se quiserem deixar dicas tambйm eu fico muito agradecido ! Quero muito aprender PAWN ! *-*'
Bom , eu sou novato em PAWN e mtooo noob aiinda ... Aii eu to criando o meu primeiro Filterscript , qe й sistema de Farmacia que o player vai em determinado ponto , faz um comando e abre uma dialog com opзхes de cura pra ele escolher ... Maiis ta dando erro euu nao sei porque , eu fiz certinho po ):
pawn Код:
#include <a_samp>
#define FILTERSCRIPT
//=== [Defines Cores] ===
#define COR_VERDE_FLUORESCENTE 0x00F600AA
#define COR_AZULNEUTRO 0xABCDEF01
#define COR_AZUL_PISCINA 0x00FFFFAA
#define COR_VERMELHO 0xFF0000FF
#define COR_VERDE_ABACATE 0xB6FC69FF
#define COR_AMARELO 0xFFFF00AA
#define COR_BRANCO 0xFFFFFFAA
#define COR_CINZA_AZUL 0x456EAF67
#define COR_AZUL 0x0000FFAA
#define COR_AZULMEDIO 0x63AFF00A
#define COR_CINZA 0xAFAFAFAA
#define COR_ROXO 0x9900FFAA
#define COR_VIOLETA 0x9955DEEE
#define COR_MARROM 0x993300AA
#define COR_MARROMCLARO 0x99934EFA
#define COR_LARANJA 0xFF9933AA
#define COR_ROSA_DANONE 0xFF66FFAA
#define COR_AZULCLARO 0x33CCFFAA
#define COR_AMARELOCLARO 0xFFFFCCAA
#define COR_3DLABEL 0xF68E00F6
#if defined FILTERSCRIPT
public OnFilterScriptInit()
{
print("\n--------------------------------------");
print(" Farmacias BNR - BY: Felipe_Chierice");
print("--------------------------------------\n");
//=-=-=-=-=-=-=-=-=-=[PICKUPS]=-=-=-=-=-=-=-=-=-=
AddStaticPickup(1241, 1, 2467.1143,-1743.7295,13.5469, 1.0);
//=-=-=-=-=-=-=-=-=-=[3DTEXTS]=-=-=-=-=-=-=-=-=-=
Create3DTextLabel("Farmacia\nUse /farmacia", COR_3DLABEL, 2467.1143,-1743.7295,13.5469, 7, 0);
return 1;
public OnPlayerCommandText(playerid, cmdtext[])
{
if(strcmp(cmdtext, "/farmacia", true) == 0)
{
if(PlayerToPoint(1.0, playerid, 2467.1143,-1743.7295,13.5469)) // O Player tem que estar nesse local dessas cordenadas
{
ShowPlayerDialog(playerid, farmacia, DIALOG_STYLE_LIST, "{FF0000}Farmacia BSL", "{00F600}Band-AID (20 Saъde) - R$20\n{00F600}Remйdio (50 Saъde) - R$50\n{00F600}Kit Mйdico (100 Saъde) - R$100", "Comprar", "Sair");
}
else
{
SendClientMessage(playerid, COR_AMARELO, "[INFO] Vocк nгo estб em nenhuma das farmбcias de Los Santos.");
}
return 1;
}
return 0;
}
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]) // Dialogs
{
if(dialogid == farmacia) // ID da dialog
{
if(response)
{
if(listitem == 0) // Band-AID
{
if(GetPlayerMoney(playerid) < 20)
{
SendClientMessage(playerid, COR_VERMELHO,"[INFO] Vocк precisa de R$20 para comprar o Band-AID.");
}
if(GetPlayerMoney(playerid) >= 20)
{
SendClientMessage(playerid, COR_AMARELO,"Vocк comprou um Band-AID e recuperou 20 de Saъde.");
GivePlayerHealth(playerid, 20); // Irб acrescentar 20 de vida ao player
PlayerPlaySound(playerid,1057,0.0,0.0,0.0); // Som que irб fazer na hora que comprar a bebida
GivePlayerMoney(playerid, -20); // Irб gastar R$20 do player
}
}
if(listitem == 1) // Remйdio
{
if(GetPlayerMoney(playerid) < 50)
{
SendClientMessage(playerid, COR_VERMELHO,"[INFO] Vocк precisa de R$50 para comprar o Remйdio.");
}
if(GetPlayerMoney(playerid) >= 50)
{
SendClientMessage(playerid, COR_AMARELO,"Vocк comprou uma Remйdio e curou 50 de Saъde.");
GivePlayerHealth(playerid, 50); // Irб acrescentar 50 de vida ao player
PlayerPlaySound(playerid,1057,0.0,0.0,0.0); // Som que irб fazer na hora que comprar a bebida
GivePlayerMoney(playerid, -50); // Irб gastar R$50 do player
}
}
if(listitem == 2) // Kit Mйdico
{
if(GetPlayerMoney(playerid) < 100)
{
SendClientMessage(playerid, COR_VERMELHO,"[INFO] Vocк precisa de R$100 para comprar o Kit Mйdico.");
}
if(GetPlayerMoney(playerid) >= 100)
{
SendClientMessage(playerid, COR_AMARELO,"Vocк comprou um Kit Mйdico e curou toda sua vida.");
GivePlayerHealth(playerid, 100); // Irб acrescentar 100 de vida ao player
PlayerPlaySound(playerid,1057,0.0,0.0,0.0); // Som que irб fazer na hora que comprar a bebida
GivePlayerMoney(playerid, -100); // Irб gastar R$100 do player
}
}
}
}
return 1;
}
#endif
pawn Код:
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(35) : warning 213: tag mismatch
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(40) : warning 225: unreachable code
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(40) : warning 217: loose indentation
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(40) : error 029: invalid expression, assumed zero
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(40) : error 004: function "OnPlayerCommandText" is not implemented
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(42) : error 017: undefined symbol "cmdtext"
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(44) : error 017: undefined symbol "PlayerToPoint"
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(46) : error 017: undefined symbol "playerid"
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(50) : error 017: undefined symbol "playerid"
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(57) : warning 225: unreachable code
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(57) : error 029: invalid expression, assumed zero
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(57) : error 004: function "OnDialogResponse" is not implemented
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(59) : error 017: undefined symbol "dialogid"
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(61) : error 017: undefined symbol "response"
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(63) : error 017: undefined symbol "listitem"
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(65) : error 017: undefined symbol "playerid"
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(67) : error 017: undefined symbol "playerid"
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(69) : error 017: undefined symbol "playerid"
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(71) : error 017: undefined symbol "playerid"
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(72) : error 017: undefined symbol "GivePlayerHealth"
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(73) : error 017: undefined symbol "playerid"
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(74) : error 017: undefined symbol "playerid"
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(77) : error 017: undefined symbol "listitem"
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(79) : error 017: undefined symbol "playerid"
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(81) : error 017: undefined symbol "playerid"
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(83) : error 017: undefined symbol "playerid"
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(85) : error 017: undefined symbol "playerid"
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(86) : error 017: undefined symbol "GivePlayerHealth"
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(87) : error 017: undefined symbol "playerid"
C:\Documents and Settings\Kieryce\Meus documentos\Cуpia (2) de Servidor BrasilNewRPG\filterscripts\Farmacia.pwn(88) : error 017: undefined symbol "playerid"
Compilation aborted.Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
26 Errors.