What is wrong?
#1

This function is not work, what ir wrong?
Код:
stock GetSlotOfSpawnedVehicle( playerid )
{
	// Funkcija: GetSlotOfSpawnedVehicle( playerid )

	for ( new i = 0; i < MAX_OWNABLE_VEHICLES; i++ )
	    if ( VehInfo[ playerid ][ i ][ vSpawned ] )
	        return i;

	return MAX_OWNABLE_VEHICLES;
}
And is this not working for this command
Код:
else if ( !strcmp( result, "deletev", true ) )
	    {
	        new
	            slot = GetSlotOfSpawnedVehicle( playerid );
	            
			if ( slot < MAX_OWNABLE_VEHICLES )
			{
			    DropVehicleRow( VehInfo[ playerid ][ slot ][ vDBID ] );
			    ShowInfoText  ( playerid, "yuor vehicle is deleted", 4000 );
			    TogglePlayerControllable( playerid, true );
			}
			else
			    SendClientMessage( playerid, COLOR_GREY, "Tuo not spawn vehicle" );
	    }
Reply


Messages In This Thread
What is wrong? - by gedas_lt - 06.07.2010, 14:45
Re: What is wrong? - by gedas_lt - 06.07.2010, 16:07
Re: What is wrong? - by gedas_lt - 07.07.2010, 07:12
Re: What is wrong? - by yoan103 - 07.07.2010, 07:21
Re: What is wrong? - by yoan103 - 07.07.2010, 07:24
Re: What is wrong? - by gedas_lt - 07.07.2010, 07:33
Re: What is wrong? - by yoan103 - 07.07.2010, 07:35
Re: What is wrong? - by gedas_lt - 07.07.2010, 07:37

Forum Jump:


Users browsing this thread: 1 Guest(s)