mirror of
https://github.com/Resxt/Plutonium-T6-Scripts.git
synced 2025-04-22 06:35:44 +00:00
Made it possible to have a default randomized map and mode from a user defined list when the human players count is between two values defined by the user Added dvar mapvote_default_rotation_maps Added dvar mapvote_default_rotation_modes (MP only) Added dvar mapvote_default_rotation_min_players Added dvar mapvote_default_rotation_max_players
32 lines
614 B
Plaintext
32 lines
614 B
Plaintext
#include maps\mp\_utility;
|
|
|
|
Init()
|
|
{
|
|
if (GetDvarInt("mapvote_enable"))
|
|
{
|
|
replaceFunc(maps\mp\gametypes\_killcam::finalkillcamwaiter, ::OnKillcamEnd);
|
|
}
|
|
}
|
|
|
|
OnKillcamEnd()
|
|
{
|
|
if (!IsDefined(level.finalkillcam_winner))
|
|
{
|
|
if (isRoundBased() && !wasLastRound())
|
|
return false;
|
|
|
|
wait GetDvarInt("mapvote_display_wait_time");
|
|
[[level.mapvote_rotate_function]]();
|
|
|
|
return false;
|
|
}
|
|
|
|
level waittill("final_killcam_done");
|
|
if (isRoundBased() && !wasLastRound())
|
|
return true;
|
|
|
|
wait GetDvarInt("mapvote_display_wait_time");
|
|
[[level.mapvote_rotate_function]]();
|
|
|
|
return true;
|
|
} |