DrawDefMap

Category: Landscape
Since engine version: 1.0 OC

Description

Draws a dynamic map within the specified rectangle over the old landscape using a given map specification from Landscape.txt.

Syntax

bool DrawDefMap(int x, int y, int width, int height, string map_name);

Parameters

x:
Left border of the rectangle in which to draw the map.
y:
Top border of the rectangle in which to draw the map.
width:
Width of the rectangle in which to draw the map.
height:
Height of the rectangle in which to draw the map.
map_name:
Name of the map to be used from Landscape.txt.

Remark

The Landscape.txt component is usually removed from memory after scenario initialization. To keep it in memory for later use by this command you should specify the option KeepMapCreator=1 in Scenario.txt section [Landscape].

Example

DrawDefMap(0,0,LandscapeWidth(), LandscapeHeight(), "TheMap");
Draws 'TheMap' over the complete landscape. 'TheMap' must be defined in Landscape.txt.
See also: DrawMap
Sven2, 2002-04