Bug help
#1

Greetings! Got a bug in my script. I made a command, and tested it out IG. When I use the command, nothing happens. Here's the code.

PHP код:
//The command
CMD:learnskill(playeridparams[])
{
     if(
IsPlayerConnected(playerid))
     {
          
LearnDialog(playerid);
    }
    return 
1;
}
//LearnDialog(playerid)
stock LearnDialog(playerid)
{
    new 
string[613];
    new 
hstring[65];
    
format(hstringsizeof(hstring), "Choose the skill/ability you wish to learn: (%d Learning Points)"PlayerInfo[playerid][pLearn]);
    switch(
PlayerInfo[playerid][pSpecial])
    {
         case 
1://Humans
         
{
              
format(stringsizeof(string), "Unarmed/Strength (Learned Rank: %d/3)\nKnife (Learned Rank: %d/5)\nKatana (Learned Rank: %d/3)\nColt 45 (Learned Rank: %d/3)\n",
            
Skills[playerid][Unarmed],Skills[playerid][Knife],Skills[playerid][Katana], Skills[playerid][Colt45]);
            return 
1;
        }
    }
    return 
1;

Yes, I have tried changing to Human class, but it still doesn't work. I even tried changing to all classes.
Reply


Messages In This Thread
Bug help - by NealPeteros - 09.10.2016, 08:18
Re: Bug help - by Konstantinos - 09.10.2016, 08:20
Re: Bug help - by NealPeteros - 09.10.2016, 08:23

Forum Jump:


Users browsing this thread: 1 Guest(s)