Author Topic: My Fatal Error x_X  (Read 4333 times)

0 Members and 3 Guests are viewing this topic.

Offline sseebbyy

  • VC:MP Veteran
  • *****
  • Posts: 774
  • Immortal VC:MP Player
    • View Profile
    • Zombie Invasion => Server Forum [DEAD PROJECT]
My Fatal Error x_X
« on: January 01, 2012, 08:01:37 pm »
I'm disappointed .

I don't know how to fix my problem X_X ...

In script , i think, are all good but.. something is deleted or.. idk

not are problem on cmds... look at "givemoney" cmd:

[pawn]else if (strcmp(cmd, "givemoney", true) == 0) {
   if(IsLogged[playerid] == 0) SendClientMessage(playerid,NOTACCES,"Need to login first !");
      else if(PlayerInfo[playerid][AdminLevel] < 5) SendClientMessage(playerid,NOTACCES,"Not have permission to use this command!(AdminLevel 5+)");
      else if(IsPlayerAdmin(playerid) || PlayerInfo[playerid][AdminLevel] >= 5)
       {
      new plr, score[256], string[256];
      tmp = strtok(cmdtext, idx), plr = FindPlayerIDFromString(tmp), score = strtok(cmdtext, idx);

      if (!strlen(tmp)) SendClientMessage(playerid,COLOR_RED,"USAGE: /c givemoney [Nick/ID] [Amount]");
        else if (plr == INACTIVE_PLAYER_ID) SendClientMessage(playerid,COLOR_RED,"Error: Unknown player");
      else {
         format(string,sizeof(string),"Admin %s Give to [ %s ] money [ %d ]",gPlayers[playerid],gPlayers[plr],strval(score));
         SendClientMessageToAll(COLOR_GREEN,string);
         IncPlayerHandCash(plr,strval(score));
      }
      }else{
      SendClientMessage(playerid,NOTACCES,"***Not have permission to use this command!");
      }
      return 1;
   }[/pawn]

I have all files.

I made a video - http://youtu.be/3bs2g56ANzU

Quote
Painful/Noob scripters acts like: I Am The Best Scripter Because I Announce My Releases With Big Font Size Without Giving Too Much Info' In The Hope They All Will Download And Check It. I Ignore Bad Replies, Replies That I Could Learn From, And Replies With So Much Text.



Offline DilsonTB

  • Made Man
  • ***
  • Posts: 140
  • VC:MP Developer. & SA:MP Currently Developer
    • View Profile
Re: My Fatal Error x_X
« Reply #1 on: January 01, 2012, 08:30:48 pm »
You may check if you have this function:

[pawn]public FindPlayerIDFromString(string[])
{// for determining player id from a string  -bakasan
// fixed version
   new player = INACTIVE_PLAYER_ID;
   new p = 0;
   if ((strlen(string) <= 2) && (isnumeric(string) == 1)) {
      if (IsPlayerConnected(strval(string))) return strval(string);
      else return INACTIVE_PLAYER_ID;
   }
   while (p < MAX_PLAYERS) { if (strfind(gPlayers[p],string,true) != -1) { player=p;break; } p++; }
   if (player == INACTIVE_PLAYER_ID) {// string didnt match so check if it can be an id
      if ((strlen(string) > 2) || (isnumeric(string) == 0)) { return INACTIVE_PLAYER_ID; }
      player = strval(string);// string is numeric and not more than 2 digits
   }
   if (!IsPlayerConnected(player)) { return INACTIVE_PLAYER_ID; }
   return player;// valid id found
}[/pawn]
_______________________________________________
¬ VC:MP Squirrel Developer.
¬ VC:MP pawno Developer.
¬ SA:MP Developer.
¬
¬ Actually developing " San Fierro Roleplay - Latino ", with
my beta team testers, Mapper + Scripter ( me ), 18,000
lines, and is 34% finished. hope to finish it in 4 Or 3 Months.

- MYSQL FULL BASED.
- PCU.
_______________________________________________

Offline DilsonTB

  • Made Man
  • ***
  • Posts: 140
  • VC:MP Developer. & SA:MP Currently Developer
    • View Profile
Re: My Fatal Error x_X
« Reply #2 on: January 01, 2012, 08:34:33 pm »
Try this One:

