Pomoc oko CMD! lagano za neke iskusnije xD


Započeo ʙᴜsᴛᴇʀ ᴄᴏɴɴᴇʟʟʏ, Februar 13, 2020, 00:24:59 PRE PODNE

prethodna tema - sledeća tema

0 članova i 1 gost pregledaju ovu temu.

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 ][Plantx], DrogaStab[ i ][Planty], DrogaStab[ i ][Plantz] ) ) {
	            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 ][Plantx] = 0;
			   	DrogaStab[ plantid ][Planty] = 0;
			   	DrogaStab[ plantid ][Plantz] = 0;
			   	DrogaStab[ plantid ][wType] = 0;
				DrogaStab[ plantid ][wPlanted] = 0;
				DrogaStab[ plantid ][wHoursPassed] = 0;
				strmid( DrogaStab[ plantid ][ wOwner ], "Niko", 0, strlen( "Niko" ), 255);
				DrogaStab[ plantid ][wViwo] = 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 ][Plantx] = 0;
			   	DrogaStab[ plantid ][Planty] = 0;
			   	DrogaStab[ plantid ][Plantz] = 0;
			   	DrogaStab[ plantid ][wType] = 0;
				DrogaStab[ plantid ][wPlanted] = 0;
				DrogaStab[ plantid ][wHoursPassed] = 0;
				strmid( DrogaStab[ plantid ][ wOwner ], "Niko", 0, strlen( "Niko" ), 255);
				DrogaStab[ plantid ][wViwo] = 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): //
Founder of
Digression Community


Citat: pjer_gancer poslato Februar 13, 2020, 08:39:19 PRE PODNE
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..
Founder of
Digression Community