Pomoc oko CMD! lagano za neke iskusnije xD

12. Feb. 2020.
793
pregleda
4
postova
Nemanja Petrovic
4
Made Man
12. Feb. 2020.
Problem(error/warning): Neko mi napravi sistem kada se ubere droga da se doda u slotove i kada igrac kuca /droga view da se vidi na tim slotovima.. Kod mene je situacija da kada se obere droga i kuca se /droga view svi slotovi su opet prazni...
Dio skripte: DROGA OBERI
	else if( strcmp( item, "oberi",true) == 0) {
    new found, plantid;
    for( new i = 1; i < MAX_PLANTS; i++) {
        if( IsPlayerInRangeOfPoint( playerid, 2.0, DrogaStab[ i ], DrogaStab[ i ], DrogaStab[ i ] ) ) {
            plantid = i;
            found = 1;
            break;
        }
        else
            continue;
    }
    if( found == 0 ) return GRESKA( playerid, "Niste blizu posadjene stabiljke.");
    if( strcmp( ImeIgraca( playerid ), DrogaStab[ plantid ][ wOwner ], true) == 0 )
{
    if( DrogaStab[ plantid ][ wType ] == 1 ) {
if( DrogaStab[ plantid ][ wHoursPassed ] >= 0 && DrogaStab[ plantid ][ wHoursPassed ] < 2 )
{
    SCM( playerid, ATLASGAMINGOGC, "* Prerano si ubrao marihuanu i nisi dobio ni jedan gram. " );
}
if( DrogaStab[ plantid ][ wHoursPassed ] >= 2 && DrogaStab[ plantid ][ wHoursPassed ] < 4 )
{
    SCM( playerid, ATLASGAMINGOGC, "* Ubrao si marihuanu i uzeo 2 grama. " );
    PlayerInfo[ playerid ][ xMarihuana ] += 2;
}
if( DrogaStab[ plantid ][ wHoursPassed ] >= 4 && DrogaStab[ plantid ][ wHoursPassed ] < 6 )
{
        SCM( playerid, ATLASGAMINGOGC, "* Ubrao si marihuanu i uzeo 3 grama. " );
        PlayerInfo[ playerid ][ xMarihuana ] += 3;
    }
    if( DrogaStab[ plantid ][ wHoursPassed ] >= 6 && DrogaStab[ plantid ][ wHoursPassed ] <= 8 )
    {
        SCM( playerid, ATLASGAMINGOGC, "* Ubrao si marihuanu i uzeo 4 grama. " );
        PlayerInfo[ playerid ][ xMarihuana ] += 4;
    }
    if( DrogaStab[ plantid ][ wHoursPassed ] > 8 && DrogaStab[ plantid ][ wHoursPassed ] <= 9 )
    {
        SCM( playerid, ATLASGAMINGOGC, "* Ubrao si marihuanu i uzeo 1 gram. " );
        PlayerInfo[ playerid ][ xMarihuana ] += 1;
    }
    if( DrogaStab[ plantid ][ wHoursPassed ] > 9 )
    {
        SCM( playerid, ATLASGAMINGOGC, "* Kasno si ubrao marihuanu, te nisi dobio ni jedan gram. " );
    }

    DrogaStab[ plantid ] = 0;
  DrogaStab[ plantid ] = 0;
  DrogaStab[ plantid ] = 0;
  DrogaStab[ plantid ] = 0;
DrogaStab[ plantid ] = 0;
DrogaStab[ plantid ] = 0;
strmid( DrogaStab[ plantid ][ wOwner ], "Niko", 0, strlen( "Niko" ), 255);
DrogaStab[ plantid ] = GetPlayerVirtualWorld( playerid );
    DestroyDynamicObject( DrogaStab[ plantid ][ wObjectID ] );
            ApplyAnimation( playerid, "BOMBER","BOM_Plant_Loop",4.0,0,0,0,0,0,1);
    format( globalstring, sizeof( globalstring ), "%s ubire marihuanu.", ImeIgraca( playerid ) );
PorukaRadius(10.0, playerid, globalstring, LJUBICASTA );
IgracPosadio[ playerid ]--;
}
else if( DrogaStab[ plantid ][ wType ] == 2 ) {

    if( DrogaStab[ plantid ][ wHoursPassed ] <= 2 )
{
    SCM( playerid, ATLASGAMINGOGC, "* Prerano si ubrao kokain i nisi dobio ni jedan gram. " );
}
if( DrogaStab[ plantid ][ wHoursPassed ] > 11 )
    {
        SCM( playerid, ATLASGAMINGOGC, "* Kasno si ubrao kokain, te nisi dobio ni jedan gram. " );
    }
    if( DrogaStab[ plantid ][ wHoursPassed ] >= 3 && DrogaStab[ plantid ][ wHoursPassed ] <= 10 )
    {
        kolicina = DrogaStab[ plantid ][ wHoursPassed ]*5;
        SendClientMessageEx( playerid, ATLASGAMINGOGC, "* Ubrao si neosuseni kokain i uzeo %d grama. ", kolicina );
        PlayerInfo[ playerid ][ xKokain2 ] += kolicina;
    }

    DrogaStab[ plantid ] = 0;
  DrogaStab[ plantid ] = 0;
  DrogaStab[ plantid ] = 0;
  DrogaStab[ plantid ] = 0;
DrogaStab[ plantid ] = 0;
DrogaStab[ plantid ] = 0;
strmid( DrogaStab[ plantid ][ wOwner ], "Niko", 0, strlen( "Niko" ), 255);
DrogaStab[ plantid ] = GetPlayerVirtualWorld( playerid );
    DestroyDynamicObject( DrogaStab[ plantid ][ wObjectID ] );
            ApplyAnimation( playerid, "BOMBER","BOM_Plant_Loop",4.0,0,0,0,0,0,1);
    format( globalstring, sizeof( globalstring ), "%s ubire stabiljku kokaina.", ImeIgraca( playerid ) );
PorukaRadius(10.0, playerid, globalstring, LJUBICASTA );
IgracPosadio[ playerid ]--;
}
}
else GRESKA( playerid, "Ovo nije tvoja stabiljka droge. " );
    return 1;
}

