SA-MP Forums

Go Back   SA-MP Forums > Non-English > Languages > Português/Portuguese

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Old 02/06/2020, 03:27 PM   #1
OsamaBin
Big Clucker
 
Join Date: Apr 2020
Location: FIm Do Mundo, um pouco pra direita
Posts: 57
Reputation: 1
Default comando /pegarkit e /droparkit bugado

Preciso de ajuda nestes comandos:
PHP Code:
CMD:pegarkit(playerid)
{
    for(new 
0<MAX_PLAYERSi++)
    {
        if(
IsPlayerInRangeOfObject(ikit[i], 5.0))
        {
            new 
string2[200];
            
format(string2sizeof(string2), "%s pegou um Kit medico do chao."nome(playerid));
            
ProxDetector(10.0playeridstring2, -1, -1, -1, -1, -1);
            
DestroyObject(kit[playerid]);
            
SendClientMessage(playeridVermelho"Voce pegou um Kit medico dropado no chao!");
            
Pinfo[playerid][KitM] += 1;
            return 
1;
        }
        else
        {
            
SendClientMessage(playeridVermelho"Nenhum MedKit aqui!");
            return 
1;
        }
    }
    return 
1;

PHP Code:
CMD:droparkit(playerid)
{
    if(
Pinfo[playerid][KitM] == 0)
    {
        
SendClientMessage(playeridVermelho"Voce nao tem MedKits!");
        return 
1;
    }
    else
    {
        new 
FloatXFloatYFloatZ;
        
GetPlayerPos(playeridXYZ);
        
kit[playerid] = CreateObject(1241,X,Y,Z-1,0.0,0.0,0.0,300.0);
        
Pinfo[playerid][KitM] -=1;
        new 
string2[200];
         
format(string2sizeof(string2), "%s dropou um Kit medico."nome(playerid));
         
ProxDetector(10.0playeridstring2, -1, -1, -1, -1, -1);
        
SendClientMessage(playeridVermelho"Voce dropou um Kit no Chao!");
        return 
1;
    }

O jogador nao pega o kit, so diz "Nenhum medkit aqui" mesmo com ele dropado
OsamaBin is offline   Reply With Quote
 

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[Ajuda] Comando bugado. SukMathcuck Português/Portuguese 20 24/01/2015 02:38 AM
[Ajuda] Comando Bugado! DwarD Português/Portuguese 0 13/11/2014 04:54 PM
[Ajuda] Comando bugado. HumildadeForevis Português/Portuguese 12 21/06/2013 08:06 PM
[Ajuda] Comando Bugado BillieJoe Português/Portuguese 6 11/03/2013 02:00 AM
[Ajuda] Comando bugado Senhor_Azul Português/Portuguese 0 10/11/2012 07:08 AM


All times are GMT. The time now is 01:57 PM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.