MakeCode Games!

A fan-made community library of MakeCode Arcade games. Visit MakeCode Arcade to make a game!

← Back to extensions

Arcade Overworld

Create connected Zelda-style room grids and seamless multi-screen adventure worlds with smooth transitions and auto-scrolling.

get overworld map in direction

Problem it solves

You want to check the layout of the adjacent room before unlocking a door to make sure a room actually exists there.

What this block does

Returns the tilemap data of the neighbor room in the specified direction from the current room.

The block

Block ID: overworld_getMapInDirection

get overworld map in direction $direction block

Parameters

NameTypeDefaultMeaning
directionCollisionDirection—The direction of the adjacent room (Top, Right, Bottom, or Left).

Returns

tiles.TileMapData — The adjacent tilemap data, or undefined if outside the grid.

Example

let northMap = overworld.getMapInDirection(CollisionDirection.Top)
if (northMap) {
    game.splash("Path north is open!")
}

Add the extension

Add github:riknoll/arcade-overworld to your project, or open: Import arcade-overworld.