Minigun Event
#1

i need if the minigun game started it show him that it started and in startmevent if any event is working it say to him that the event is already running

PHP код:
CMD:startmevent(playerid,params[])
{
if(
pInfo[playerid][pLevel] >= 7)
{
new 
string[134];
format(string,sizeof(string),"Admin %s Has Started The Minigun Event Type /joinm To Join The Event",GetName(playerid));
SendClientMessageToAll(yellow,string);
return 
1;
}
else return 
ShowMessage(playerid,red,1);
}
CMD:joinm(playerid,params[])
{
if(
InMinigun[playerid] == 1)
{
SendClientMessage(playerid,0xFF0000FF,"You Already In The Minigun Game");
}
if(
Started[playerid] == 1)
{
SendClientMessage(playerid,0xFF0000FF,"The Event Has Been Started Wait For The New Event");
}
else
{
SendClientMessage(playerid,yellow,"You Have Joined The Minigun Event");
InMinigun[playerid] = 1;
}
return 
1;

Reply
#2

You will need to define something:

Код:
new bool:EvenInProgress;
Код:
CMD:startmevent(playerid,params[])
{
    if(EventInProgress == true) return SendClientMessage(playerid,0xFF0000FF,"The event is already in progress!");
	else if(pInfo[playerid][pLevel] >= 7)
	{
		new string[134];
		format(string,sizeof(string),"Admin %s Has Started The Minigun Event Type /joinm To Join The Event",GetName(playerid));
		SendClientMessageToAll(yellow,string);
		EventInProgress = true;
		return 1;
	}
	else return ShowMessage(playerid,red,1);
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)