MakeCode Games!

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

← Back to extensions

Split Screen

Add split-screen multiplayer cameras and picture-in-picture camera view sprites to MakeCode Arcade games.

center camera view

Problem it solves

You want a mini-camera window to look at a stationary point on the map, like a locked treasure chest or dungeon exit.

What this block does

Centers the viewport of a camera view sprite at fixed (x, y) coordinates in the world.

The block

Block ID: splitscreen_centerCameraViewAt

center camera view $cameraView at x $x y $y block

Parameters

NameTypeDefaultMeaning
cameraViewSpritemyCameraViewThe camera view sprite to position
xnumber0The horizontal pixel position in the game world
ynumber0The vertical pixel position in the game world

Example

let miniCam = splitScreen.createCameraView(40, 30)
splitScreen.centerCameraViewAt(miniCam, 100, 100)

Add the extension

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