[Ajuda] Criar varias plantaзхes
#1

Salve galera, estou criando um sistema de plantaзгo de maconha do 0 e queria fazer uma coisa mas nгo tenho ideia de como fazer. Й tipo assim vai ter vбrios ID's de plantaзгo, ID: 1, ID: 2... e assim por diante. Consegui criar a ID: 1 mas queria criar uma do lado da outra alguйm tem ideia de como faзo isso? Eu queria que ficasse assim: ID: 1 em uma posiзгo, e a ID: 2 do lado dela, e assim por diante. Aqui estгo as prints de como esta no momento: https://imgur.com/a/JL1njN0

PHP код:
if(strcmp("/colher"cmdtexttrue10) == 0)
    {
        if(
PlayerLeo[playerid][Profissao] != FAZENDEIRO) {
            
SendClientMessage(playeridCOR_ERRO"| ERRO | Vocк nгo й um fazendeiro.");
            return 
1;
        }
        if(
Colher[playerid] == 1) {
            
SendClientMessage(playeridCOR_ERRO"| ERRO | A sua maconha ainda nгo esta pronta para colher");
            return 
1;
        }
        if(
Colhido[playerid] == 1) {
            
SendClientMessage(playeridCOR_ERRO"| ERRO | Vocк jб colheu, plante novamente.");
            return 
1;
        }
        new 
string[128];
        new 
gramas random(300);
        new 
grana random(3000 1000) + 2000;
        
GivePlayerMoney(playeridgrana);
        
Colhido[playerid] = 1;
        
Plantando[playerid] = 0;
        
DestroyObject(Maconha[1]);
        
Delete3DTextLabel(Text3D:MaconhaL[1]);
        
format(stringsizeof(string), "| INFO | Vocк colheu {FF0000}%d gramas{FFFFFF} de maconha, e recebeu {228B22}R$%d{FFFFFF}."gramasgrana);
        
SendClientMessage(playerid, -1string);
        return 
1;
        } 
PHP код:
if(strcmp("/plantarmaconha"cmdtexttrue10) == 0)
    {
        if(
PlayerLeo[playerid][Profissao] != FAZENDEIRO) {
            
SendClientMessage(playeridCOR_ERRO"| ERRO | Vocк nгo й um fazendeiro");
            return 
1;
        }
        if(
PlayerLeo[playerid][Sementes] <= 2) {
            
SendClientMessage(playeridCOR_ERRO"| ERRO | Vocк nгo tem sementes o suficiente para plantar maconha (2 Sementes necessбrias)");
            return 
1;
        }
        if(
Plantando[playerid] == 1) {
            
SendClientMessage(playeridCOR_ERRO"| ERRO | Jб comeзou a plantar espere atй crescer para plantar novamente.");
            return 
1;
        }
        new 
string[128];
        
SendClientMessage(playerid, -1"| INFO | Vocк comeзou a plantar maconha, espere atй crescer e colha.");
        
ApplyAnimation(playerid,"BOMBER""BOM_Plant"4.00000320001);
        
ApplyAnimation(playerid,"BOMBER""BOM_Plant"4.00000320001);
        
PlayerLeo[playerid][Sementes] -= 2;
        
Plantando[playerid] = 1;
        
Colher[playerid] = 1;
        
Colhido[playerid] = 0;
        
MaconhaL[1] = format(stringsizeof(string), "Plantaзгo ID: 1 de {32CD32}%s"GetPlayerNome(playerid));
        
Create3DTextLabel(string0xFFFFFFFF, -1052.03845, -1611.9676576.000010.00);
        
SetTimerEx("Plantar1"30000false"i"playerid);
        return 
1;
    } 
PHP код:
public Plantar1(playerid)
{
    
Colher[playerid] = 0;
    
SendClientMessage(playerid, -1"| INFO | {FF0000}Maconha{FFFFFF} pronta para ser colhida.");
    
Maconha[1] = CreateObject(3409, -1052.03845, -1611.9676574.7571,   0.000000.000000.00000);
    return 
1;

Reply


Messages In This Thread
Criar varias plantaзхes - by iAplle - 25.03.2019, 01:33
Re: Criar varias plantaзхes - by GuiKommander - 25.03.2019, 01:54
Re: Criar varias plantaзхes - by iAplle - 25.03.2019, 02:17
Re: Criar varias plantaзхes - by RenanMsV - 25.03.2019, 02:21
Re: Criar varias plantaзхes - by RiqueP - 25.03.2019, 13:56
Re: Criar varias plantaзхes - by iAplle - 25.03.2019, 19:11
Re: Criar varias plantaзхes - by RiqueP - 25.03.2019, 20:03
Re: Criar varias plantaзхes - by iAplle - 25.03.2019, 20:51
Re: Criar varias plantaзхes - by iAplle - 26.03.2019, 01:31

Forum Jump:


Users browsing this thread: 1 Guest(s)