DROGA VIEW
    else if( strcmp( item, "view",true) == 0)
    {
        SCM( playerid, SVETLOPLAVA, "[_________________________ MOJE DROGE _________________________=]");
        format( globalstring, sizeof( globalstring ), "Slot 1: [%s(%d g)]", GetDrugNameByDrugID( PlayerInfo[ playerid ][ xDrugCode ][ 0 ] ), PlayerInfo[ playerid ][ xDrug ][ 0 ] );
SCM( playerid, BELA, globalstring);
format( globalstring, sizeof( globalstring ), "Slot 2: [%s(%d g)]", GetDrugNameByDrugID( PlayerInfo[ playerid ][ xDrugCode ][ 1 ] ), PlayerInfo[ playerid ][ xDrug ][ 1 ] );
SCM( playerid, BELA, globalstring);
format( globalstring, sizeof( globalstring ), "Slot 3: [%s(%d g)]", GetDrugNameByDrugID( PlayerInfo[ playerid ][ xDrugCode ][ 2 ] ), PlayerInfo[ playerid ][ xDrug ][ 2 ] );
SCM( playerid, BELA, globalstring);
format( globalstring, sizeof( globalstring ), "Slot 4: [%s(%d g)]", GetDrugNameByDrugID( PlayerInfo[ playerid ][ xDrugCode ][ 3 ] ), PlayerInfo[ playerid ][ xDrug ][ 3 ] );
SCM( playerid, BELA, globalstring);
format( globalstring, sizeof( globalstring ), "Slot 5: [%s(%d g)]", GetDrugNameByDrugID( PlayerInfo[ playerid ][ xDrugCode ][ 4 ] ), PlayerInfo[ playerid ][ xDrug ][ 4 ] );
SCM( playerid, BELA, globalstring);
SCM( playerid, SVETLOPLAVA, "");
return 1;
}

Debug iz server_log(ukoliko je u pitanju crashanje servera - crashdetect log): //
Slika/video ingame problema(obavezno ako je ingame problem): //
pjer_gancer
2
Street Runner
13. Feb. 2020.
pa imas vec ne treba ti nasa pomoc
Nemanja Petrovic
4
Made Man
13. Feb. 2020.
pjer_gancer wrote on February 13, 2020, 7:39 am:
pa imas vec ne treba ti nasa pomoc

Ma de imam nece da radi IG probao sam, ne dodaje se droga u slotovima kad je oberes..
Nemanja Petrovic
4
Made Man
14. Feb. 2020.
Neko? Ode mi tema.

Morate biti prijavljeni da biste odgovorili na ovu temu.

Prijava

© 2026 SmartShark. All rights reserved.

Powered by Momentum|v2026.3.001 Alpha