複製程式
//這裡應該是模式的編號
/* Game modes for zp_round_started() */
enum
{
MODE_NONE = 0,
MODE_INFECTION,
MODE_NEMESIS,
MODE_ASSASSIN,
MODE_SURVIVOR,
MODE_SNIPER,
MODE_SWARM,
MODE_MULTI,
MODE_PLAGUE,
MODE_LNJ
}
//這個應該是回合開始後用的
/**
* Called when the ZP round starts, i.e. first zombie
* is chosen or a game mode begins.
*
* @param gamemode Mode which has started.
* @param id Affected player's index (if applicable).
*/
forward zp_round_started(gamemode, id)
//這個應該是回合開始前
/**
* Called before the ZP round starts. This is only
* called for custom game modes.
*
* Note: The custom game mode id can be used to start
* the game mode externally
*
* Note: returning ZP_PLUGIN_HANDLED will cause the
* game mode to be blocked and other game modes will
* be given a chance.
*
* @param gameid Custom mode id which is called
*/
forward zp_round_started_pre(gameid)
至於gamemode跟id的用法不大清楚...第1種應該是你要的...他的gamemode可以用在多人感染...然後id應該是指受影響的玩家...應該一個判斷就夠了
大概是這樣吧!?
if(zp_round_started(7, id))
{
......
......
......
}