This is the view of the map, it extends the map which is the raw model and allows to draw it
Resets the tiles content
Draws the faction overlays (e.g. if the opponent is of the red faction, draw a red overlay over his area)
Draws the outer space, that is everything which is outside of the tiles. This is visible when zooming out very far on a big screen
Draws all static entities like buildings etc.
Returns all buildings within the transport range which have the given component
Returns the canvas which can be used to visualize the transporter radius as tiles, e.g. when placing a new transporter.
the tile radius to get the canvas for
Returns the canvas containing the empty background. If a chunk is empty, the empty background is used so we avoid drawing empty chunks all the time.
Returns the dpi of the empty chunk background (we need this for rendering)
Returns the tile content of a given tile
Entity or null
Checks a given tile for validty
Returns the pattern for a given faction
Internal method to get the stripes canvas from the atlas
Initializes all canvases used for background rendering
Checks if the tile is used
Checks if a given tile is within the map bounds
Checks if a given tile is within the map bounds, including borders
Redraws the background into a chunk
Generates the cached canvas patterns which are used to draw the chunk backgrounds. Must be called after the theme changed (is called on the theme changed hook)
Removes the entity from the map
Sets the tiles content