[pawn]else if (strcmp(cmd, "givemoney", true) == 0) {
   if(IsLogged[playerid] == 0) SendClientMessage(playerid,NOTACCES,"Need to login first !");
      else if(PlayerInfo[playerid][AdminLevel] < 5) SendClientMessage(playerid,NOTACCES,"Not have permission to use this command!(AdminLevel 5+)");
      else if(IsPlayerAdmin(playerid) || PlayerInfo[playerid][AdminLevel] >= 5)
       {
      new string[256], plr, money[256];
      snick = strtok(cmdtext, idx), plr = FindPlayerIDFromString(snick), money = strtok(cmdtext, idx);

      if (!strlen(tmp)) SendClientMessage(playerid,COLOR_RED,"USAGE: /c givemoney [Nick/ID] [Amount]");
      else if (plr == INACTIVE_PLAYER_ID) SendClientMessage(playerid,COLOR_RED,"Unknown Player");
      else {
         format(string,sizeof(string),"Admin %s Give to [ %s ] money [ %d ]",gPlayers[playerid],gPlayers[plr],strval(money));
         SendClientMessageToAll(COLOR_GREEN,string);
         IncPlayerHandCash(plr,strval(money));
      }
      }else{
      SendClientMessage(playerid,NOTACCES,"***Not have permission to use this command!");
      }
      return 1;
   }[/pawn]
« Last Edit: January 01, 2012, 08:39:48 pm by DilsonTB »
_______________________________________________
¬ VC:MP Squirrel Developer.
¬ VC:MP pawno Developer.
¬ SA:MP Developer.
¬
¬ Actually developing " San Fierro Roleplay - Latino ", with
my beta team testers, Mapper + Scripter ( me ), 18,000
lines, and is 34% finished. hope to finish it in 4 Or 3 Months.

- MYSQL FULL BASED.
- PCU.
_______________________________________________

Offline sseebbyy

  • VC:MP Veteran
  • *****
  • Posts: 774
  • Immortal VC:MP Player
    • View Profile
    • Zombie Invasion => Server Forum [DEAD PROJECT]
Re: My Fatal Error x_X
« Reply #3 on: January 01, 2012, 08:58:00 pm »
You may check if you have this function:

[pawn]public FindPlayerIDFromString(string[])
{// for determining player id from a string  -bakasan
// fixed version
   new player = INACTIVE_PLAYER_ID;
   new p = 0;
   if ((strlen(string) <= 2) && (isnumeric(string) == 1)) {
      if (IsPlayerConnected(strval(string))) return strval(string);
      else return INACTIVE_PLAYER_ID;
   }
   while (p < MAX_PLAYERS) { if (strfind(gPlayers[p],string,true) != -1) { player=p;break; } p++; }
   if (player == INACTIVE_PLAYER_ID) {// string didnt match so check if it can be an id
      if ((strlen(string) > 2) || (isnumeric(string) == 0)) { return INACTIVE_PLAYER_ID; }
      player = strval(string);// string is numeric and not more than 2 digits
   }
   if (!IsPlayerConnected(player)) { return INACTIVE_PLAYER_ID; }
   return player;// valid id found
}[/pawn]

i have...

and about cmd... not the cmd is the problem...

I added IpOrigin, and after some time I took ... and I think I deleted something that broke my script

Quote
Painful/Noob scripters acts like: I Am The Best Scripter Because I Announce My Releases With Big Font Size Without Giving Too Much Info' In The Hope They All Will Download And Check It. I Ignore Bad Replies, Replies That I Could Learn From, And Replies With So Much Text.



Offline sseebbyy

  • VC:MP Veteran
  • *****
  • Posts: 774
  • Immortal VC:MP Player
    • View Profile
    • Zombie Invasion => Server Forum [DEAD PROJECT]
Re: My Fatal Error x_X
« Reply #4 on: January 02, 2012, 12:24:47 pm »
none?  :'(

PS:  I made a backup ... but i saw some errors in he ... what need to make to fix this problems ?

