Eto ti a sad cu ti nac nesto za event
if(strcmp(cmd, "/b", true) == 0)
{
if(IsPlayerConnected(playerid))
{
if(gPlayerLogged == 0)
{
SendClientMessage(playerid, COLOR_GREY, "** You havent logged in yet !");
return 1;
}
if(PlayerInfo == 1)
{
SendClientMessage(playerid, TEAM_CYAN_COLOR, "You cannot speak, you have been silenced");
return 1;
}
new y,m,d;
new h,mi,s;
getdate(y,m,d);
gettime(h,mi,s);
new length = strlen(cmdtext);
while ((idx < length) && (cmdtext <= ' '))
{
idx++;
}
new offset = idx;
new result;
while ((idx < length) && ((idx - offset) < (sizeof(result) - 1)))
{
result[idx - offset] = cmdtext;
idx++;
}
result[idx - offset] = EOS;
if(!strlen(result))
{
SendClientMessage(playerid, COLOR_GRAD2, "USAGE: /b [local ooc chat]");
return 1;
}
new brojevi[] = { '1','2','3','4','5','6','7','8','9'};
for(new b = 0; b < sizeof brojevi; b++)
{
new tekst = strlen(result);
for(new i = 0; i {
if(result == brojevi)
result = '*' ;
}
}
if(PlayerInfo == 1)
{
format(string, sizeof(string), "(( Admin : %s ))", result);
SetPlayerChatBubble(playerid, string, COLOR_NICERED, 20.0, 8000);
ProxDetector(20.0, playerid, string,COLOR_FADE1,COLOR_FADE2,COLOR_FADE3,COLOR_FADE4,COLOR_FADE5);
format(string, sizeof(string), "(%d/%d/%d)[%d:%d:%d] %s (Local OOC -Admin-): %s",d,m,y,h,mi,s, sendername, result);
ChatLog(string);
}
if(PlayerInfo == 0 && PlayerInfo == 1)
{
format(string, sizeof(string), "(( Stranac : %s ))", result);
SetPlayerChatBubble(playerid, string, COLOR_WHITE, 20.0, 8000);
ProxDetector(20.0, playerid, string,COLOR_FADE1,COLOR_FADE2,COLOR_FADE3,COLOR_FADE4,COLOR_FADE5);
format(string, sizeof(string), "(%d/%d/%d)[%d:%d:%d] %s (Local OOC -Masked-): %s",d,m,y,h,mi,s, sendername, result);
ChatLog(string);
}
if(PlayerInfo == 0 && PlayerInfo == 0)
{
format(string, sizeof(string), "(( %s : %s ))", sendername, result);
SetPlayerChatBubble(playerid, string, COLOR_WHITE, 20.0, 8000);
ProxDetector(20.0, playerid, string,COLOR_FADE1,COLOR_FADE2,COLOR_FADE3,COLOR_FADE4,COLOR_FADE5);
format(string, sizeof(string), "(%d/%d/%d)[%d:%d:%d] %s (Local OOC): %s",d,m,y,h,mi,s, sendername, result);
ChatLog(string);
}
}
return 1;
}
if(strcmp(cmd, "/evozila", true) == 0)
{
if (PlayerInfo >= 1 || PlayerInfo >= 1)
{
ShowPlayerDialog(playerid,59,DIALOG_STYLE_LIST,"Tourww Event","Stvori Aute\nUnisti Aute","Odaberi", "Zatvori");
}
else
{
SendClientMessage(playerid,COLOR_GRAD1,": Samo admin lvl 1 moze koristiti ovu komandu!");
}
return 1;
}
i pod ondialogresponse
if(dialogid == 59)
{
switch(listitem)
{
case 0:
{
Event1 = CreateVehicle(411,2854.8875,-1917.1416,10.6641,0.6626,1,1,60000); // tww car 1
SendClientMessage(playerid,COLOR_YELLOW,": Vozila za utrku su uspjesno stvorena.");
}
case 1:
{
DestroyVehicle(Event1);
SendClientMessage(playerid,COLOR_YELLOW,": Vozila za event su unistena.");
}
}
}
i naravno logicki gore u skripti stavit new Event1;
to je npr za jedan event..i onda dodajes dalje vozila event2 itd..