Last active
August 7, 2019 13:54
-
-
Save Draknek/a9fbd46735cd965b080497d961e12978 to your computer and use it in GitHub Desktop.
Splitting Headache (PuzzleScript Script)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
title Splitting Headache | |
author Alan Hazelden | |
homepage www.draknek.org | |
realtime_interval 0.07 | |
run_rules_on_level_start | |
noaction | |
======== | |
OBJECTS | |
======== | |
Background | |
DARKBLUE BLACK | |
11111 | |
01111 | |
11101 | |
11111 | |
10111 | |
Wall | |
DarkGrey | |
Player | |
#a46422 #495e2b #493c2b #000000 | |
..0.. | |
.111. | |
01110 | |
02220 | |
.2.2. | |
Slime | |
#44891a #50a01e #306c0c #36770e | |
01001 | |
00100 | |
00000 | |
22222 | |
32232 | |
SlimeAnim1_1 | |
#44891a #50a01e #306c0c #36770e | |
..... | |
..... | |
..... | |
..... | |
..... | |
SlimeAnim1_2 | |
#44891a #50a01e #306c0c #36770e | |
....0 | |
....1 | |
..... | |
..... | |
..... | |
SlimeAnim1_3 | |
#44891a #50a01e #306c0c #36770e | |
...10 | |
..... | |
..... | |
..... | |
..... | |
SlimeAnim2_1 | |
#44891a #50a01e #306c0c #36770e | |
..... | |
..... | |
..... | |
..... | |
..... | |
SlimeAnim2_2 | |
#44891a #50a01e #306c0c #36770e | |
10... | |
..... | |
..... | |
..... | |
..... | |
SlimeAnim2_3 | |
#44891a #50a01e #306c0c #36770e | |
.0... | |
1.... | |
..... | |
..... | |
..... | |
SlimeAnim3_1 | |
#44891a #50a01e #306c0c #36770e | |
..... | |
..... | |
..... | |
..... | |
..... | |
SlimeAnim3_2 | |
#44891a #50a01e #306c0c #36770e | |
..... | |
..0.. | |
..1.. | |
..... | |
..... | |
SlimeAnim3_3 | |
#44891a #50a01e #306c0c #36770e | |
..... | |
..0.. | |
.1... | |
..... | |
..... | |
SlimeAnim4_1 | |
#44891a #50a01e #306c0c #36770e | |
..... | |
..... | |
..... | |
..... | |
..... | |
SlimeAnim4_2 | |
#44891a #50a01e #306c0c #36770e | |
..... | |
..... | |
..... | |
..... | |
23... | |
SlimeAnim4_3 | |
#44891a #50a01e #306c0c #36770e | |
..... | |
..... | |
..... | |
.3... | |
2.... | |
SlimeAnim5_1 | |
#44891a #50a01e #306c0c #36770e | |
..... | |
..... | |
..... | |
..... | |
..... | |
SlimeAnim5_2 | |
#44891a #50a01e #306c0c #36770e | |
..... | |
..... | |
..... | |
...3. | |
...2. | |
SlimeAnim5_3 | |
#44891a #50a01e #306c0c #36770e | |
..... | |
..... | |
..... | |
..... | |
...23 | |
BelowSlime | |
#44891a #50a01e #306c0c #36770e | |
22222 | |
..... | |
..... | |
..... | |
..... | |
AboveSlime | |
#44891a #50a01e #306c0c #36770e | |
..... | |
..... | |
..... | |
..... | |
00000 | |
AboveSlimeJoin | |
#44891a #50a01e #306c0c #36770e | |
..... | |
..... | |
..... | |
00000 | |
00000 | |
WeakCrate | |
Orange | |
00000 | |
0...0 | |
0...0 | |
0...0 | |
00000 | |
Target | |
grey black | |
11111 | |
11111 | |
10001 | |
10101 | |
10001 | |
BelowWall | |
#444 | |
00000 | |
..... | |
..... | |
..... | |
..... | |
AboveWall | |
#93815f | |
..... | |
..... | |
..... | |
..... | |
00000 | |
WallD | |
#93815f #444 | |
..... | |
..... | |
..... | |
00000 | |
11111 | |
WallL | |
#93815f | |
0.... | |
0.... | |
0.... | |
0.... | |
0.... | |
WallR | |
#93815f | |
....0 | |
....0 | |
....0 | |
....0 | |
....0 | |
WallLR | |
#93815f | |
0...0 | |
0...0 | |
0...0 | |
0...0 | |
0...0 | |
AboveWallL | |
#93815f | |
..... | |
..... | |
..... | |
0.... | |
0.... | |
AboveWallR | |
#93815f | |
..... | |
..... | |
..... | |
....0 | |
....0 | |
AboveWallLR | |
#93815f | |
..... | |
..... | |
..... | |
0...0 | |
0...0 | |
AboveWallLRwithR | |
#93815f | |
....0 | |
....0 | |
....0 | |
0...0 | |
0...0 | |
Current | |
red | |
Blocked | |
red | |
SpawnWeakCrate | |
red | |
======= | |
LEGEND | |
======= | |
. = Background | |
# = Wall | |
P = Player | |
* = Slime | |
o = Target | |
Pushable = Slime or WeakCrate | |
Blocking = Wall or Blocked | |
Something = Wall or Slime or WeakCrate | |
AboveDecoration = AboveWall or AboveWallL or AboveWallR or WallL or WallR or WallLR | |
BelowDecoration = BelowWall or BelowSlime | |
SlimeAnim1 = SlimeAnim1_1 or SlimeAnim1_2 or SlimeAnim1_3 | |
SlimeAnim2 = SlimeAnim2_1 or SlimeAnim2_2 or SlimeAnim2_3 | |
SlimeAnim3 = SlimeAnim3_1 or SlimeAnim3_2 or SlimeAnim3_3 | |
SlimeAnim4 = SlimeAnim4_1 or SlimeAnim4_2 or SlimeAnim4_3 | |
SlimeAnim5 = SlimeAnim5_1 or SlimeAnim5_2 or SlimeAnim5_3 | |
SlimeAnim = SlimeAnim1 or SlimeAnim2 or SlimeAnim3 or SlimeAnim4 or SlimeAnim5 | |
======= | |
SOUNDS | |
======= | |
player move 36568707 | |
spawnweakcrate create 14399509 (split) | |
slime create 41555509 | |
restart 63086709 | |
undo 19490707 | |
endlevel 40333508 | |
================ | |
COLLISIONLAYERS | |
================ | |
Background | |
Target | |
BelowDecoration | |
Wall, Slime, WeakCrate | |
Player | |
Blocked, Current | |
SlimeAnim1 | |
SlimeAnim2 | |
SlimeAnim3 | |
SlimeAnim4 | |
SlimeAnim5 | |
AboveDecoration | |
WallD, AboveWallLR, AboveWallLRwithR, SpawnWeakCrate | |
AboveSlime, AboveSlimeJoin | |
====== | |
RULES | |
====== | |
(slime anim) | |
[ stationary Slime no Target ] -> [ action Slime random SlimeAnim ] | |
[ stationary Slime Target no SlimeAnim ] -> [ Target action Slime random SlimeAnim ] | |
[ action Slime ] -> [ Slime ] | |
[ SlimeAnim1_2 SlimeAnim2_3 SlimeAnim3_1 ] -> [] | |
[ SlimeAnim1_3 SlimeAnim2_1 SlimeAnim3_1 ] -> [] | |
late [ SlimeAnim no Slime ] -> [] | |
(3D) | |
down [ Wall | no Wall ] -> [ Wall WallD | BelowWall ] | |
up [ Wall | no Wall ] -> [ Wall | AboveWall ] | |
left [ Wall | no Wall ] -> [ Wall WallL | ] | |
right [ Wall WallL | no Wall ] -> [ Wall WallLR | ] | |
right [ Wall no AboveDecoration | no Wall ] -> [ Wall WallR | ] | |
up [ WallL | Wall no AboveDecoration ] -> [ WallL | Wall AboveWallL ] | |
up [ WallR | Wall no AboveDecoration ] -> [ WallR | Wall AboveWallR ] | |
up [ WallLR | Wall ] -> [ WallLR | Wall AboveWallLR ] | |
up [ WallL | Wall WallR ] -> [ WallL | Wall AboveWallLRwithR ] | |
[ AboveSlime ] -> [] | |
[ AboveSlimeJoin ] -> [] | |
[ BelowSlime ] -> [] | |
late down [ Slime | ] -> [ Slime | BelowSlime ] | |
late up [ Slime | Slime ] -> [ Slime | Slime AboveSlimeJoin ] | |
late up [ Slime | no Slime ] -> [ Slime | AboveSlime ] | |
(game) | |
[ > Player | Wall ] -> [ Player | Wall ] | |
[ > Player | Pushable ] -> [ > Player | > Pushable ] | |
startloop | |
[ > Pushable | stationary Pushable no Blocked ] -> [ > Pushable | > Pushable ] | |
[ > Pushable | stationary Something ] -> [ > Pushable > Current | Something ] | |
(we've hit something solid) | |
(check for dead-end) | |
[ Wall | perpendicular WeakCrate Current | Wall ] -> [ Wall | | Wall ] | |
[ Wall | perpendicular Slime Current | Wall ] -> [ Wall | Slime Blocked | Wall ] | |
(check for corner) | |
[ Wall | perpendicular Pushable Current | no Wall ] -> [ Wall | > Pushable | ] | |
([ Something | perpendicular Pushable Current | no Something ] -> [ Something | > Pushable | ] | |
[ Slime | perpendicular Pushable Current | WeakCrate ] -> [ Slime | > Pushable | > WeakCrate ]) | |
(check for split) | |
([ no Something | perpendicular WeakCrate Current | no Something ] -> [ | | ] | |
[ no Something | perpendicular Slime Current | no Something ] -> [ SpawnWeakCrate | | SpawnWeakCrate ] | |
[ WeakCrate | perpendicular WeakCrate Current | WeakCrate ] -> [ WeakCrate | | WeakCrate ] | |
[ WeakCrate | perpendicular Slime Current | WeakCrate ] -> [ < WeakCrate SpawnWeakCrate | | > WeakCrate SpawnWeakCrate ]) | |
[ | perpendicular Slime Current | ] -> [ < SpawnWeakCrate | | > SpawnWeakCrate ] | |
[ > SpawnWeakCrate Slime ] -> [ SpawnWeakCrate > Slime ] | |
endloop | |
[ > Current > Pushable ] -> [ Pushable ] | |
[ > Pushable | stationary Pushable ] -> [ Pushable | Pushable ] | |
[ > Player | stationary Pushable ] -> [ Player | Pushable ] | |
[ Blocked ] -> [] | |
[ Current ] -> [] | |
[ > Pushable | no Something ] -> [ | Pushable ] | |
[ SpawnWeakCrate no Something ] -> [ Slime ] | |
[ SpawnWeakCrate ] -> [] | |
late [ Player Slime ] -> [ Player ] | |
============== | |
WINCONDITIONS | |
============== | |
all target on Slime | |
all Slime on target | |
======= | |
LEVELS | |
======= | |
######### | |
#.......# | |
#...*...# | |
#.......# | |
#.p...o.# | |
#.......# | |
######### | |
######### | |
#.......# | |
#.p.....# | |
#...#.o.# | |
#...#...# | |
#...#.o.# | |
#.*.....# | |
#.......# | |
######### | |
######### | |
##..*..## | |
##.....## | |
##..p..## | |
#.......# | |
#.o.o.o.# | |
#.......# | |
######### | |
####### | |
##.p.## | |
#.o.o.# | |
#..*..# | |
#.o.o.# | |
##...## | |
####### | |
######### | |
#...#o.o# | |
#op*..#.# | |
#...#o.o# | |
######### | |
######### | |
###.o.### | |
#o#.#.#o# | |
#...p...# | |
#o#.*.#o# | |
###.o.### | |
######### | |
####### | |
##o#o## | |
#o...o# | |
##*.p## | |
#o...o# | |
###o### | |
####### | |
####### | |
#..#oo# | |
#.p.oo# | |
##...## | |
#oo.*.# | |
#oo#..# | |
####### | |
####### | |
#o.o.o# | |
#.*.p.# | |
#o.o.o# | |
#.###.# | |
#o.o.o# | |
####### | |
####### | |
#oo.oo# | |
#.*#p.# | |
#.....# | |
#oo#oo# | |
####### | |
######### | |
#o.....o# | |
#.#.p.#.# | |
#o..o..o# | |
#.#.*.#.# | |
#o.....o# | |
######### | |
######### | |
###o.o### | |
#..o#o..# | |
#.#opo#.# | |
#.##.##.# | |
#...*...# | |
######### | |
########### | |
###.##oo.## | |
#....#.#.## | |
#.#p...*.o# | |
#....#.#.## | |
###.##oo.## | |
########### | |
####### | |
#....o# | |
#.#.#.# | |
#o#*po# | |
#.#.#.# | |
#....o# | |
####### | |
########### | |
###.....### | |
#.#.#p#.#.# | |
#o...o...o# | |
#.#.#*#.#.# | |
#.........# | |
########### | |
########### | |
##..###..## | |
#.........# | |
###.###.### | |
###.*p#.### | |
###.###.### | |
##.o...o.## | |
########### | |
######### | |
#o..#...# | |
##..*..## | |
#.p##...# | |
#...###.# | |
#.#.#...# | |
#...#...# | |
######### | |
(######### | |
###.p.### | |
###...### | |
####.#### | |
#o.....o# | |
#..*o#..# | |
#o.....o# | |
#########) | |
message Thanks for playing :) | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Play this game by pasting the script in http://www.puzzlescript.net/editor.html |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment