#include <amxmodx>
#include <reapi>
public plugin_init()
{
register_plugin("30_rounds", "0.1", "maFFyoZZyk");
RegisterHookChain(RG_CSGameRules_RestartRound, "RoundStart_Pre", true);
}
public RoundEnd_Post(WinStatus:status, ScenarioEventEndRound:event, Float:tmDelay)
{
iRounds = get_member_game(m_iNumTerroristWins) + get_member_game(m_iNumCTWins);
if(iRounds == 30)
{
new szMap[32];
get_mapname(szMap, charsmax(szMap));
server_cmd("changelevel %s", szMap);
}
}
#include <amxmodx>
#include <reapi>
#define RESTART_AFTER_ROUNDS 30
public plugin_init() {
register_plugin("Auto Restart Map", "1.0.0", "ArKaNeMaN");
RegisterHookChain(RG_CSGameRules_RestartRound, "@OnRestartRound", true);
}
@OnRestartRound() {
if (get_member_game(m_iTotalRoundsPlayed) >= RESTART_AFTER_ROUNDS) {
server_cmd("restart");
}
}