setup() {
        if (lightMode) return;
        this.canvas = document.getElementById('miniMapArea');
        this.pageHeight = height; // Math.round(((parseInt($("#simulationArea").height())))/ratio)*ratio-50; // -50 for tool bar? Check again
        this.pageWidth = width; // Math.round(((parseInt($("#simulationArea").width())))/ratio)*ratio;
        this.pageY = (this.pageHeight - globalScope.oy);
        this.pageX = (this.pageWidth - globalScope.ox);

        if (simulationArea.minHeight != undefined) { this.minY = Math.min(simulationArea.minHeight, (-globalScope.oy) / globalScope.scale); } else { this.minY = (-globalScope.oy) / globalScope.scale; }
        if (simulationArea.maxHeight != undefined) { this.maxY = Math.max(simulationArea.maxHeight, this.pageY / globalScope.scale); } else { this.maxY = this.pageY / globalScope.scale; }
        if (simulationArea.minWidth != undefined) { this.minX = Math.min(simulationArea.minWidth, (-globalScope.ox) / globalScope.scale); } else { this.minX = (-globalScope.ox) / globalScope.scale; }
        if (simulationArea.maxWidth != undefined) { this.maxX = Math.max(simulationArea.maxWidth, (this.pageX) / globalScope.scale); } else { this.maxX = (this.pageX) / globalScope.scale; }

        var h = this.maxY - this.minY;
        var w = this.maxX - this.minX;

        var ratio = Math.min(250 / h, 250 / w);
        if (h > w) {
            this.canvas.height = 250.0;
            this.canvas.width = (250.0 * w) / h;
        } else {
            this.canvas.width = 250.0;
            this.canvas.height = (250.0 * h) / w;
        }

        this.canvas.height += 5;
        this.canvas.width += 5;

        document.getElementById('miniMap').style.height = this.canvas.height;
        document.getElementById('miniMap').style.width = this.canvas.width;
        this.ctx = this.canvas.getContext('2d');
        this.play(ratio);
    }
@type {Object} miniMapArea
This object is used to draw the miniMap.
@property {number} pageY
@property {number} pageX
@property {HTMLCanvasObject} canvas - the canvas object
@property {function} setup - used to setup the parameters and dimensions
@property {function} play - used to draw outline of minimap and call resolve
@property {function} resolve - used to resolve all objects and draw them on minimap
@property {function} clear - used to clear minimap
@category minimap