GhostLine
ABOUT THIS PROJECT
A puzzle platformer where dying is a mechanic, not a reset.
You move between two forms (alive and ghost) and each one has its own physics profile, so the level you can solve depends on the body you are in. Transformations are energy-limited, which turns the whole game into a budgeting problem: You can always reach the exit, but not always the way you first tried.
A dual-state player
Pressing C flips isGhost and calls Physics2D.IgnoreCollision between the player's collider and every wall collider, so ghost form passes through walls without a second physics layer or a second body. The tint is set in the same branch as the toggle, so the visual and the collider can never disagree. Ghost form cannot jump, because grounding comes from collisions with Safe and Wall and a ghost has none. Every switch into ghost spends one of the level's form changes, and going below zero is a death, which turns each puzzle into a budget rather than a maze.
Levers and gated doors
A lever is a trigger zone that accepts E only while the player is inside it and alive, so a ghost can pass a lever but never pull it. Flipping it mirrors the sprite and reports to the level's LogicScript, which counts levers attained against a leversNeeded number and swaps the closed door for the open one only at equality. A level's requirement is therefore one integer on the logic object, and a designer raises it to force more of the level to be visited in the right form.
Levels fit the camera
Ground and wall tilemaps built from a spliced sheet. Rather than hand-placing a camera per level, CameraFitTileMap reads the tilemap's bounds and sets the orthographic size to the larger of half the height and half the width divided by the aspect ratio, plus padding, so every level fills the screen on any monitor and never shows past its edge. The animated background is a prefab shared by every level, so a change to it propagates everywhere at once.
Art and shipping it
Drew the 16x16 player sprite and its idle, walk and death animations, added a title screen with its own animation and an end screen with fades between levels, and produced both Windows and Mac builds. Jumps are variable height: releasing the key while still rising divides the upward velocity by a multiplier. Early levels carry written directions because playtesters did not discover the form-change mechanic on their own.