[Pedido] Pedir, Apenas uma modificaзгo.(quem quiser tapete de prego)
#1

Aew, galera o maior desafio , foi achar o tapete de prego que funcione, eu jб consegui.
Caso alguйm queira sу pegar..
Preciso que alguйm modifique o o comando de tapete de prego para apenas policias, pois qualquer um pode colocar..
alguйm pode me ajudar.

Code:
#include <a_samp>
#include <SpikeStrip>

strtok(const string[], &index)
{
	new length = strlen(string);
	while ((index < length) && (string[index] <= ' '))
	{
		index++;
	}

	new offset = index;
	new result[20];
	while ((index < length) && (string[index] > ' ') && ((index - offset) < (sizeof(result) - 1)))
	{
		result[index - offset] = string[index];
		index++;
	}
	result[index - offset] = EOS;
	return result;
}

public OnPlayerCommandText(playerid, cmdtext[])
{
	new cmd[256];
	new idx;
	cmd = strtok(cmdtext, idx);

	if (strcmp(cmd,"/ctapete",true) == 0)
	{
	    new Float:plocx,Float:plocy,Float:plocz,Float:ploca;
        GetPlayerPos(playerid, plocx, plocy, plocz);
        GetPlayerFacingAngle(playerid,ploca);
        CreateStrip(plocx,plocy,plocz,ploca);
	    return 1;
	}
	else if (strcmp(cmd,"/rtapete",true) == 0)
	{
        DeleteClosestStrip(playerid);
	    return 1;
	}
	else if (strcmp(cmd,"/removerall",true) == 0)
	{
        DeleteAllStrip();
	    return 1;
	}
	
	return 0;
}
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)