MakeCode Games!

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

← Back to extensions

Raycasting 3D Render

Transforms your 2D tilemaps and sprites into a first-person 3D/2.5D raycasted world with jumping, heights, camera controls, and multi-directional animations.

current is

Problem it solves

You need your user interface or HUD elements to display only when the game is in 2D tilemap view or only in 3D view.

What this block does

Returns true if the raycasting engine is currently set to the specified view mode (tilemapView or raycastingView).

The block

Block ID: rcRender_isViewMode

current is $viewMode block

Parameters

NameTypeDefaultMeaning
viewModeViewModeThe view mode to check against (ViewMode.tilemapView or ViewMode.raycastingView).

Returns

boolean — true if current view matches the specified mode, false otherwise.

Example

if (Render.isViewMode(ViewMode.raycastingView)) {
    console.log("In 3D view")
}

Add the extension

Add github:The-Code-Zone/Raycasting-pxt-extension to your project, or open: Import Raycasting-pxt-extension.