03.07.2011, 07:57
Hello!
When i compiled the script, it shows these errors
This is the full code
Please help me to fix it
When i compiled the script, it shows these errors
pawn Код:
C:\Documents and Settings\Ironboy\Desktop\0.3c package\SATDM v13 Latest\filterscripts\lang.pwn(33) : warning 202: number of arguments does not match definition
C:\Documents and Settings\Ironboy\Desktop\0.3c package\SATDM v13 Latest\filterscripts\lang.pwn(55) : warning 202: number of arguments does not match definition
Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
2 Warnings.
pawn Код:
#include <a_samp>
#include <zcmd>
#define LANG_ENGLISH 0
#define LANG_GERMAN 1
// And so on, make sure you increase that number after the language, so 0, 1, 2, 3... It's the language id.
#define LANG_DIALOG 666 // Put any number here, but make sure there isn't same dialog ID anywhere in the script.
#if defined FILTERSCRIPT
public OnFilterScriptInit()
{
print("\n--------------------------------------");
print(" Blank Filterscript by your name here");
print("--------------------------------------\n");
return 1;
}
public OnFilterScriptExit()
{
return 1;
}
#else
main()
{
print("\n----------------------------------");
print(" Blank Gamemode by your name here");
print("----------------------------------\n");
}
#endif
public OnPlayerConnect(playerid)
{
ShowPlayerDialog( playerid, LANG_DIALOG, DIALOG_STYLE_LIST, "Pick your language", "English\nGerman", "Choose" ); // Shows the dialog to pick your language upon connecting...
return 1;
}
public OnPlayerCommandText(playerid, cmdtext[])
{
return 1;
}
CMD:mylang( playerid, params[ ] ) {
if( GetPVarInt( playerid, "Language" ) == LANG_ENGLISH ) {
SendClientMessage( playerid, -1, "Your picked language is English. " );
}
else if( GetPVarInt( playerid, "Language" ) == LANG_GERMAN ) {
SendClientMessage( playerid, -1, "Ihre abgeholt Sprache ist Deutsch." ); // ****** again.
}
return 1;
}
public OnDialogResponse( playerid, dialogid, response, listitem, inputtext[ ] ) {
if( dialogid == LANG_DIALOG ) {
if( !response )
return ShowPlayerDialog( playerid, LANG_DIALOG, DIALOG_STYLE_LIST, "Pick your language", "English\nGerman", "Choose" ); // So he can't exit the dialog without choosing the language.
if( listitem == 0 ) { // If you picked English...
SetPVarInt( playerid, "Language", LANG_ENGLISH ); // Sets your language to English.
SendClientMessage( playerid, -1, "You have choosen English as your language!" );
}
if( listitem == 1 ) { // If you picked German...
SetPVarInt( playerid, "Language", LANG_GERMAN ); // Sets your language to German.
SendClientMessage( playerid, -1, "Sie haben ausgewдhlt Deutsch als Ihre Sprache!" ); // Translated with ****** Translate :p...
}
}
return 1;
}