[pawn]D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(345) : error 017: undefined symbol "GetPlayerHandCash"
D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(471) : error 017: undefined symbol "FindPlayerIDFromString"
D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(595) : error 017: undefined symbol "IncPlayerHandCash"
D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(596) : error 017: undefined symbol "DecPlayerHandCash"
D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(611) : error 017: undefined symbol "FindPlayerIDFromString"
D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(685) : error 017: undefined symbol "FindPlayerIDFromString"
D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(705) : error 017: undefined symbol "FindPlayerIDFromString"
D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(724) : error 017: undefined symbol "HealAll"
D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(736) : error 017: undefined symbol "ArmourAll"
D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(748) : error 017: undefined symbol "CleanChat"
D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(761) : error 017: undefined symbol "FindPlayerIDFromString"
D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(782) : error 017: undefined symbol "FindPlayerIDFromString"
D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(802) : error 017: undefined symbol "FindPlayerIDFromString"
D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(822) : error 017: undefined symbol "FindPlayerIDFromString"
D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(829) : error 017: undefined symbol "SetPlayerHandScore"
D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(842) : error 017: undefined symbol "FindPlayerIDFromString"
D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(849) : error 017: undefined symbol "SetPlayerHandCash"
D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(862) : error 017: undefined symbol "FindPlayerIDFromString"
D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(869) : error 017: undefined symbol "IncPlayerHandCash"
D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(882) : error 017: undefined symbol "FindPlayerIDFromString"
D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(889) : error 017: undefined symbol "DecPlayerHandCash"
D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(903) : error 017: undefined symbol "FindPlayerIDFromString"
D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(961) : error 017: undefined symbol "FindPlayerIDFromString"
D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(966) : error 017: undefined symbol "FindWepIDFromString"
D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(982) : error 017: undefined symbol "FindPlayerIDFromString"
D:\Jocuri\Vice City\SERVER\[RBS] Romania Best Style v2\gamemodes\New folder\RO.pwn(1005) : error 017: undefined symbol "FindPlayerIDFromString"

Compilation aborted.Pawn compiler 3.0.3367         Copyright (c) 1997-2005, ITB CompuPhase


26 Errors.[/pawn]

I have all publics and stocks
« Last Edit: January 02, 2012, 01:10:29 pm by sseebbyy »

Quote
Painful/Noob scripters acts like: I Am The Best Scripter Because I Announce My Releases With Big Font Size Without Giving Too Much Info' In The Hope They All Will Download And Check It. I Ignore Bad Replies, Replies That I Could Learn From, And Replies With So Much Text.



Offline SaFeeR

  • Street Thug
  • *
  • Posts: 37
  • Pawno Scripter
    • View Profile
    • PaK-ServeR Website
Re: My Fatal Error x_X
« Reply #5 on: January 02, 2012, 01:17:11 pm »
else if ( strcmp( cmd, "setmoney", true ) == 0 )
   {
      new snick[ 128 ], plr, tmp2[ 128 ], szMsg[ 128 ];
      snick = strtok( cmdtext, idx ), plr = FindPlayerIDFromString( snick), tmp2 = strtok( cmdtext, idx );
      if ( !IsLoggedIn( playerid ) ) SendClientMessage( playerid, COLOR_RED, "Please log-in to your account." );
      else if ( !IsAuthorized( playerid, cmd ) ) SendClientMessage( playerid, COLOR_RED, "You don't have access to use this command!" );
      else if ( !strlen( tmp2 ) ) SendClientMessage( playerid, COLOR_GREEN, "USAGE: /c setmoney [Nick/ID] [Money]" );
        else if ( plr == INACTIVE_PLAYER_ID ) SendClientMessage( playerid, COLOR_RED, "Error: Unknown player" );
        else if ( !IsPlayerRegistered( gPlayers[ plr ] ) )
      {
         format( szMsg, sizeof( szMsg ), "Error: %s is not a registered nick.", gPlayers[ plr ] );
         SendClientMessage( playerid, COLOR_GREEN, szMsg );
      }
      else
      {
         format( file, sizeof( file ), USERS_FILE, gPlayers[ plr ] );
         dini_Set( file, "Cash", tmp2 );

         format( szMsg, sizeof( szMsg ), "%s's cash set to:[ %s ]", gPlayers[ plr ], tmp2 );
         SendClientMessage( playerid, COLOR_GREEN, szMsg );
         SetPlayerMoney( plr, strval( tmp2 ) );
      }
      return 1;
   }
If You Like My Scripting Like My Page


Offline sseebbyy

  • VC:MP Veteran
  • *****
  • Posts: 774
  • Immortal VC:MP Player
    • View Profile
    • Zombie Invasion => Server Forum [DEAD PROJECT]
Re: My Fatal Error x_X
« Reply #6 on: January 02, 2012, 01:44:32 pm »
I already solved the error ... with backup.

Thanks to all.


--------TOPIC CLOSED--------

Quote
Painful/Noob scripters acts like: I Am The Best Scripter Because I Announce My Releases With Big Font Size Without Giving Too Much Info' In The Hope They All Will Download And Check It. I Ignore Bad Replies, Replies That I Could Learn From, And Replies With So Much Text.