StartRound/EndRound
#1

hi all.

im making a TDM

i have a question and a problem.

Question:
How can i make if a team have 50 kills the round ends and server restarts??
and if they have 23/50 kills and the time limit is reached the server restarts??

Problem:
What is wrong with this code
Код:
public LoadMap()
{
	ShowPlayerDialog(playerid, TDM, DIALOG_STYLE_LIST, "Choose a Team?", "Defenders \nAttackers \nSpectate", "Select", "Cancel");
	return 1;
}
I get this error:
Код:
C:\Documents and Settings\Luc\Bureaublad\Pawno\gamemodes\test.pwn(813) : error 017: undefined symbol "playerid"
can someone help me?

TY ALOT

-Luckie12
Reply
#2

Код:
public LoadMap(playerid)
Reply
#3

Use This

Код:
public LoadMap(playerid)
{
	ShowPlayerDialog(playerid, TDM, DIALOG_STYLE_LIST, "Choose a Team?", "Defenders \nAttackers \nSpectate", "Select", "Cancel");
	return 1;
}
Reply
#4

Код:
forward LoadMap(playerid);
public LoadMap(playerid)
{
  ShowPlayerDialog(playerid, TDM, DIALOG_STYLE_LIST, "Choose a Team?", "Defenders \nAttackers \nSpectate", "Select", "Cancel");
  return 1;
}
And if your using a timer, change it to this:
Код:
SetTimerEx("LoadMap", time, repeating, "i", playerid);
Reply
#5

EDIT:what i have to change with SetTimerEx?
Reply
#6

Some one?

[sorry for bump]
Reply
#7

How does loadmap get called?
Reply
#8

forward LoadMap(playerid);

?

public LoadMap(playerid)

?
Reply
#9

i got it :P!

but 1 other little problem

if i go in my server i have to wait 10 sec for the dialog to show up (THAT IS GOOD)
but i click on Defenders or Attackers Or Spectator i click Select
and After 10 sec it shows up again :S
like a loop
parts:

Код:
forward LoadMap(playerid);
Код:
public OnPlayerSpawn(playerid)
{
	SetPlayerPos(playerid, -227.027999,1401.229980,27.765625);
 	SetTimerEx("LoadMap", 10000, true, "i");
	GameTextForPlayer(playerid, "~r~Please Wait ~w~10 ~B~Seconds Until The ~r~Next ~B~Map Loaded...", 5000, 1);
	return 1;
}
Код:
public LoadMap(playerid)
{
	ShowPlayerDialog(playerid, TDM, DIALOG_STYLE_LIST, "Choose a Team?", "Defenders \nAttackers \nSpectate", "Select", "Cancel");
	return 1;
}
Reply
#10

Код:
public OnPlayerSpawn(playerid)
{
  SetPlayerPos(playerid, -227.027999,1401.229980,27.765625);
  SetTimerEx("LoadMap", 10000, false, "i", playerid);
  GameTextForPlayer(playerid, "~r~Please Wait ~w~10 ~B~Seconds Until The ~r~Next ~B~Map Loaded...", 5000, 1);
  return 1;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)