import { GlobalData } from ".."; export default function bigmap() { var bigmap = { enabled: false, timer: null }; mp.game.ui.setRadarZoom(0.0); mp.game.ui.setRadarBigmapEnabled(false, false); mp.events.add("render", () => { mp.game.controls.disableControlAction(0, 48, true); if (mp.game.controls.isDisabledControlJustPressed(0, 48) && !GlobalData.InChat) { if (bigmap.timer != null) { clearTimeout(bigmap.timer); bigmap.timer = null; } if (!bigmap.enabled) { mp.game.ui.setRadarBigmapEnabled(true, false); mp.game.ui.setRadarZoom(1.0); bigmap.enabled = true; bigmap.timer = setTimeout(() => { mp.game.ui.setRadarBigmapEnabled(false, false); mp.game.ui.setRadarZoom(0.0); bigmap.enabled = false; bigmap.timer = null; }, 7500); } else { mp.game.ui.setRadarBigmapEnabled(false, false); mp.game.ui.setRadarZoom(0.0); bigmap.enabled = false; } } }); }