Jump to content
  • 0

Ma puteti scapa si pe mine de aceste erori va rog frumos!!


Question

Guest Bug_Mafia
Posted

if(strcmp(cmd,"/buylicense",true)==0)

    {

        if(IsPlayerConnected(playerid))

    {

            if(PlayerToPoint(25.0,playerid,1492.6129,1308.1138,1093.2937))

            {

              new x_nr[256];

  x_nr = strtok(cmdtext, idx);

  if(!strlen(x_nr)) {

      SendClientMessage(playerid, COLOR_DBLUE, "|__________________ Licenses __________________|");

  SendClientMessage(playerid, COLOR_LIGHTBLUE, "USAGE: /buylicense [name]");

  SendClientMessage(playerid, COLOR_YELLOW, "Available names: Driving  (500$)");

  SendClientMessage(playerid, COLOR_YELLOW, "Available names: Flying    (8000$)");

  SendClientMessage(playerid, COLOR_YELLOW, "Available names: Sailing  (4500$)");

  SendClientMessage(playerid, COLOR_YELLOW, "Available names: Fishing  (2000$)");

  SendClientMessage(playerid, COLOR_YELLOW, "Available names: Gun      (15000$)");

  SendClientMessage(playerid, COLOR_DBLUE, "|____________________________________________|");

  return 1;

  }

          if(strcmp(x_nr,"Driving",true) == 0)

  {

      if(PlayerInfo[playerid][pCarLic] < 1)

                if(GetPlayerCash(playerid) < 500)

          {

        format(string, sizeof(string), ".: Driving License costs $500, You don't have enough :.");

        SendClientMessage(playerid, COLOR_WHITE, string);

        return 1;

      }

              if(PlayerInfo[playerid][pCarLic] == 1)

          {

        format(string, sizeof(string), ".: You already have a Driving license :.");

        SendClientMessage(playerid, COLOR_WHITE, string);

        return 1;

      }

                  PlayerInfo[playerid][pCarLic] = 1;

      SendClientMessage(playerid,COLOR_WHITE,".: You can now drive cars :.");

          GivePlayerCash(playerid,-500);

  }

  else if(strcmp(x_nr,"Flying",true) == 0)

  {

                  if(PlayerInfo[playerid][pFlyLic] < 1)

                if(GetPlayerCash(playerid) < 8000)

          {

        format(string, sizeof(string), ".:Flying License costs $8000, You don't have enough :.");

        SendClientMessage(playerid, COLOR_WHITE, string);

        return 1;

      }

              if(PlayerInfo[playerid][pFlyLic] == 1)

          {

        format(string, sizeof(string), ".: You already have a Flying license :.");

        SendClientMessage(playerid, COLOR_WHITE, string);

        return 1;

      }

                  PlayerInfo[playerid][pFlyLic] = 1;

      SendClientMessage(playerid,COLOR_WHITE,".: You can now drive Helys and Planes :.");

          GivePlayerCash(playerid,-8000);

              }

              else if(strcmp(x_nr,"Sailing",true) == 0)

  {

                  if(PlayerInfo[playerid][pBoatLic] < 1)

                if(GetPlayerCash(playerid) < 4500)

          {

        format(string, sizeof(string), ".:Sailing License costs $4500, You don't have enough :.");

        SendClientMessage(playerid, COLOR_WHITE, string);

        return 1;

      }

              if(PlayerInfo[playerid][pBoatLic] == 1)

          {

        format(string, sizeof(string), ".: You already have a Sailing license :.");

        SendClientMessage(playerid, COLOR_WHITE, string);

        return 1;

      }

                  PlayerInfo[playerid][pBoatLic] = 1;

      SendClientMessage(playerid,COLOR_WHITE,".: You can now drive Boats :.");

          GivePlayerCash(playerid,-4500);

              }

              else if(strcmp(x_nr,"Fishing",true) == 0)

  {

                  if(PlayerInfo[playerid][pFishLic] < 1)

                if(GetPlayerCash(playerid) < 2000)

          {

        format(string, sizeof(string), ".:Fishing License costs $2000, You don't have enough :.");

        SendClientMessage(playerid, COLOR_WHITE, string);

        return 1;

      }

              if(PlayerInfo[playerid][pFishLic] == 1)

          {

        format(string, sizeof(string), ".: You already have a Fishing license :.");

        SendClientMessage(playerid, COLOR_WHITE, string);

        return 1;

      }

                  PlayerInfo[playerid][pFishLic] = 1;

      SendClientMessage(playerid,COLOR_WHITE,".: You can now Fish Safe :.");

          GivePlayerCash(playerid,-2000);

              }

              else if(strcmp(x_nr,"Gun",true) == 0)

  {

                  if(PlayerInfo[playerid][pGunLic] < 1)

                if(GetPlayerCash(playerid) < 15000)

          {

        format(string, sizeof(string), ".:Gun License costs $15000, You don't have enough :.");

        SendClientMessage(playerid, COLOR_WHITE, string);

        return 1;

      }

              if(PlayerInfo[playerid][pGunLic] == 1)

          {

        format(string, sizeof(string), ".: You already have a Gun license :.");

        SendClientMessage(playerid, COLOR_WHITE, string);

        return 1;

      }

                  PlayerInfo[playerid][pGunLic] = 1;

      SendClientMessage(playerid,COLOR_WHITE,".: You can now have a Gun Safe :.");

          GivePlayerCash(playerid,-15000);

              }

            }

else

{

SendClientMessage(playerid, COLOR_GREY, "  You are not in the City Hall !");

            return 1;

}

        }//not connected

return 1;

}

