Skip to content

Instantly share code, notes, and snippets.

@ClementSparrow
Created August 13, 2019 21:37
Show Gist options
  • Save ClementSparrow/e828753140c2b5829288dba6e3223e4f to your computer and use it in GitHub Desktop.
Save ClementSparrow/e828753140c2b5829288dba6e3223e4f to your computer and use it in GitHub Desktop.
Colorman (PuzzleScript Script)
Play this game by pasting the script in http://www.puzzlescript.net/editor.html
title Colorman
author Clement Sparrow
key_repeat_interval 0.15
========
OBJECTS
========
OPlayer
Orange YELLOW BLACK
.222.
.000.
22122
.222.
.2.2.
nochange
red
....0
...0.
..0..
.0...
0....
bgoal
lightblue
.....
.0.0.
..0..
.0.0.
.....
ogoal
yellow
.....
.0.0.
..0..
.0.0.
.....
goal
gray
.....
.0.0.
..0..
.0.0.
.....
BPlayer
blue Purple BLACK
.222.
.000.
22122
.222.
.2.2.
Owall
BROWN orange
00000
11010
00000
01011
00000
Wall
Black gray
00000
11010
00000
01011
00000
Bwall
purple Blue
00000
11010
00000
01011
00000
Obox
lightbrown
0.0.0
.....
0...0
.....
0.0.0
Bbox
blue
.0.0.
0...0
.....
0...0
.0.0.
Box
darkgray
00000
0...0
0...0
0...0
00000
background
white
outside
black
=======
LEGEND
=======
0 = background
1 = nochange
_ = outside
E = bgoal and background
F = ogoal and background
G = goal and background
N = bgoal and nochange
O = ogoal and nochange
P = goal and nochange
2 = Wall
3 = Bwall and background
4 = Owall and background
Q = Bwall and background and ogoal
R = Owall and background and bgoal
5 = Bbox and background
6 = Obox and background
7 = Box and background
8 = Bbox and Obox
9 = Bbox and nochange
C = Obox and nochange
D = Box and nochange
S = BBox and OBox and nochange
T = Bbox and bgoal
U = Obox and ogoal
W = Bbox and Ogoal
X = Obox and Bgoal
Y = Box and goal
H = OPlayer and background
I = OPlayer and nochange and background
J = oplayer and bwall and background
K = oplayer and bbox and background
L = BPlayer and Owall and background
M = BPlayer and obox and background
Player = OPlayer or BPlayer
Oblocking = Owall or Wall
Bblocking = Bwall or Wall
blocking = wall or bwall or owall
boxes = box or Bbox or Obox
goals = bgoal or ogoal or goal
bboxes = bbox or box
oboxes = obox or box
=======
SOUNDS
=======
================
COLLISIONLAYERS
================
background
nochange, outside
goals
Wall,Owall,Bwall
bbox
obox
box
Player
======
RULES
======
(action)
[Action BPlayer no OWall no boxes no nochange] -> [OPlayer]
[Action OPlayer no BWall no boxes no nochange] -> [BPlayer]
(boxes)
[> BPlayer | Bbox] -> [> BPlayer | > Bbox]
[> OPlayer | Obox] -> [> OPlayer | > Obox]
[> Player | box] -> [> Player | > box]
(boxes pushing other boxes)
startloop
[> Bbox | Bbox] -> [> Bbox | > Bbox]
[> Obox | Obox] -> [> Obox | > Obox]
[> boxes | box] -> [> boxes | > box]
[> box | boxes] -> [> box | > boxes]
endloop
(boxes blocked by walls or boxes)
[> bbox | Bblocking] -> cancel
[> Obox | Oblocking] -> cancel
[> box | blocking] -> cancel
(moves, blocked by walls)
[> BPlayer | Bblocking ] -> CANCEL
[> OPlayer | Oblocking ] -> CANCEL
==============
WINCONDITIONS
==============
all goal on box
all bgoal on bbox
all ogoal on obox
=======
LEVELS
=======
message 1 way or another
222222222
2e05h60f2
222202222
2f05060e2
222222222
message Only 2 ways about it
__22222__
__20h02__
222020222
2ee586ff2
222202222
_2000002_
220222022
2e05760f2
222222222
message <3 is the solution
2222222
2002002
20e7f02
206g502
2200022
_22h22_
__222__
message Crosstown Traffic
______22222
______2g002
______2g202
2222222g202
2e007675702
20202020222
2h00000f2__
222222222__
message Clopen set: Open set whose complement is also open.
22222_
206f2_
22e22_
_25222
_2f6h2
_22222
message Crosstown Traffic (redux)
______22222
______2f002
______2f202
22222220202
2ee06575602
20202020222
2h00000g2__
222222222__
message Open-closed principle: Stay close, create openings.
22222222222222222222
20h00200000020000002
22ut02022ux02022wt02
20xw22020tw22020xu22
20000002000000200002
22222222222222222222
message Open-closed principle (the real one): Closed for modification, but open to extension (1/3)
222222
20h002
22wt02
22tu22
20ux22
200002
222222
message Open-closed principle (the real one): Closed for modification, but open to extension (2/3)
222222
20h002
22wt02
24xw32
20ux22
200002
222222
message Open-closed principle (the real one): Closed for modification, but open to extension (3/3)
222222
20h002
22ux02
22xw22
20wt22
200002
222222
message Congratulations. Seriously. I could not solve this last one myself.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment