Lexy's Labyrinth, a web-based CC1 + CC2 emulator
#1
   

https://c.eev.ee/lexys-labyrinth/ — source and changelog on GitHub

Hello!  I wrote a thing to play Chip's Challenge in a web browser, due to reasons. I think it's pretty cool and I hope you do too.

Current features as of May '21:
  • Extremely good compatibility with both Chip's Challenge 1 and 2; defaults to a tweaked Steam ruleset that fixes some bugs, but can also play under Steam rules (~99% compatible), Lynx rules (~95% compatible), or MS rules (lol)
  • Brand new (and unencumbered) artwork, sound effects, and music
  • Phone and touchscreen support, with a dedicated compact layout
  • Undo or rewind when you fat-finger a block into a corner, ten minutes into a horrible sokoban level
  • "Step mode", where the world doesn't move until you do
  • Separate recording of your best clock, best real time, best score, and whether you beat the level without undo
  • One click to play any CCLP — but you can also load a CCL/DAT, individual C2M, or C2G zip/folder
  • Built-in level editor that can create just about anything, plus lets you share individual levels via URL
  • Support for custom tilesets, in either the compact TW layout or the CC2 layout
  • Experimental support for some new tiles and other features, inspired by CC3D and a couple ill-fated fan spinoffs
  • Small notices when you're playing a level that uses CC1 boots mode or "hide logic", so there are no surprises
  • Tons of other nice little touches

Note that a small handful of CCLP (and canonical) levels don't work under the default rules, generally because of rule changes between Lynx/Steam (though one CC2LP1 level does rely on hook behavior that I deemed to be a bug).

Enjoy!
Reply
#2
1.1 is now live, not like version numbers mean anything.  Biggest change is that it can now load C2Gs, so you can now drag and drop the Steam releases' game files right in there and play them.

Gameplay fixes:
  • Brown buttons held down when the level starts now work correctly
  • Multiple brown buttons wired to the same trap work correctly
  • If CCL custom connections are present, red and brown buttons ONLY use those, rather than falling back to auto-connection rules (i.e., unconnected buttons in CCL levels stay unconnected)
  • Blue button behavior now matches Lynx/Steam behavior, queuing the reversal on each tank until it's next able to move, EXCEPT that in CCLs, tanks ignore button presses while sliding
  • Blue tanks always try to move in their current direction, even when blocked or in a trap
  • CCLs convert blue walls to recessed walls if an actor starts on top of them, preserving the intended behavior under CC2 rules
  • CCLs convert recessed walls to a new "doubly recessed wall" tile if an actor starts on top of them, preserving the intended behavior under CC2 rules
  • Monsters now eat blue keys
  • Actors now act in reverse order, matching Lynx/Steam behavior and fixing several unsolveable CCLP levels
  • CC2 gray buttons are partially implemented
  • CC2 wiring is partially implemented

Other changes:
  • Green keys/locks are somewhat more colorblind-friendly
  • Two new music tracks
  • SFX volume is kinder when there are a lot of off-screen button presses
  • If you tie a previous score that used undo, but the new score didn't use undo, the new score takes priority (so you get the star)
  • Errors that fail to load show the error and apologize profusely, rather than silently doing nothing
  • A new LL-exclusive level feature: camera regions, which restrict the camera to a given rectangle while the player is within it; essentially just made for magical so their tiny computer-generated sokobans play better
Reply
#3
I am arbitrarily calling the current state of things 1.2 because a lot has happened.  A lot of the new stuff is still buggy, but it's usable and rapidly getting there!

I've also started writing documentation on the project wiki; most helpful at the moment is the list of known broken levels.

Interface:
  • New: Added "turn-based mode" (contributed by Patashu), in which the game remains paused while you're not moving (hold spacebar to advance manually)
  • New: Added three more music tracks
  • New: Added a debug panel (middle-click on the logo in the lower left), which allows you to control time, mess with your inventory, alter the viewport size, watch a C2M's replay, teleport freely, etc.
  • New: CC2 levels now respect the viewport size option, i.e. most of them will use a 10×10 viewport
  • New: Players have a new victory pose when they reach the exit
  • New: Blobs and walkers have distinct animations in all four directions
  • New: Actors that die in slime use a custom slime splash
  • Improved: Expanded undo buffer to 30 seconds and reduced its memory usage considerably
  • Improved: Redesigned keys and doors to be more colorblind-friendly (and better-themed overall)
  • Improved: Buttons are more compact, which is especially helpful on mobile
  • Improved: Auto-scaling behavior now works better on small portrait screens, improving the chances that the game will fill the screen
  • Improved: Touch detection is now relative to the center of the viewport, not the entire play area
  • Fixed: Rewind button is now a toggle; previously it could get you stuck permanently
CC2 support:
  • New: Finished CC2 tileset
  • New: Added the drop/cycle/swap actions
  • New: All tiles now load, so any C2M should be playable (if not necessarily solveable)
  • New: Implemented "no" signs, orange buttons, frame (directional) blocks, light switches, railroad tracks, timid teeth, the bribe, the lightning bolt, and the foil
  • New: Added support for the common form of item bestowal, where an actor starts on an item and a force floor facing a wall
  • New: Mostly implemented logic gates, rovers, and green/red/yellow teleporters
  • New: Partially implemented flame jets, doppelgangers, and wired blue teleporter behavior
  • New: Force floors are now toggled by a gray button or a pulse
  • New: Swivel doors are now rotated by a gray button or a pulse
  • Improved: Switched to using the CC2 PRNG, so the behavior of blobs/walkers/green teleporters/RFFs should now be replay-compatible
  • Improved: Slime now destroys actors as appropriate
  • Improved: Gliders don't sink lilypads/turtles
  • Improved: Canopies now render
  • Improved: Teeth now run away from Cerise/Melinda
  • Improved: Collision rules are much closer to correct; notably, ghosts generally pass through the right things and CC2 blocks can go in the right places
