Skip to content

Instantly share code, notes, and snippets.

@instr3
Created June 29, 2021 06:10
Show Gist options
  • Save instr3/d6105c50b06e26b050b5a86acebfdc0a to your computer and use it in GitHub Desktop.
Save instr3/d6105c50b06e26b050b5a86acebfdc0a to your computer and use it in GitHub Desktop.
Elephant Express (PuzzleScript Script)
Play this game by pasting the script in http://www.puzzlescript.net/editor.html
title Elephant Express
author Alith
homepage alith.itch.io
run_rules_on_level_start
========
OBJECTS
========
Background
#DDDDFF #CCCCFF
00000
01000
00000
00010
00000
Wall
#884400 Brown
00000
01110
01110
01110
00000
Elephant1
gray darkgray
.....
111..
0001.
11011
.1000
Elephant2
gray darkgray
..111
.....
.....
.....
.....
Elephant3
gray darkgray black
.....
.1111
10000
00201
00001
Elephant4
gray darkgray lightgray
22010
10000
10011
1001.
1111.
Elephant5
gray darkgray
.....
111..
0001.
00001
00001
Elephant6
gray darkgray
00001
00001
11001
.1001
.1111
NoseBackL
darkgray
.....
00...
00...
00...
.....
NoseBackR
darkgray
.....
...00
...00
...00
.....
NoseBackU
darkgray
.000.
.000.
.....
.....
.....
NoseBackD
darkgray
.....
.....
.....
.000.
.000.
NoseFrontL
gray
.....
.....
000..
.....
.....
NoseFrontR
gray
.....
.....
..000
.....
.....
NoseFrontU
gray
..0..
..0..
..0..
.....
.....
NoseFrontD
gray
.....
.....
..0..
..0..
..0..
Player
darkgray
.....
.....
..0..
.....
.....
PlayerTrace
darkgray
.....
..0..
.000.
..0..
.....
Crate1
lightred red
..1..
.111.
10001
10001
.111.
Crate2
lightgreen green
..1..
.111.
10001
10001
.111.
Target1
lightred
.....
.000.
.000.
.000.
.....
Target2
lightgreen
.....
.000.
.000.
.000.
.....
Unsatisfied
brown
.....
.....
..0..
.....
.....
ElephantPlaceHolder
transparent
=======
LEGEND
=======
. = Background
# = Wall
P = Player
1 = Crate1
2 = Crate2
Crate = Crate1 or Crate2
Target = Target1 or Target2
! = Target1 and Wall and Unsatisfied
@ = Target2 and Wall and Unsatisfied
ElephantBody = Elephant1 or Elephant3 or Elephant4 or Elephant5 or Elephant6
NoseFront = NoseFrontL or NoseFrontR or NoseFrontU or NoseFrontD
NoseBack = NoseBackL or NoseBackR or NoseBackU or NoseBackD
- = NoseFrontR and NoseBackR and Player
Obstacles = PlayerTrace or Wall or ElephantBody
E = ElephantPlaceHolder
=======
SOUNDS
=======
================
COLLISIONLAYERS
================
Background
Elephant2
Crate
NoseBackL
NoseBackR
NoseBackU
NoseBackD
PlayerTrace
NoseFrontL
NoseFrontR
NoseFrontU
NoseFrontD
Player, Wall, ElephantBody
Target
Unsatisfied
ElephantPlaceHolder
======
RULES
======
[ > Player | Obstacles ] -> [ Player | Obstacles ]
left [ left Player Crate | no Obstacles no Crate ] -> [ NoseBackL NoseFrontL PlayerTrace | NoseBackR NoseFrontR Player Crate]
right [ right Player Crate | no Obstacles no Crate ] -> [ NoseBackR NoseFrontR PlayerTrace | NoseBackL NoseFrontL Player Crate]
up [ up Player Crate | no Obstacles no Crate ] -> [ NoseBackU NoseFrontU PlayerTrace | NoseBackD NoseFrontD Player Crate]
down [ down Player Crate | no Obstacles no Crate ] -> [ NoseBackD NoseFrontD PlayerTrace | NoseBackU NoseFrontU Player Crate]
left [ left Player no Crate | no Obstacles ] -> [ NoseBackL NoseFrontL PlayerTrace | NoseBackR NoseFrontR Player]
right [ right Player no Crate | no Obstacles ] -> [ NoseBackR NoseFrontR PlayerTrace | NoseBackL NoseFrontL Player]
up [ up Player no Crate | no Obstacles ] -> [ NoseBackU NoseFrontU PlayerTrace | NoseBackD NoseFrontD Player]
down [ down Player no Crate | no Obstacles ] -> [ NoseBackD NoseFrontD PlayerTrace | NoseBackU NoseFrontU Player]
[ > Player ] -> [ Player ]
left [ NoseBackR action Player Crate | no Obstacles no Crate ] -> [ NoseBackR Player | Crate ]
right [ NoseBackL action Player Crate | no Obstacles no Crate ] -> [ NoseBackL Player | Crate ]
up [ NoseBackD action Player Crate | no Obstacles no Crate ] -> [ NoseBackD Player | Crate ]
down [ NoseBackU action Player Crate | no Obstacles no Crate ] -> [ NoseBackU Player | Crate ]
[ action Player Crate1 | Unsatisfied Target1 no Crate ] -> [ Player | Target1 ]
[ action Player Crate2 | Unsatisfied Target2 no Crate ] -> [ Player | Target2 ]
down [ ElephantPlaceHolder | ElephantPlaceHolder ] -> [ ElephantPlaceHolder | ]
right [ ElephantPlaceHolder | ElephantPlaceHolder | ElephantPlaceHolder ] -> [ Elephant1 ElephantPlaceHolder | Elephant3 ElephantPlaceHolder | Elephant5 ElephantPlaceHolder ]
down [ ElephantPlaceHolder Elephant1 | ] -> [ Elephant1 | Elephant2 ]
down [ ElephantPlaceHolder Elephant3 | ] -> [ Elephant3 | Elephant4 ]
down [ ElephantPlaceHolder Elephant5 | ] -> [ Elephant5 | Elephant6 ]
==============
WINCONDITIONS
==============
No Unsatisfied
=======
LEVELS
=======
#########
#.......#
#.....2.@
#...1...!
#...-EEE#
#....EEE#
#########
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment