Započeo Ryan Sanchez
•24. Jun 2011.• Zaključano[Pomoc hitno] COUNT
816
pregleda
5
postova
Hustler
Balkan SA:MP
SA-MP Doprinos
Balkan SA:MP
SA-MP DoprinosNovi Član
90 / 100 XP
Početnik(0)
81
Postovi:
34
Teme:
Pridružio se:Mar. 2011
24. Jun 2011.
// -- Simple CountDown Filterscript --
// -- By Unnamed / Unnamed (2008) --
// -- It has basic protection against duel counts and negative numbers
// -- being used in the /count command....
#include
//Credit to Unnamed and OG_LOG
#define dcmd(%1,%2,%3) if ((strcmp((%3), #%1, true, (%2)) == 0) && ((((%3)[(%2) + 1] == 0) && (dcmd_%1(playerid, "")))||(((%3)[(%2) + 1] == 32) && (dcmd_%1(playerid, (%3)[(%2) + 2]))))) return 1
new Counting;
dcmd_count(playerid, params[])
{
if (!strlen(params)) return SendClientMessage(playerid, 0xafafafff, "Use: /count [how many]");
if (!IsNumeric(params)) return SendClientMessage(playerid, 0xafafafff, "[how many] no more 30");
if (Counting) return SendClientMessage(playerid, 0xafafafff, "Counter is started");
Counting = true;
new ii = strval(params);
do
{
SetTimerEx("CountDown", (strval(params) - ii) * 1000, false, "i", ii);
ii --;
}
while (ii != -1);
SendClientMessage(playerid, 0xffe600ff, "*** Counter is started ***");
return 1;
}
public OnPlayerCommandText(playerid, cmdtext[])
{
dcmd(count, 5, cmdtext);
return 0;
}
forward CountDown(num);
public CountDown(num)
{
new str;
if (num)
{
format(str, sizeof(str), "%i", num);
GameTextForAll(str, 1001, 4);
}
else
{
GameTextForAll("~g~Go Go Go", 3000, 4);
Counting = false;
}
}
IsNumeric(const string[])
{
for (new i = 0, j = strlen(string); i < j; i++)
{
if (string > '9' || string < '0') return 0;
}
return 1;
}
Eh ovako, moze mi neko objasnit kako to da stavim u pawno ?
neznam gdje ovo new da stavim i to molim pomoc.
Hustler
Balkan SA:MP
SA-MP Doprinos
Balkan SA:MP
SA-MP DoprinosNovi Član
90 / 100 XP
Početnik(0)
81
Postovi:
34
Teme:
Pridružio se:Mar. 2011
24. Jun 2011.
Bobby_Zacharias wrote on June 24, 2011, 10:56 pm:
Ma samo otvori pawno idi new i ubaciÅ¡ to i konvertujeÅ¡ i saÄuvaÅ¡ negdje, i to je to. 🙂
pa bote, gdje ubacim #define gdje new?
Enforcer
Balkan SA:MP
SA-MP Doprinos
Balkan SA:MP
SA-MP DoprinosNovi Član
90 / 100 XP
Početnik(0)
223
Postovi:
16
Teme:
Pridružio se:Mar. 2011
24. Jun 2011.
Mr_Break wrote on June 24, 2011, 10:56 pm:
Ma samo otvori pawno idi new i ubaciÅ¡ to i konvertujeÅ¡ i saÄuvaÅ¡ negdje, i to je to. 🙂
pa bote, gdje ubacim #define gdje new?
ReÄeno ti je, ne vrijeÄ‘aj. Odi u programu pawno na new, pa SVE ovo kopiraÅ¡ jer je ovo Filterskripta, i samo konvertujeÅ¡.
Morate biti prijavljeni da biste odgovorili na ovu temu.
Prijava