18 answers to this question

Recommended Posts

Guest Bug_Mafia
Posted

Cand dau compile imi apar cel putin 10 erori din cate am vazut imi puteti face sa nu mai apara nici una?

Guest Bug_Mafia
Posted

C:Documents and SettingsSmookEDesktopGameZone RPGGameZone RPGGameZone RPGGameZone RPGX2gamemodescel mai smecher mod.pwn(10219) : error 017: undefined symbol "GetPlayerCash"

C:Documents and SettingsSmookEDesktopGameZone RPGGameZone RPGGameZone RPGGameZone RPGX2gamemodescel mai smecher mod.pwn(10233) : error 017: undefined symbol "GivePlayerCash"

C:Documents and SettingsSmookEDesktopGameZone RPGGameZone RPGGameZone RPGGameZone RPGX2gamemodescel mai smecher mod.pwn(10238) : error 017: undefined symbol "GetPlayerCash"

C:Documents and SettingsSmookEDesktopGameZone RPGGameZone RPGGameZone RPGGameZone RPGX2gamemodescel mai smecher mod.pwn(10252) : error 017: undefined symbol "GivePlayerCash"

C:Documents and SettingsSmookEDesktopGameZone RPGGameZone RPGGameZone RPGGameZone RPGX2gamemodescel mai smecher mod.pwn(10257) : error 017: undefined symbol "GetPlayerCash"

C:Documents and SettingsSmookEDesktopGameZone RPGGameZone RPGGameZone RPGGameZone RPGX2gamemodescel mai smecher mod.pwn(10271) : error 017: undefined symbol "GivePlayerCash"

C:Documents and SettingsSmookEDesktopGameZone RPGGameZone RPGGameZone RPGGameZone RPGX2gamemodescel mai smecher mod.pwn(10276) : error 017: undefined symbol "GetPlayerCash"

C:Documents and SettingsSmookEDesktopGameZone RPGGameZone RPGGameZone RPGGameZone RPGX2gamemodescel mai smecher mod.pwn(10290) : error 017: undefined symbol "GivePlayerCash"

C:Documents and SettingsSmookEDesktopGameZone RPGGameZone RPGGameZone RPGGameZone RPGX2gamemodescel mai smecher mod.pwn(10295) : error 017: undefined symbol "GetPlayerCash"

C:Documents and SettingsSmookEDesktopGameZone RPGGameZone RPGGameZone RPGGameZone RPGX2gamemodescel mai smecher mod.pwn(10309) : error 017: undefined symbol "GivePlayerCash"

Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase

10 Errors.

  • Administrator
Posted

Inlocuieste GetPlayerCash cu GivePlayerMoney

logo.png

ATENTIE!!! Nu imi trimiteti mesaje private care au legatura cu scriptingul. NU mai scriptez.

Guest Bug_Mafia
Posted

Am facut tot ce ai zis u dar tot imi apar erori  nu imi poti face u sa nu imi mai apara si sa postezi FS?PLS

  • Administrator
Posted

Ai includele a_players.inc ?

logo.png

ATENTIE!!! Nu imi trimiteti mesaje private care au legatura cu scriptingul. NU mai scriptez.

Guest Bug_Mafia
Posted

Sunt incepator nu stiu ce is alea dar tot ce am postat aia am daca ma poti ajuta sa nu mai aiba erori bine daca nu MULTUMESC!

  • Administrator
Posted

La tine e posibil sa nu ai un anumit include. Eu m-am uitat prin includele mele si linia GivePlayerMoney era in includele a_players.inc

