CSB Map Chooser runs an end-of-map vote. A short time before the time limit runs out it opens a menu with a handful of random maps taken from the map cycle - excluding the current map and the last few that were played, which are tracked in a file - counts the votes with a HUD countdown and sets amx_nextmap to the winner. Players can instead vote to extend the current map, up to a capped number of extensions.
A clean-room GPL re-implementation inspired by the original AMX Mod X MapChooser.
mapcyclefile, validated with is_map_validsay /nextmap to check the decisioncsb_mapchooser.amxx in addons/amxmodx/plugins/plugins.inimp_timelimit is greater than 0