Other gameplay changes:
  • New: When the player starts on a hint tile, the hint is shown immediately
  • New: Actors that start on force floors immediately start sliding
  • New: Sliding blocks can now be pushed
  • New: Invisible walls reveal themselves briefly when bumped, as in CC2
  • Improved: Thief sound only plays if you lost either items or points
  • Fixed: Standing in an open trap and pushing a block off of the brown button holding it open no longer softlocks you
  • Fixed: Stepping onto a cell containing both flippers and water no longer drowns you
  • Fixed: The main loop no longer has a "finish movement" pass at the beginning, which fixes some obscure timing issues (albeit introduces others)
  • Fixed: Monsters attempt to move in their least preferred direction even if they're blocked in every direction
Editor:
  • New: Levels can be saved to browser storage
  • New: Editor has its own level browser that shows maps of every level in a pack
  • New: Tools show basic usage hints on hover
  • New: Right-click with the pencil to erase
  • New: Ctrl-click with the pencil to pick up a tile
  • New: Adjust tool can toggle many more tiles
  • New: Right-click with the adjust tool to rotate counter-clockwise
  • New: Ctrl-click with the adjust tool to edit properties of specific tiles; currently works on letter tiles, hints, railroad tracks, and frame blocks
  • New: Current tile appears in the upper left; press ,/. to rotate it, or click it to edit it (like ctrl-click with the adjust tool)
  • New: Railroad track tool (right-drag to erase)
  • New: Wire tool (right-drag to erase)
  • New: Edit the title, author, size, and time limit of a level
  • Improved: Pencil behavior is consistent across layers; it will always replace only tiles on the same layer, but hold Shift to replace everything
  • Improved: Almost all CC2 tiles are available in the palette; only canopy and thin walls are missing, for technical reasons
  • Improved: C2M saving now supports hints and most level metadata
  • Improved: Level is now centered and padded
  • Fixed: C2M compression occasionally lost the last byte, resulting in a corrupted level
  • Fixed: Large levels are no longer cut off
  • Fixed: All tiles now always have a direction
  • Fixed: Drawing is more robust and will no longer freak out in edge cases or when drawing outside of the level
Extensions:
  • New: Added a custom tile, gift bow, which goes on the same layer as the "no" sign and causes an item to be able to be picked up by any actor
  • New: Added a custom tile, circuit block, which contains wires
Reply
#4
Very great project! Thanks for your effort!
Reply
#5
Whoops, I haven't updated this thread in half a year. At this point a changelog is meaningless so here is where things stand with what I'm arbitrarily calling 2.0:
  • Everything is better in every way
  • Everything is implemented and the game basically works; remaining divergences from CC2 are incredibly obscure and unlikely to make levels unbeatable
  • The default ("Lexy") rules are more similar to Steam rules now, but still fix some buggy behavior like getting stuck out of sync on force floors or getting caught on monsters when carrying a hook
  • 99% compatible with Steam rules (syncs all CC1 replays, all CC2 replays, all but six CC2LP1 replays, and the vast majority of CC2LP1-Voting)
  • 93% compatible with Lynx rules (syncs, well, 93% of the Lynx TWS; a lot of the remaining issues are quirks with teleporting that are hard to fix under the CC2 model)
  • Incredibly not compatible with MS rules but you can make monsters run into fire if that's nostalgic
  • Mobile interface is vastly improved and much more likely to fill your screen rather than shrink the game to the size of a postage stamp
  • There is an ending screen rather than simply crashing
  • Best clock, best real time, and best score are tracked separately
  • Includes a (not quite complete) set of custom levels, Lexy's Lessons, that act as a whirlwind tour of the entire game for new players
  • Has some extra (non-blocking) visual effects, like a smoke puff when changing or opening some kinds of terrain, teleporter + transmogrifier flash, and a non-blocking explosion for bowling balls that are dropped against walls
  • Has a budding CLI for running a bunch of replays automatically
  • Editor has undo, selection tool, rotate/flip selection or entire level, floodfill tool, visible monster directions
  • Editor can rearrange, clone, or delete levels in a pack
  • Editor can export to a zip of C2G + C2Ms
  • Editor can export to CCL/DAT (if possible) and has like 20% support for editing manual button connections
  • More experimental tiles, including a skeleton key, colored sokoban blocks (similar to CC3D), a glass block which allows for moving and cloning items, one-way thin walls, door-like gates that can sit atop any terrain
Reply
#6
Great work! It gives me so much joy!
Reply
#7
pretty good and but how do you change the ending image tho???
Reply
#8
I don't think that's possible without self-hosting.
CC is awesome!

CC2 sets (still being updated): C1059-CC2 --- Walls of CC2

CC1 sets (all complete): C1059-2 --- C1059-1 --- 1059PG01 --- C1059-Christmas --- C1059-INSANITY --- C1059-CCLP4

My Youtube channel --- Fiver's Honeycomb --- Fanfiction.net

Good posts don't cost too much, yet many go unwritten.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)