Downloadeaza-l de aici si copie-l in Serverul tau in folderul Pawno/Include apoi dai F5 la scriptul tau.

logo.png

ATENTIE!!! Nu imi trimiteti mesaje private care au legatura cu scriptingul. NU mai scriptez.

Guest Bug_Mafia
Posted

Frate eu aveam aia ce mi-ai dat u nu poti sa ie iu scriptul sa il faci sa nu mai aiba erori si dupa sa il pui ?Ca am facut tot ce am putut dar tot imi apar erori :(( ajutama si pe mine!!MULTUMESC ;D

  • Administrator
Posted

Cred ca am gasit rezolvarea!

Adauga linia asta

GivePlayerMoney(playerid,PlayerInfo[playerid][pCash]);

dupa public OnPlayerConnect(playerid) si dupa public OnPlayerLogin(playerid,password[])

si dupaia

=-" post="18829" timestamp="1252938446"]

Inlocuieste GetPlayerCash cu GivePlayerMoney

logo.png

ATENTIE!!! Nu imi trimiteti mesaje private care au legatura cu scriptingul. NU mai scriptez.

Guest Bug_Mafia
Posted

FRATE AM FACUT TOT CE MI-AI ZISU DAR TOT DEGEABA IN LOC DE 10 ERORI AKUM APAR 36 EU TE-AM RUGAT SA FACI U SCRIPTUL SA II SCOTI ERORILE SI DUPA SA IL PUI DAR DACA NU VREI ASTA E MULTUMESC INCA O DATA!!!

Posted

FRATE AM FACUT TOT CE MI-AI ZISU DAR TOT DEGEABA IN LOC DE 10 ERORI AKUM APAR 36 EU TE-AM RUGAT SA FACI U SCRIPTUL SA II SCOTI ERORILE SI DUPA SA IL PUI DAR DACA NU VREI ASTA E MULTUMESC INCA O DATA!!!

Se putea fara caps?

Daca ai spune care sunt cele 36 de erori am incerca sa te ajutam.

Guest Bug_Mafia
Posted

Frate eu v-am pus scriptul sus de tot si v-am rugat daca puteti sa imi scoateti erorile din el si dupa sa mi-l puneti si mie sa il download.Dar daca am vazut ca nu ma puteti ajuta si am si mai multe erori atunci ....

Posted

Frate eu v-am pus scriptul sus de tot si v-am rugat daca puteti sa imi scoateti erorile din el si dupa sa mi-l puneti si mie sa il download.Dar daca am vazut ca nu ma puteti ajuta si am si mai multe erori atunci ....

Noi nu ti-le putem rezolva doar iti zicem tie cum sa le rezolvi

Calea: inlocuieste "GivePlayerCash" cu "GivePlayerMoney" asta e problema dar la tine poate nu ai cv include la pawno de nu-ti merge

Imi aduc aminte cand jucam pe versiunea 0.1.. ala era SA-MP adevarat.

Va salut cu respect (pe cei care merita).

Posted

sau pune sus pe la define:

#define GivePlayerCash GivePlayerMoney

:D

Guest Bug_Mafia
Posted

TOT degeaba nu merge imi bag p**a daca nu puteti sa ma ajutati id meu este <sters>!!!

Posted

Trece sus de tot #pragma tabsize 0

Inlocuieste GivePlayerCash cu GivePlayerMoney

Inlocuieste GetPlayerCash cu GetPlayerMoney

-----------------------------------------------------------------------------

[color=blue]#pragma tabsize 0[/color]
    if(strcmp(cmd,"/buylicense",true)==0)
    {
        if(IsPlayerConnected(playerid))
        {
            if(PlayerToPoint(25.0,playerid,1492.6129,1308.1138,1093.2937))
            {
            new x_nr[256];
            x_nr = strtok(cmdtext, idx);
            if(!strlen(x_nr)) {
              SendClientMessage(playerid, COLOR_DBLUE, "|__________________ Licenses __________________|");
              SendClientMessage(playerid, COLOR_LIGHTBLUE, "USAGE: /buylicense [name]");
              SendClientMessage(playerid, COLOR_YELLOW, "Available names: Driving   (500$)");
              SendClientMessage(playerid, COLOR_YELLOW, "Available names: Flying    (8000$)");
              SendClientMessage(playerid, COLOR_YELLOW, "Available names: Sailing   (4500$)");
              SendClientMessage(playerid, COLOR_YELLOW, "Available names: Fishing   (2000$)");
              SendClientMessage(playerid, COLOR_YELLOW, "Available names: Gun       (15000$)");
              SendClientMessage(playerid, COLOR_DBLUE, "|____________________________________________|");
              return 1;
            }
            if(strcmp(x_nr,"Driving",true) == 0)
            {
               if(PlayerInfo[playerid][pCarLic] < 1)
               if(GetPlayerMoney(playerid) < 500)
                {
                  format(string, sizeof(string), ".: Driving License costs $500, You don't have enough :.");
                  SendClientMessage(playerid, COLOR_WHITE, string);
                  return 1;
               }
               if(PlayerInfo[playerid][pCarLic] == 1)
               {
                  format(string, sizeof(string), ".: You already have a Driving license :.");
                  SendClientMessage(playerid, COLOR_WHITE, string);
                  return 1;
               }
               PlayerInfo[playerid][pCarLic] = 1;
               SendClientMessage(playerid,COLOR_WHITE,".: You can now drive cars :.");
               GivePlayerMoney(playerid,-500);
            }
            else if(strcmp(x_nr,"Flying",true) == 0)
            {
                  if(PlayerInfo[playerid][pFlyLic] < 1)
                  if(GetPlayerMoney(playerid) < 8000)
                   {
                  format(string, sizeof(string), ".:Flying License costs $8000, You don't have enough :.");
                  SendClientMessage(playerid, COLOR_WHITE, string);
                  return 1;
               }
               if(PlayerInfo[playerid][pFlyLic] == 1)
               {
                  format(string, sizeof(string), ".: You already have a Flying license :.");
                  SendClientMessage(playerid, COLOR_WHITE, string);
                  return 1;
                }
                PlayerInfo[playerid][pFlyLic] = 1;
                SendClientMessage(playerid,COLOR_WHITE,".: You can now drive Helys and Planes :.");
                GivePlayerMoney(playerid,-8000);
            }
            else if(strcmp(x_nr,"Sailing",true) == 0)
            {
                  if(PlayerInfo[playerid][pBoatLic] < 1)
                  if(GetPlayerMoney(playerid) < 4500)
                {
                  format(string, sizeof(string), ".:Sailing License costs $4500, You don't have enough :.");
                  SendClientMessage(playerid, COLOR_WHITE, string);
                  return 1;
               }
               if(PlayerInfo[playerid][pBoatLic] == 1)
               {
                  format(string, sizeof(string), ".: You already have a Sailing license :.");
                  SendClientMessage(playerid, COLOR_WHITE, string);
                  return 1;
               }
               PlayerInfo[playerid][pBoatLic] = 1;
               SendClientMessage(playerid,COLOR_WHITE,".: You can now drive Boats :.");
               GivePlayerMoney(playerid,-4500);
            }
            else if(strcmp(x_nr,"Fishing",true) == 0)
            {
                  if(PlayerInfo[playerid][pFishLic] < 1)
                  if(GetPlayerMoney(playerid) < 2000)
               {
                  format(string, sizeof(string), ".:Fishing License costs $2000, You don't have enough :.");
                  SendClientMessage(playerid, COLOR_WHITE, string);
                  return 1;
               }
               if(PlayerInfo[playerid][pFishLic] == 1)
               {
                  format(string, sizeof(string), ".: You already have a Fishing license :.");
                  SendClientMessage(playerid, COLOR_WHITE, string);
                  return 1;
               }
               PlayerInfo[playerid][pFishLic] = 1;
               SendClientMessage(playerid,COLOR_WHITE,".: You can now Fish Safe :.");
               GivePlayerMoney(playerid,-2000);
            }
            else if(strcmp(x_nr,"Gun",true) == 0)
            {
                  if(PlayerInfo[playerid][pGunLic] < 1)
                  if(GetPlayerMoney(playerid) < 15000)
               {
                  format(string, sizeof(string), ".:Gun License costs $15000, You don't have enough :.");
                  SendClientMessage(playerid, COLOR_WHITE, string);
                  return 1;
               }
               if(PlayerInfo[playerid][pGunLic] == 1)
               {
                  format(string, sizeof(string), ".: You already have a Gun license :.");
                  SendClientMessage(playerid, COLOR_WHITE, string);
                  return 1;
               }
               PlayerInfo[playerid][pGunLic] = 1;
               SendClientMessage(playerid,COLOR_WHITE,".: You can now have a Gun Safe :.");
               GivePlayerMoney(playerid,-15000);
               }
            }
         else
         {
            SendClientMessage(playerid, COLOR_GREY, "   You are not in the City Hall !");
            return 1;
          }
        }//not connected
      return 1;
   }

PS: Daca nici asa nu merge da add la ID-ul meu de mess de la profil

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.