This commit is contained in:
monsterkodi 2016-08-08 13:27:33 +02:00
commit 142091f36f
53 changed files with 2772 additions and 0 deletions

30
levels/bombs.coffee Normal file
View File

@ -0,0 +1,30 @@
# 0000000 0000000 00 00 0000000 0000000
# 000 000 000 000 000 000 000 000 000
# 0000000 000 000 000000000 0000000 0000000
# 000 000 000 000 000 0 000 000 000 000
# 0000000 0000000 000 000 0000000 0000000
module.exports =
name: 'bombs'
scheme: "red_scheme"
size: [9,9,9]
intro: "bombs"
help: """
$scale(1.5)mission:
get to the exit!
to get to the exit,
use the bombs
"""
player: position: [0,-4,0]
exits: [
name: "exit"
active: 1
position: [0,2,0]
],
create: ->
world.addObjectAtPos KikiBomb(), world.decenter 0,-4,2
world.addObjectAtPos KikiBomb(), world.decenter 0,-4,-2
world.addObjectAtPos KikiBomb(), world.decenter -3,-2,0

32
levels/borg.coffee Normal file
View File

@ -0,0 +1,32 @@
# level design by Michael Abel
# 0000000 0000000 00000000 0000000
# 000 000 000 000 000 000 000
# 0000000 000 000 0000000 000 0000
# 000 000 000 000 000 000 000 000
# 0000000 0000000 000 000 0000000
module.exports =
name: 'borg'
scheme: "default_scheme"
size: [9,9,9]
intro: "borg"
help: """
Believe me,
they are
CRAZY!
"""
player:
coordinates: [0,0,0]
nostatus: 0
exits: [
name: "exit"
active: 1
position: [0,0,0]
]
create: ->
world.addObjectAtPos KikiLight(), KikiPos 7,7,7
for i in [0...150]
world.setObjectRandom KikiMutant()

48
levels/bridge.coffee Normal file
View File

@ -0,0 +1,48 @@
# 0000000 00000000 000 0000000 0000000 00000000
# 000 000 000 000 000 000 000 000 000
# 0000000 0000000 000 000 000 000 0000 0000000
# 000 000 000 000 000 000 000 000 000 000
# 0000000 000 000 000 0000000 0000000 00000000
module.exports =
name: 'bridge'
scheme: "red_scheme"
size: [9,9,5]
intro: "bridge"
help: """
$scale(1.5)mission:
activate the exit!
to activate the exit,
feed it with electricity:
connect the generator
with the motor
place a wire stone
next to the exit
"""
player: position: [0,-3,1]
exits: [
name: "exit"
active: 0
position: [0,-1,0]
]
create: ->
s = world.getSize()
world.addObjectAtPos KikiMotorGear(KikiFace.NY), KikiPos s.x/2-1, s.y-1, s.z/2
world.addObjectAtPos KikiMotorCylinder(KikiFace.NY), KikiPos s.x/2-1, s.y-2, s.z/2
world.addObjectAtPos KikiGenerator(KikiFace.NY), KikiPos s.x/2+1, s.y-1, s.z/2
world.addObjectLine "KikiWire (KikiFace.NY, KikiWire.VERTICAL)", KikiPos(s.x/2, s.y-1, 0), KikiPos s.x/2, s.y-1, s.z
world.addObjectLine "KikiWire (KikiFace.PY, KikiWire.VERTICAL)", KikiPos(s.x/2, 0, 0), KikiPos s.x/2, 0, s.z
world.addObjectLine "KikiWire (KikiFace.PZ, KikiWire.VERTICAL)", KikiPos(s.x/2, 0, 0), KikiPos s.x/2, s.y, 0
world.addObjectLine "KikiWire (KikiFace.NZ, KikiWire.VERTICAL)", KikiPos(s.x/2, 0, s.z-1), KikiPos s.x/2, s.y, s.z-1
world.addObjectAtPos KikiWireStone(), KikiPos s.x/2+3, 0, s.z/2
world.addObjectAtPos KikiWireStone(), KikiPos s.x/2-3, 0, s.z/2
world.addObjectAtPos KikiWireStone(), KikiPos s.x/2+2, 1, s.z/2
world.addObjectAtPos KikiWireStone(), KikiPos s.x/2-2, 1, s.z/2
world.addObjectAtPos KikiWireStone(), KikiPos s.x/2+1, 2, s.z/2
world.addObjectAtPos KikiWireStone(), KikiPos s.x/2-1, 2, s.z/2

87
levels/bronze.coffee Normal file
View File

@ -0,0 +1,87 @@
module.exports =
name: 'bronze'
scheme: "bronze_scheme"
size: [9,6,9]
intro: "bronze"
help: """
$scale(1.5)mission:
activate the exit!
to activate the exit
feed it with electricity:
connect the generator
with the motor
and close the circuit
with the wire stones"
"""
player: position: [0,1,0]
exits: [
name: "exit"
active: 0
position: [0,0,0]
]
create: ->
s = world.getSize()
d = 2
world.addObjectAtPos(KikiMotorCylinder(KikiFace.PY), KikiPos(s.x/2, 1, s.z/2))
world.addObjectAtPos(KikiMotorGear(KikiFace.PY), KikiPos(s.x/2, 0, s.z/2))
world.addObjectAtPos(KikiGear(KikiFace.PY), KikiPos(s.x/2-1, s.y-1, s.z/2-1))
world.addObjectAtPos(KikiGenerator(KikiFace.PY), KikiPos(s.x/2+1, s.y-1, s.z/2-1))
world.addObjectAtPos(KikiBomb(), KikiPos(s.x/2-1, s.y-1, s.z/2+1))
world.addObjectAtPos(KikiWireStone(), KikiPos(s.x/2, s.y-1, s.z/2))
world.addObjectAtPos(KikiWireStone(), KikiPos(s.x/2+1, s.y-2, s.z/2))
world.addObjectAtPos(KikiWireStone(), KikiPos(s.x/2-1, s.y-2, s.z/2))
# floor wire square
world.addObjectLine("KikiWire(KikiFace.PY, 10)", KikiPos(s.x/2-d+1, 0, s.z/2-d), KikiPos(s.x/2+d, 0, s.z/2-d))
world.addObjectLine("KikiWire(KikiFace.PY, 10)", KikiPos(s.x/2-d+1, 0, s.z/2+d), KikiPos(s.x/2+d, 0, s.z/2+d))
world.addObjectAtPos(KikiWire(KikiFace.PY, 5), KikiPos(s.x/2-d, 0, s.z/2+1))
world.addObjectAtPos(KikiWire(KikiFace.PY, 5), KikiPos(s.x/2-d, 0, s.z/2-1))
world.addObjectAtPos(KikiWire(KikiFace.PY, 13), KikiPos(s.x/2-d, 0, s.z/2))
world.addObjectAtPos(KikiWire(KikiFace.PY, 5), KikiPos(s.x/2+d, 0, s.z/2+1))
world.addObjectAtPos(KikiWire(KikiFace.PY, 5), KikiPos(s.x/2+d, 0, s.z/2-1))
world.addObjectAtPos(KikiWire(KikiFace.PY, 7), KikiPos(s.x/2+d, 0, s.z/2))
# corners of wire square
world.addObjectAtPos(KikiWire(KikiFace.PY, 6), KikiPos(s.x/2-d, 0, s.z/2-d))
world.addObjectAtPos(KikiWire(KikiFace.PY, 3), KikiPos(s.x/2-d, 0, s.z/2+d))
world.addObjectAtPos(KikiWire(KikiFace.PY, 9), KikiPos(s.x/2+d, 0, s.z/2+d))
world.addObjectAtPos(KikiWire(KikiFace.PY, 12), KikiPos(s.x/2+d, 0, s.z/2-d))
world.addObjectLine("KikiWire(KikiFace.PY, 10)", KikiPos(0, 0, s.z/2), KikiPos(s.x/2-d, 0, s.z/2))
world.addObjectLine("KikiWire(KikiFace.PY, 10)", KikiPos(s.x/2+d+1, 0, s.z/2), KikiPos(s.x, 0, s.z/2))
# ceiling wire square
world.addObjectLine("KikiWire(KikiFace.NY, 10)", KikiPos(s.x/2-d+1, s.y-1, s.z/2-d), KikiPos(s.x/2+d, s.y-1, s.z/2-d))
world.addObjectLine("KikiWire(KikiFace.NY, 10)", KikiPos(s.x/2-d+1, s.y-1, s.z/2+d), KikiPos(s.x/2+d, s.y-1, s.z/2+d))
world.addObjectAtPos(KikiWire(KikiFace.NY, 5), KikiPos(s.x/2-d, s.y-1, s.z/2+1))
world.addObjectAtPos(KikiWire(KikiFace.NY, 5), KikiPos(s.x/2-d, s.y-1, s.z/2-1))
world.addObjectAtPos(KikiWire(KikiFace.NY, 13), KikiPos(s.x/2-d, s.y-1, s.z/2))
world.addObjectAtPos(KikiWire(KikiFace.NY, 5), KikiPos(s.x/2+d, s.y-1, s.z/2+1))
world.addObjectAtPos(KikiWire(KikiFace.NY, 5), KikiPos(s.x/2+d, s.y-1, s.z/2-1))
world.addObjectAtPos(KikiWire(KikiFace.NY, 7), KikiPos(s.x/2+d, s.y-1, s.z/2))
# corners of wire square
world.addObjectAtPos(KikiWire(KikiFace.NY, 3), KikiPos(s.x/2-d, s.y-1, s.z/2-d))
world.addObjectAtPos(KikiWire(KikiFace.NY, 6), KikiPos(s.x/2-d, s.y-1, s.z/2+d))
world.addObjectAtPos(KikiWire(KikiFace.NY, 12), KikiPos(s.x/2+d, s.y-1, s.z/2+d))
world.addObjectAtPos(KikiWire(KikiFace.NY, 9), KikiPos(s.x/2+d, s.y-1, s.z/2-d))
world.addObjectLine("KikiWire(KikiFace.NY, 10)", KikiPos(0, s.y-1, s.z/2), KikiPos(s.x/2-d, s.y-1, s.z/2))
world.addObjectLine("KikiWire(KikiFace.NY, 10)", KikiPos(s.x/2+d+1, s.y-1, s.z/2), KikiPos(s.x, s.y-1, s.z/2))
# wall wire lines
world.addObjectLine("KikiWire(KikiFace.PX, 5)", KikiPos( 0, 0, s.z/2), KikiPos( 0, s.y, s.z/2))
world.addObjectLine("KikiWire(KikiFace.NX, 5)", KikiPos(s.x-1, 0, s.z/2), KikiPos(s.x-1, s.y, s.z/2))

36
levels/captured.coffee Normal file
View File

@ -0,0 +1,36 @@
# Level design of 'captured' by Niko Boehm
module.exports =
name: "captured"
scheme: "default_scheme"
size: [9,9,9]
intro: "captured"
help: """
$scale(1.5)mission:
get to the exit!
to get to the exit,
move the stones
"""
player: position: [0,-3,0]
exits: [
name: "exit"
active: 1
position: [0,0,0]
]
create: ->
s = world.getSize()
for i in [-2, 2]
world.addObjectPoly (KikiStone, [world.decenter(1, 1, i), world.decenter(1, -1, i),
world.decenter(-1, -1, i), world.decenter(-1, 1, i)])
world.addObjectPoly (KikiStone, [world.decenter(1, i, 1), world.decenter(1, i, -1),\
world.decenter(-1, i, -1), world.decenter(-1, i, 1)])
world.addObjectPoly (KikiStone, [world.decenter(i, 1, 1), world.decenter(i, 1, -1),\
world.decenter(i, -1, -1), world.decenter(i, -1, 1)])
for i in [-4, -2, 2, 4]
world.addObjectAtPos(KikiStone(), world.decenter(i, 0, 0))
world.addObjectAtPos(KikiStone(), world.decenter(0, i, 0))
world.addObjectAtPos(KikiStone(), world.decenter(0, 0, i))

37
levels/chain.coffee Normal file
View File

@ -0,0 +1,37 @@
module.exports =
name: "chain"
scheme: "candy_scheme"
size: [9,9,5]
intro: "chain"
help: """
$scale(1.5)mission:
activate the exit!
to activate the exit,
feed it with electricity:
connect the generator
with the motor
place a wire stone
next to the exit
"""
player: position: [1,2,0]
exits: [
name: "exit"
active: 0
position: [0,-1,0]
],
create: ->
s = world.getSize()
d = s.z/2
world.addObjectAtPos(KikiWall(), KikiPos(0, 0, d))
world.addObjectAtPos(KikiBomb(), KikiPos(0, 1, d))
world.addObjectAtPos(KikiBomb(), KikiPos(1, 0, d))
world.addObjectAtPos(KikiBomb(), KikiPos(0, 7, d))
world.addObjectAtPos(KikiBomb(), KikiPos(5, 7, d))
world.addObjectAtPos(KikiBomb(), KikiPos(1, 3, d))
world.addObjectAtPos(KikiBomb(), KikiPos(5, 3, d))
world.addObjectAtPos(KikiWireStone(), KikiPos(1,5,d))

85
levels/cheese.coffee Normal file
View File

@ -0,0 +1,85 @@
# level design by Owen Hay
module.exports =
name: "cheese"
scheme: "yellow_scheme"
size: [11,12,7]
intro: "cheese"
help: """
$scale(1.5)mission:
activate the exit!
to activate the switches,
shoot them
to be able to shoot the switches,
move the center stone
to move the center stone,
use the bomb.
the bomb will detonate if you shoot it
"""
player:
coordinates: [3, 4,3]
nostatus: 0
exits: [
name: "exit"
active: 0
position: [-1,0,0]
]
create: ->
s = world.getSize()
h = 0
# bomb and stones
for i in [1, 2]
world.addObjectAtPos(KikiWall(), KikiPos(1, i, 1))
world.addObjectAtPos(KikiWall(), KikiPos(1, i, 3))
world.addObjectAtPos(KikiWall(), KikiPos(2, i, 1))
world.addObjectAtPos(KikiWall(), KikiPos(2, i, 2))
world.addObjectAtPos(KikiWall(), KikiPos(2, i, 5))
world.addObjectAtPos(KikiWall(), KikiPos(3, i, 1))
world.addObjectAtPos(KikiWall(), KikiPos(3, i, 2))
world.addObjectAtPos(KikiWall(), KikiPos(3, i, 4))
world.addObjectAtPos(KikiWall(), KikiPos(3, i, 5))
world.addObjectAtPos(KikiWall(), KikiPos(5, i, 0))
world.addObjectAtPos(KikiWall(), KikiPos(5, i, 2))
world.addObjectAtPos(KikiWall(), KikiPos(5, i, 3))
world.addObjectAtPos(KikiWall(), KikiPos(5, i, 4))
world.addObjectAtPos(KikiWall(), KikiPos(6, i, 1))
world.addObjectAtPos(KikiWall(), KikiPos(6, i, 2))
world.addObjectAtPos(KikiWall(), KikiPos(7, i, 2))
world.addObjectAtPos(KikiWall(), KikiPos(7, i, 4))
world.addObjectAtPos(KikiWall(), KikiPos(7, i, 5))
world.addObjectAtPos(KikiWall(), KikiPos(8, i, 0))
world.addObjectAtPos(KikiWall(), KikiPos(8, i, 2))
world.addObjectAtPos(KikiWall(), KikiPos(8, i, 4))
world.addObjectAtPos(KikiWall(), KikiPos(8, i, 5))
world.addObjectAtPos(KikiWall(), KikiPos(9, i, 2))
world.addObjectAtPos(KikiWall(), KikiPos(9, i, 4))
world.addObjectAtPos(KikiWall(), KikiPos(10, i, 3))
for i in range(0,s.x)
for j in range(0, s.z)
world.addObjectAtPos(KikiStone(), KikiPos(i,2,j))
world.switch_counter = 0
switched = (switch) ->
world.switch_counter += switch.isActive() and 1 or -1
exit = kikiObjectToGate(world.getObjectWithName("exit"))
exit.setActive(world.switch_counter == 4)
switch1 = KikiSwitch()
switch1.getEventWithName("switched").addAction(continuous(()-> s=switch1: switched(s)))
switch2 = KikiSwitch()
switch2.getEventWithName("switched").addAction(continuous(()-> s=switch2: switched(s)))
switch3 = KikiSwitch()
switch3.getEventWithName("switched").addAction(continuous(()-> s=switch3: switched(s)))
switch4 = KikiSwitch()
switch4.getEventWithName("switched").addAction(continuous(()-> s=switch4: switched(s)))
world.addObjectAtPos(switch1, KikiPos(1, 0 ,2))
world.addObjectAtPos(switch2, KikiPos(7, 1, 0))
world.addObjectAtPos(switch3, KikiPos(9, 0, 0))
world.addObjectAtPos(switch4, KikiPos(9, 1, 5))

43
levels/church.coffee Normal file
View File

@ -0,0 +1,43 @@
module.exports =
name: "church"
scheme: "yellow_scheme"
size: [5,7,5]
intro: "church"
help: """
$scale(1.5)mission:
activate the exit!
to activate the exit,
feed it with electricity:
connect the generator
with the motor
place a wire stone
next to the exit
"""
player: position: [1,0,0]
exits: [
name: "exit"
active: 0
position: [0,-1,0]
]
create: ->
s = world.getSize()
world.addObjectLine("KikiWireStone()", KikiPos(0, 0, 0), KikiPos(0, s.y-2, 0))
world.addObjectLine("KikiWireStone()", KikiPos(s.x-1, 0, 0), KikiPos(s.x-1, s.y-2, 0))
world.addObjectLine("KikiWireStone()", KikiPos(s.x-1, 0, s.z-1), KikiPos(s.x-1, s.y-2, s.z-1))
world.addObjectLine("KikiWireStone()", KikiPos(0, 0, s.z-1), KikiPos(0, s.y-2, s.z-1))
world.addObjectAtPos(KikiBomb(), KikiPos(s.x/2, s.y-2, s.z/2))
world.addObjectAtPos(KikiGenerator(KikiFace.PY), KikiPos(s.x/2, s.y/2, s.z/2))
world.addObjectAtPos(KikiWireStone(), KikiPos(1, s.y-2, 1))
world.addObjectAtPos(KikiWireStone(), KikiPos(s.x-2, s.y-2, 1))
world.addObjectAtPos(KikiWireStone(), KikiPos(1, s.y-2, s.z-2))
world.addObjectAtPos(KikiWireStone(), KikiPos(s.x-2, s.y-2, s.z-2))
world.addObjectAtPos(KikiWireStone(), KikiPos(s.x/2, s.y-1, s.z/2))
world.addObjectAtPos(KikiMotorGear(KikiFace.PY), KikiPos(s.x/2, 0, 0))
world.addObjectAtPos(KikiMotorCylinder(KikiFace.PY), KikiPos(s.x/2, 1, 0))

69
levels/circuit.coffee Normal file
View File

@ -0,0 +1,69 @@
# level design by Michael Abel
module.exports =
name: "circuit"
scheme: "tron_scheme"
size: [9,9,9]
intro: "circuit"
help: """
$scale(1.5)mission:
activate the exit!
to activate the exit
feed it with electricity
"""
player:
coordinates: [4,6,4]
nostatus: 0
orientation: rot0
exits: [
name: "exit"
active: 0
coordinates: [8,8,8]
]
create: ->
s=world.getSize()
mx=s.x/2
my=s.y/2
mz=s.z/2
sx=s.x-1
sy=s.y-1
sz=s.z-1
p=[ [KikiPos( 0, 0, 0+1),KikiPos( 0, 0,mz),KikiPos( 0,my,mz), KikiFace.X, KikiFace.X],
[KikiPos( 0,my,mz+1),KikiPos( 0,my,sz),KikiPos(mx,my,sz), KikiFace.X, KikiFace.NZ],
[KikiPos(mx,my-1,sz),KikiPos(mx, 0,sz),KikiPos(my, 0,mz), KikiFace.NZ, KikiFace.Y],
[KikiPos(mx+1, 0,mz),KikiPos(sx, 0,mz),KikiPos(sx,my,mz), KikiFace.Y, KikiFace.NX],
[KikiPos(sx,my,mz-1),KikiPos(sx,my, 0),KikiPos(mx,my, 0), KikiFace.NX, KikiFace.Z],
[KikiPos(mx,my+1, 0),KikiPos(mx,sy, 0),KikiPos(mx,sy,my), KikiFace.Z, KikiFace.NY],
[KikiPos(mx+1,sy,my),KikiPos(sx,sy,mz),KikiPos(sx,sy,sz), KikiFace.NY, KikiFace.NY],
]
for k in p
stone= () -> KikiWire(k[3], 15)
world.addObjectLine(stone,k[0],k[1])
world.addObjectAtPos(KikiWire(k[3], 15), k[1]) # correct the last missing stone of the line
stone= () ->KikiWire(k[4], 15)
world.addObjectLine(stone,k[1],k[2])
world.addObjectAtPos(KikiWireStone(), world.decenter(1,0,0))
world.addObjectAtPos(KikiWireStone(), world.decenter(-1,0,0))
world.addObjectAtPos(KikiWireStone(), world.decenter(0,1,0))
world.addObjectAtPos(KikiWireStone(), world.decenter(0,-1,0))
world.addObjectAtPos(KikiWireStone(), world.decenter(0,0,1))
world.addObjectAtPos(KikiWireStone(), world.decenter(0,0,-1))
world.addObjectAtPos(KikiWireStone(), world.decenter(0,0,2))
world.addObjectAtPos(KikiWireStone(), world.decenter(0,0,-2))
world.addObjectAtPos(KikiWire(KikiFace.X), KikiPos(0,0,0))
world.addObjectAtPos(KikiWire(KikiFace.Z), KikiPos(0,0,0))
world.addObjectAtPos(KikiWire(KikiFace.Z), KikiPos(1,0,0))
world.addObjectAtPos(KikiWire(KikiFace.NY), KikiPos(sx,sy,sz))
world.addObjectAtPos(KikiMotorGear(KikiFace.Z), KikiPos(2,0,0))
world.addObjectAtPos(KikiMotorCylinder(KikiFace.Z), KikiPos(2,0,1))
g=KikiGenerator(KikiFace.Z)
world.addObjectAtPos(g, KikiPos(mx,my,mz))

32
levels/columns.coffee Normal file
View File

@ -0,0 +1,32 @@
module.exports =
name: "columns"
scheme: "green_scheme"
size: [7,9,7]
intro: "columns"
help: """
$scale(1.5)mission:
get to the exit!
to get to the exit,
use the stones
"""
player: position: [0,-1,0]
exits: [
name: "exit"
active: 1
position: [0,0,0]
]
create: ->
s = world.getSize()
for y in range(-s.y/2+1, s.y/2+1)
for x in range(-s.x/2+1, s.x/2+1, 2)
for z in range(-s.z/2+1, s.z/2+1, 2)
world.addObjectAtPos(KikiStone(), world.decenter(x, y, z))
world.deleteObject(world.getOccupantAtPos(world.decenter(-1, 0, 1)))
world.deleteObject(world.getOccupantAtPos(world.decenter( 1, 0,-1)))
world.deleteObject(world.getOccupantAtPos(world.decenter( 1, 0, 1)))
world.deleteObject(world.getOccupantAtPos(world.decenter(-1, 0,-1)))

79
levels/conductor.coffee Normal file
View File

@ -0,0 +1,79 @@
# level design by Michael Abel
module.exports =
name: "conductor"
scheme: "default_scheme"
size: [11,9,11]
intro: "conductor"
help: """
$scale(1.5)mission:
activate the exit!
to activate the exit
feed it with electricity:
connect the generator
with the motor
and place a powered wirestone
next to the exit
"""
player:
coordinates: [3,0,3]
nostatus: 0
exits: [
name: "exit"
active: 0
position: [0,0,4]
],
create: ->
KikiWireWall = (c , p) ->
if world.isUnoccupiedPos(KikiPos(p.x,p.y,p.z))
world.addObjectAtPos(KikiWall() , KikiPos(p.x,p.y,p.z))
world.addObjectAtPos(KikiWire (KikiFace.X, c ), KikiPos(p.x+1,p.y ,p.z ))
world.addObjectAtPos(KikiWire (KikiFace.NX, c ), KikiPos(p.x-1,p.y ,p.z ))
world.addObjectAtPos(KikiWire (KikiFace.Y, c ), KikiPos(p.x ,p.y+1,p.z ))
world.addObjectAtPos(KikiWire (KikiFace.NY, c ), KikiPos(p.x ,p.y-1,p.z ))
world.addObjectAtPos(KikiWire (KikiFace.Z, c ), KikiPos(p.x ,p.y ,p.z+1))
world.addObjectAtPos(KikiWire (KikiFace.NZ, c ), KikiPos(p.x ,p.y ,p.z-1))
for h in [2,4,6]
world.addObjectLine (KikiWall, KikiPos(5,2,h), KikiPos(5,6,h) )
world.addObjectAtPos(KikiWireStone(), KikiPos(5,1,h))
world.addObjectAtPos(KikiWireStone(), KikiPos(5,6,h))
wire_u= -> KikiWire(KikiFace.Z, 4+1 )
wire_d= -> KikiWire(KikiFace.NZ, 4+1 )
world.addObjectLine(wire_d, KikiPos(5,2,1),KikiPos(5,6,1))
world.addObjectLine(wire_u, KikiPos(5,2,3),KikiPos(5,6,3))
world.addObjectAtPos( KikiWire (KikiFace.NY, 5 ), KikiPos(5,1,2))
world.addObjectAtPos( KikiWire (KikiFace.Y, 5 ), KikiPos(5,6,2))
world.addObjectAtPos(KikiMotorGear(KikiFace.Z), KikiPos(5,0,0))
world.addObjectAtPos(KikiMotorCylinder(KikiFace.Z), KikiPos(5,0,1))
world.addObjectAtPos(KikiMotorCylinder(KikiFace.NX), KikiPos(4,0,0))
world.addObjectAtPos(KikiMotorCylinder(KikiFace.X), KikiPos(6,0,0))
g = KikiGenerator(KikiFace.Z) #set to Active as last command in LevelS
world.addObjectAtPos(g, KikiPos(5,1,0))
world.addObjectAtPos(KikiWireStone(), KikiPos(5,2,0))
world.addObjectAtPos(KikiWireStone(), KikiPos(5,2,1))
world.addObjectAtPos(KikiWireStone(), KikiPos(5,5,3))
world.addObjectAtPos(KikiWireStone(), KikiPos(5,5,5))
KikiWireWall(15, KikiPos(5,4,8))
world.addObjectAtPos(KikiWall(), KikiPos(0,0,0))
world.addObjectAtPos(KikiWall(), KikiPos(10,0,0))
world.addObjectAtPos(KikiWall(), KikiPos(10,8,0))
world.addObjectAtPos(KikiWall(), KikiPos(0,8,0))
g.setActive(True)

24
levels/cube.coffee Normal file
View File

@ -0,0 +1,24 @@
# level design by Michael Abel
module.exports =
name: "cube"
scheme: "default_scheme"
size: [5,5,5]
intro: "cube"
help: "reach the exit!"
player:
coordinates: [2,0,0]
nostatus: 0
orientation: rot0
exits: [
name: "exit"
active: 1
position: [0,2,2]
],
create: ->
#startblock
x=range(5)
for (i,j,l) in [(i,j,l) for i in x for j in x for l in x]
if (-1)**(i+j+l) == -1
world.addObjectAtPos(KikiStone(), KikiPos(i,j,l))

29
levels/edge.coffee Normal file
View File

@ -0,0 +1,29 @@
# level design by Michael Abel
module.exports =
name: "edge"
scheme: "candy_scheme"
size: [7,7,7]
intro: "edge"
help: "$scale(1.5)mission:\nget to the exit!"
player:
coordinates: [3,0,0]
nostatus: 0
orientation: rot0
exits: [
name: "exit"
active: 1
position: [0,0,0]
]
create: ->
s=world.getSize()
for (i,j,l) in [ (m,n,o) for m in range(3) for n in range(3) for o in range(3)]:
if (i==2 or j==2 or l==2) and i>=1 and j>=1 and l >=1 :
c= 0.6 - (0.3)*(-1)**(i+j+l)
d= 0.6 + (0.3)*(-1)**(i+j+l)
world.addObjectAtPos(KikiStone(KColor(c ,0, d, 0.8) , False), KikiPos(i,j,l))
world.addObjectAtPos(KikiStone(KColor(c ,0, d, 0.8) , False), KikiPos(s.x-i-1,s.y-j-1,s.z-l-1))
world.addObjectAtPos(KikiStone(KColor(c ,0, d, 0.8) , False), KikiPos(s.x-i-1,j,l))
world.addObjectAtPos(KikiStone(KColor(c ,0, d, 0.8) , False), KikiPos(i,s.y-j-1,s.z-l-1))

61
levels/electro.coffee Normal file
View File

@ -0,0 +1,61 @@
module.exports =
name: "electro"
scheme: "metal_scheme"
size: [9,7,9]
intro: "electro"
help: """
$scale(1.5)mission:
activate the exit!
to activate the exit
feed it with electricity:
connect the generator
with the motor
"""
player:
coordinates: [2,0,4]
orientation: rotz180
nostatus: 0
exits: [
name: "exit"
active: 0
position: [0,0,0]
],
create: ->
s = world.getSize ()
d = 2
world.addObjectLine(KikiWireStone, world.decenter(-d, s.y/2, 0), world.decenter(-d, 0, 0))
world.addObjectLine(KikiWireStone, world.decenter( d, s.y/2, 0), world.decenter( d, 0, 0))
world.addObjectLine(KikiWireStone, world.decenter( d, 0, 0), world.decenter( 0, 0, 0))
world.addObjectLine(KikiWireStone, world.decenter(-d, 0, 0), world.decenter( 0, 0, 0))
world.addObjectAtPos(KikiGear(KikiFace.PY), KikiPos(s.x/2-1, 0, s.z/2-1))
world.addObjectAtPos(KikiGenerator(KikiFace.PY), KikiPos(s.x/2+1, 0, s.z/2+1))
world.addObjectAtPos(KikiMotorCylinder(KikiFace.PY), KikiPos(s.x/2, 1, s.z/2))
world.addObjectAtPos(KikiMotorGear(KikiFace.PY), KikiPos(s.x/2, 0, s.z/2))
# floor wire square
world.addObjectLine("KikiWire(KikiFace.PY, 10)", KikiPos(s.x/2-d+1, 0, s.z/2-d), KikiPos(s.x/2+d, 0, s.z/2-d))
world.addObjectLine("KikiWire(KikiFace.PY, 10)", KikiPos(s.x/2-d+1, 0, s.z/2+d), KikiPos(s.x/2+d, 0, s.z/2+d))
world.addObjectLine("KikiWire(KikiFace.PY, 5)", KikiPos(s.x/2-d, 0, s.z/2-d+1), KikiPos(s.x/2-d, 0, s.z/2+d))
world.addObjectLine("KikiWire(KikiFace.PY, 5)", KikiPos(s.x/2+d, 0, s.z/2-d+1), KikiPos(s.x/2+d, 0, s.z/2+d))
# corners of wire square
world.addObjectAtPos(KikiWire(KikiFace.PY, 6), KikiPos(s.x/2-d, 0, s.z/2-d))
world.addObjectAtPos(KikiWire(KikiFace.PY, 3), KikiPos(s.x/2-d, 0, s.z/2+d))
world.addObjectAtPos(KikiWire(KikiFace.PY, 9), KikiPos(s.x/2+d, 0, s.z/2+d))
world.addObjectAtPos(KikiWire(KikiFace.PY, 12), KikiPos(s.x/2+d, 0, s.z/2-d))
world.addObjectLine("KikiWire(KikiFace.PX, 5)", KikiPos( 0, 0, s.z/2), KikiPos( 0, s.y, s.z/2))
world.addObjectLine("KikiWire(KikiFace.NX, 5)", KikiPos(s.x-1, 0, s.z/2), KikiPos(s.x-1, s.y, s.z/2))
world.addObjectLine("KikiWire(KikiFace.NY, 10)", KikiPos(0, s.y-1, s.z/2), KikiPos(s.x/2-d, s.y-1, s.z/2))
world.addObjectLine("KikiWire(KikiFace.NY, 10)", KikiPos(s.x-d, s.y-1, s.z/2), KikiPos(s.x, s.y-1, s.z/2))
world.addObjectLine("KikiWire(KikiFace.PY, 10)", KikiPos(0, 0, s.z/2), KikiPos(s.x/2-d, 0, s.z/2))
world.addObjectLine("KikiWire(KikiFace.PY, 10)", KikiPos(s.x-d, 0, s.z/2), KikiPos(s.x, 0, s.z/2))
world.addObjectAtPos(KikiWire(KikiFace.PY, 13), KikiPos(s.x/2-d, 0, s.z/2))
world.addObjectAtPos(KikiWire(KikiFace.PY, 7), KikiPos(s.x/2+d, 0, s.z/2))

49
levels/elevate.coffee Normal file
View File

@ -0,0 +1,49 @@
module.exports =
name: "elevate"
scheme: "bronze_scheme"
size: [9,5,7]
intro: "elevate"
help: """
$scale(1.5)mission:
activate the exit!
to activate the exit,
feed it with electricity
use the bombs
to elevate the gears
and the generator
the bombs will detonate
if you shoot them
"""
player: position: [3,-2,0]
exits: [
name: "exit"
active: 0
position: 2,-2,0
]
create: ->
s = world.getSize()
world.addObjectAtPos(KikiMotorGear(KikiFace.NY), KikiPos(s.x/2-3, s.y-1, s.z/2))
world.addObjectAtPos(KikiMotorCylinder(KikiFace.NY), KikiPos(s.x/2-3, s.y-2, s.z/2))
world.addObjectAtPos(KikiGenerator (KikiFace.NY), KikiPos(s.x/2+2, 1, s.z/2-1))
world.addObjectAtPos(KikiGear(KikiFace.NY), KikiPos(s.x/2+1, 1, s.z/2+1))
world.addObjectAtPos(KikiGear(KikiFace.NY), KikiPos(s.x/2, 1, s.z/2-1))
world.addObjectAtPos(KikiGear(KikiFace.NY), KikiPos(s.x/2-1, 1, s.z/2+1))
world.addObjectAtPos(KikiGear(KikiFace.NY), KikiPos(s.x/2-2, 1, s.z/2-1))
world.addObjectLine("KikiWire (KikiFace.NY, KikiWire.VERTICAL)", KikiPos(s.x/2+2, s.y-1, 0), KikiPos(s.x/2+2, s.y-1, s.z))
world.addObjectLine("KikiWire (KikiFace.PY, KikiWire.VERTICAL)", KikiPos(s.x/2+2, 0, 0), KikiPos(s.x/2+2, 0, s.z))
world.addObjectLine("KikiWire (KikiFace.PZ, KikiWire.VERTICAL)", KikiPos(s.x/2+2, 0, 0), KikiPos(s.x/2+2, s.y, 0))
world.addObjectLine("KikiWire (KikiFace.NZ, KikiWire.VERTICAL)", KikiPos(s.x/2+2, 0, s.z-1), KikiPos(s.x/2+2, s.y, s.z-1))
world.addObjectAtPos(KikiBomb(), KikiPos(s.x/2+2, 0, s.z/2-1))
world.addObjectAtPos(KikiBomb(), KikiPos(s.x/2+1, 0, s.z/2+1))
world.addObjectAtPos(KikiBomb(), KikiPos(s.x/2, 0, s.z/2-1))
world.addObjectAtPos(KikiBomb(), KikiPos(s.x/2-1, 0, s.z/2+1))
world.addObjectAtPos(KikiBomb(), KikiPos(s.x/2-2, 0, s.z/2-1))

87
levels/energy.coffee Normal file
View File

@ -0,0 +1,87 @@
module.exports =
name: "energy"
scheme: "default_scheme"
size: [9,17,9]
intro: "energy"
help: """
$scale(1.5)mission:
activate the exit!
to activate the exit,
shoot the 4 switches
"""
player:
position: [0,1,0]
orientation: roty90
exits: [
name: "exit"
active: 0
position: [0,0,0]
],
create: ->
s = world.getSize()
world.addObjectLine(KikiWall, [0, s.y/2, s.z/2], [s.x, s.y/2, s.z/2])
world.addObjectLine(KikiWall, [s.x/2, s.y/2, 0], [s.x/2, s.y/2, s.z])
world.deleteObject(world.getOccupantAtPos(world.decenter(0,0,0)))
world.addObjectAtPos(KikiWall(), world.decenter(0, 3, 0))
world.addObjectAtPos(KikiWall(), world.decenter(0, 6, 0))
world.addObjectAtPos(KikiWall(), world.decenter(0, -4, 0))
world.addObjectAtPos(KikiWall(), world.decenter( 2,-5, 1))
world.addObjectAtPos(KikiWall(), world.decenter(-1,-5, 2))
world.addObjectAtPos(KikiWall(), world.decenter(-2,-5,-1))
world.addObjectAtPos(KikiWall(), world.decenter( 1,-5,-2))
world.addObjectAtPos(KikiMutant(), world.decenter( 2,-5, 2))
world.addObjectAtPos(KikiMutant(), world.decenter(-2,-5,-2))
world.addObjectAtPos(KikiMutant(), world.decenter( 1,-5, 1))
world.addObjectAtPos(KikiMutant(), world.decenter(-1,-5,-1))
world.addObjectAtPos(KikiMutant(), world.decenter( 2,-5,-2))
world.addObjectAtPos(KikiMutant(), world.decenter(-2,-5, 2))
world.addObjectAtPos(KikiMutant(), world.decenter( 1,-5,-1))
world.addObjectAtPos(KikiMutant(), world.decenter(-1,-5, 1))
world.addObjectAtPos(KikiWall(), world.decenter( 0, 3, s.z/2))
world.addObjectAtPos(KikiWall(), world.decenter( 0, 5, s.z/2))
world.addObjectAtPos(KikiWall(), world.decenter( 1, 4, s.z/2))
world.addObjectAtPos(KikiWall(), world.decenter(-1, 4, s.z/2))
world.addObjectAtPos(KikiWall(), world.decenter(s.x/2, 3, 0))
world.addObjectAtPos(KikiWall(), world.decenter(s.x/2, 5, 0))
world.addObjectAtPos(KikiWall(), world.decenter(s.x/2, 4, 1))
world.addObjectAtPos(KikiWall(), world.decenter(s.x/2, 4, -1))
world.addObjectAtPos(KikiWall(), world.decenter( 0, 3, -s.z/2+1))
world.addObjectAtPos(KikiWall(), world.decenter( 0, 5, -s.z/2+1))
world.addObjectAtPos(KikiWall(), world.decenter( 1, 4, -s.z/2+1))
world.addObjectAtPos(KikiWall(), world.decenter(-1, 4, -s.z/2+1))
world.addObjectAtPos(KikiWall(), world.decenter(-s.x/2+1, 3, 0))
world.addObjectAtPos(KikiWall(), world.decenter(-s.x/2+1, 5, 0))
world.addObjectAtPos(KikiWall(), world.decenter(-s.x/2+1, 4, 1))
world.addObjectAtPos(KikiWall(), world.decenter(-s.x/2+1, 4, -1))
world.switch_counter = 0
switched = (switch) ->
world.switch_counter += switch.isActive() and 1 or -1
exit = kikiObjectToGate (world.getObjectWithName("exit"))
exit.setActive(world.switch_counter == 4)
switch1 = KikiSwitch()
switch1.getEventWithName("switched").addAction(continuous(()-> sw=switch1: switched(sw)))
switch2 = KikiSwitch()
switch2.getEventWithName("switched").addAction(continuous(()-> sw=switch2: switched(sw)))
switch3 = KikiSwitch()
switch3.getEventWithName("switched").addAction(continuous(()-> sw=switch3: switched(sw)))
switch4 = KikiSwitch()
switch4.getEventWithName("switched").addAction(continuous(()-> sw=switch4: switched(sw)))
world.addObjectAtPos(switch1, world.decenter(-s.x/2+1, 4, 0))
world.addObjectAtPos(switch2, world.decenter( s.x/2, 4, 0))
world.addObjectAtPos(switch3, world.decenter(0, 4, -s.z/2+1))
world.addObjectAtPos(switch4, world.decenter(0, 4, s.z/2))

29
levels/entropy.coffee Normal file
View File

@ -0,0 +1,29 @@
# level design by Michael Abel
module.exports =
name: "entropy"
scheme: "green_scheme"
size: [9,9,9]
intro: "entropy"
help: """
$scale(1.5)mission:
get to the exit!
use the stones to reach it
"""
player:
coordinates: [4,3,4]
nostatus: 0
exits: [
name: "exit"
active: 1
position: [0,0,0]
]
create: ->
s=world.getSize()
d=2
for (i,j,l) in [ (m,n,o) for m in range(s.x) for n in range(s.y) for o in range(s.z)]
if (-1)**(i+j+l) ==1 and not ( d<=i<=s.x-d-1 and d<=j<=s.y-d-1 and d<=l<=s.z-d-1 )
world.addObjectAtPos(KikiStone(KColor(0,0.8,0.2,0.8), true), KikiPos(i,j,l))

65
levels/escape.coffee Normal file
View File

@ -0,0 +1,65 @@
module.exports =
name: "escape"
scheme: "metal_scheme"
size: [7,9,7]
intro: "escape"
help: """
$scale(1.5)mission:
try to escape!
to escape,
activate the exit
to activate the exit,
shoot the switch
to be able to
shoot the switch,
move the stones
"""
player:
position: [0,0,0]
orientation: rotx180
exits: [
name: "exit"
active: 0
position: [0,-3,0]
]
create: ->
#
s = world.getSize()
exit_switch = KikiSwitch()
exit_switch.getEventWithName("switched").addAction(continuous(()-> : world.toggle("exit")))
world.addObjectAtPos(exit_switch, world.decenter( 0, -2, 0))
world.addObjectAtPos(KikiStone(), world.decenter( 0, s.y/2, 0))
world.addObjectAtPos(KikiStone(), world.decenter( 1, s.y/2, 0))
world.addObjectAtPos(KikiStone(), world.decenter( 0, s.y/2, 1))
world.addObjectAtPos(KikiStone(), world.decenter( 0, s.y/2,-1))
world.addObjectAtPos(KikiStone(), world.decenter(-1, s.y/2, 0))
world.addObjectLine(KikiStone, world.decenter(-2, s.y/2,-2), world.decenter( 2, s.y/2,-2))
world.addObjectLine(KikiStone, world.decenter( 2, s.y/2,-2), world.decenter( 2, s.y/2, 2))
world.addObjectLine(KikiStone, world.decenter( 2, s.y/2, 2), world.decenter(-2, s.y/2, 2))
world.addObjectLine(KikiStone, world.decenter(-2, s.y/2, 2), world.decenter(-2, s.y/2,-2))
world.addObjectAtPos(KikiWall(), world.decenter( 1, 0, 0))
world.addObjectAtPos(KikiWall(), world.decenter( 0, 0, 1))
world.addObjectAtPos(KikiWall(), world.decenter(-1, 0, 0))
world.addObjectAtPos(KikiWall(), world.decenter( 0, 0,-1))
world.addObjectAtPos(KikiWall(), world.decenter( 1,-1, 0))
world.addObjectAtPos(KikiWall(), world.decenter( 0,-1, 1))
world.addObjectAtPos(KikiWall(), world.decenter(-1,-1, 0))
world.addObjectAtPos(KikiWall(), world.decenter( 0,-1,-1))
world.addObjectAtPos(KikiWall(), world.decenter( 1,-1, 1))
world.addObjectAtPos(KikiWall(), world.decenter(-1,-1, 1))
world.addObjectAtPos(KikiWall(), world.decenter(-1,-1,-1))
world.addObjectAtPos(KikiWall(), world.decenter( 1,-1,-1))
world.addObjectAtPos(KikiWall(), world.decenter( 1,-2, 0))
world.addObjectAtPos(KikiWall(), world.decenter( 0,-2, 1))
world.addObjectAtPos(KikiWall(), world.decenter(-1,-2, 0))
world.addObjectAtPos(KikiWall(), world.decenter( 0,-2,-1))

69
levels/evil.coffee Normal file
View File

@ -0,0 +1,69 @@
module.exports =
name: "evil"
scheme: "red_scheme"
size: [13,5,13]
intro: "evil"
help: """
$scale(1.5)mission:
activate the exit!
place a powered
wire stone next to it.
a wirestone is powered by
a rotating generator
or it shares at least
one edge with
another powered wirestone.
this one is hard,
really hard,
but it's possible.
good luck!
"""
player: position: [1,1,1]
exits: [
name: "exit"
active: 0
position: [0,0,4]
],
create: ->
sx, sy, sz = 13,5,13
for z in range(-sz/2+2, sz/2)
world.addObjectAtPos(KikiWall(), world.decenter(-sx/2+2, 0, z))
world.addObjectAtPos(KikiWall(), world.decenter( sx/2-1, 0, z))
for z in range(-sz/2+4, sz/2-2)
world.addObjectAtPos(KikiWall(), world.decenter(-sx/2+4, 0, z))
world.addObjectAtPos(KikiWall(), world.decenter( sx/2-3, 0, z))
for x in range(-sx/2+3, sx/2-1)
world.addObjectAtPos(KikiWall(), world.decenter(x, 0, -sz/2+2))
world.addObjectAtPos(KikiWall(), world.decenter(x, 0, sz/2-1))
for x in range(-sx/2+4, sx/2-2)
world.addObjectAtPos(KikiWall(), world.decenter(x, 0, -sz/2+4))
world.addObjectAtPos(KikiWall(), world.decenter(x, 0, sz/2-3))
world.addObjectAtPos(KikiGenerator(KikiFace.PY), world.decenter(0,0,-4))
world.addObjectAtPos(KikiWireStone(), world.decenter(4,0,0))
world.addObjectAtPos(KikiWireStone(), world.decenter(-4,0,0))
world.addObjectAtPos(KikiWireStone(), world.decenter(0,-2,-2))
world.addObjectAtPos(KikiWireStone(), world.decenter(0,-1,-2))
world.addObjectAtPos(KikiMotorGear(KikiFace.PY), world.decenter(0,0,-2))
world.addObjectAtPos(KikiMotorCylinder(KikiFace.PY), world.decenter(0,1,-2))
world.addObjectAtPos(KikiBomb(), world.decenter(0, 2,-2))
world.addObjectAtPos(KikiBomb(), world.decenter( 1, 0,-2))
world.addObjectAtPos(KikiBomb(), world.decenter(-1, 0,-2))
world.removeObject(world.getOccupantAtPos(world.decenter(0, 0, 3)))
world.addObjectAtPos(KikiWireStone(), world.decenter(0,0,3))

62
levels/fallen.coffee Normal file
View File

@ -0,0 +1,62 @@
# level design by Owen Hay
module.exports =
name: "fallen"
scheme: "blue_scheme"
size: [13,15,13]
intro: "fallen"
help: """
$scale(1.5)mission:
get to the exit!
to get to the exit,
jump and fall off the stones
try to jump so that you
land on other stones
if you fall, there is a stone
on ground to help get back on
you have to fall of this stone, as well
"""
player:
coordinates: [6,11,6]
nostatus: 0
exits: [
name: "exit"
active: 1
position: [-4, 1,-3]
,
name: "exit"
active: 1
position: [0, -1, 0]
]
create: ->
s = world.getSize ()
#hop back on
world.addObjectAtPos(KikiWall(), KikiPos(2, 12, 12))
#orient world
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2, s.y/2+2, s.z/2))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2+2, s.y/2+2, s.z/2))
#some Hops
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2+2, s.y/2-2, s.z/2+2))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2+2, s.y/2-2, s.z/2+4))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2, s.y/2-2, s.z/2+4))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2+2, s.y/2-2, s.z/2+4))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2, s.y/2-4, s.z/2+4))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2-2, s.y/2-4, s.z/2+4))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2-4, s.y/2-4, s.z/2+4))
#long fall and strip1
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2-4, s.y/2+4, s.z/2+2))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2-3, s.y/2+4, s.z/2+2))
#short fall and strip2
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2-4, s.y/2+1, s.z/2-2))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2-4, s.y/2+1, s.z/2-1))
world.addObjectAtPos(KikiStone(), KikiPos(0, 0, 0))

36
levels/flower.coffee Normal file
View File

@ -0,0 +1,36 @@
# level design by Michael Abel
module.exports =
name: "flower"
scheme: "metal_scheme"
size: [7,7,11]
intro: "flower"
help: """
$scale(1.5)mission:
get to the exit!
the green stone is slicky
you can't grab it while falling
"""
player:
coordinates: [3,0,1]
nostatus: 0
orientation: roty0
exits: [
name: "exit"
active: 1
position: [0,0,0]
]
create: ->
s=world.getSize()
for m in [ [1,KikiWall], [2,KikiStone] ]
for (k,l) in [[i,j] for i in [-1*m[0],1*m[0]] for j in [-1*m[0],1*m[0]]]
world.addObjectLine(m[1], KikiPos(s.x/2+k, s.y/2+l ,0), KikiPos(s.x/2+k, s.y/2+l ,3))
world.addObjectLine(m[1], KikiPos(s.x/2+k, s.y/2+l ,8), KikiPos(s.x/2+k, s.y/2+l ,s.z))
world.addObjectAtPos(KikiStone(KColor(0,1,0,0.5), true), world.decenter(1,0,0))
world.addObjectAtPos(KikiStone(KColor(0,1,0,0.5), true), world.decenter(-1,0,0))
world.addObjectAtPos(KikiStone(KColor(0,1,0,0.5), true), world.decenter(0,1,0))
world.addObjectAtPos(KikiStone(KColor(0,1,0,0.5), true), world.decenter(0,-1,0))

76
levels/gamma.coffee Normal file
View File

@ -0,0 +1,76 @@
# level design by Michael Abel
schemes=[test_scheme, tron_scheme,candy_scheme, default_scheme,
green_scheme, yellow_scheme, blue_scheme, red_scheme, metal_scheme, bronze_scheme]
module.exports =
name: "gamma"
scheme: "tron_scheme"
size: [10,10,10]
intro: "gamma"
help: """
$scale(1.5)mission:
activate the exit!
shoot at the 3 switches to activate the exit
"""
player:
coordinates: [0,5,0]
nostatus: 0
exits: [
name: "exit"
active: 0
coordinates: [2,7,4] #absolute coord
]
create: ->
s = world.getSize()
world.switch_countera = 0
world.switch_counter = 0
aswitched = () ->
applyColorScheme (schemes[world.switch_countera])
if world.switch_countera==schemes.length-1
world.switch_countera=0
else
world.switch_countera+=1
switched = (switch) ->
world.switch_counter += switch.isActive() and 1 or -1
exit = kikiObjectToGate(world.getObjectWithName("exit"))
exit.setActive(world.switch_counter == 4)
aswitch = KikiSwitch()
bswitch = KikiSwitch()
cswitch = KikiSwitch()
dswitch = KikiSwitch()
eswitch = KikiSwitch()
aswitch.getEventWithName("switched").addAction(continuous( aswitched ))
bswitch.getEventWithName("switched").addAction(continuous(()-> s= bswitch : switched(s) ))
cswitch.getEventWithName("switched").addAction(continuous(()-> s= cswitch : switched(s) ))
dswitch.getEventWithName("switched").addAction(continuous(()-> s= dswitch : switched(s) ))
eswitch.getEventWithName("switched").addAction(continuous(()-> s= eswitch : switched(s) ))
world.addObjectAtPos(aswitch , KikiPos (s.x-1,0,0))
world.addObjectAtPos(bswitch , KikiPos (0,0,0))
world.addObjectAtPos(KikiMutant() , KikiPos (s.x/2,0,0))
world.addObjectLine(KikiWall, KikiPos(0,0,1), KikiPos(s.x,0,1))
world.addObjectLine(KikiWall, KikiPos(0,1,0), KikiPos(s.x,1,0))
world.addObjectLine(KikiWall, KikiPos(0,2,2), KikiPos(s.x-3,2,2))
world.addObjectAtPos(KikiSwitch() , KikiPos (s.x-3,2,2))
world.addObjectLine(KikiWall, KikiPos(2,2,2), KikiPos(2,2,s.z-3))
world.addObjectAtPos(KikiSwitch() , KikiPos (2,2,s.z-3))
world.addObjectLine(KikiWall, KikiPos(2,2,4), KikiPos(2,s.y-3,4))
#exit
world.addObjectAtPos(KikiSwitch() , KikiPos (2,s.y-3,4))
world.addObjectLine(KikiWall, KikiPos(2,4,4), KikiPos(s.x-4,4,4))
world.addObjectAtPos(cswitch , KikiPos (s.x-3,4,4))
world.addObjectLine(KikiWall, KikiPos(4,4,4), KikiPos(4,4,s.z-4))
world.addObjectAtPos(dswitch , KikiPos (4,4,s.z-3))
world.addObjectLine(KikiWall, KikiPos(4,4,6), KikiPos(4,s.y-4,6))
world.addObjectAtPos(eswitch , KikiPos (4,s.y-3,6))

60
levels/gears.coffee Normal file
View File

@ -0,0 +1,60 @@
module.exports =
name: "gears"
scheme: "blue_scheme"
size: [9,9,9]
intro: "gears"
help: """
$scale(1.5)mission:
activate the exit!
to activate the exit
feed it with electricity:
connect the generator
with the motor
and close the circuit
with the wire stones
"""
player: position: [0,0,0]
exits: [
name: "exit"
active: 0
position: [0,4,0]
]
create: ->
s = world.getSize()
world.addObjectAtPos(KikiWireStone(), world.decenter(-1, 0, 0))
world.addObjectAtPos(KikiWireStone(), world.decenter( 1, 0, 0))
world.addObjectAtPos(KikiWireStone(), world.decenter( 0,-1, 0))
world.addObjectAtPos(KikiWireStone(), world.decenter( 0, 1, 0))
world.addObjectAtPos(KikiWireStone(), world.decenter( 0, 0,-1))
world.addObjectAtPos(KikiWireStone(), world.decenter( 0, 0, 1))
world.addObjectAtPos(KikiGear(KikiFace.PY), KikiPos(s.x/2-1, 0, s.z/2-1))
world.addObjectAtPos(KikiGear(KikiFace.PY), KikiPos(s.x/2+1, 0, s.z/2-1))
world.addObjectAtPos(KikiGear(KikiFace.PY), KikiPos(s.x/2-1, 0, s.z/2+1))
d = 3
world.addObjectAtPos(KikiGenerator(KikiFace.PY), KikiPos(s.x/2+1, 0, s.z/2+1))
world.addObjectAtPos(KikiMotorCylinder(KikiFace.PY), KikiPos(s.x/2, 1, s.z/2))
world.addObjectAtPos(KikiMotorGear(KikiFace.PY), KikiPos(s.x/2, 0, s.z/2))
# floor wire square
world.addObjectLine("KikiWire(KikiFace.PY, 10)", KikiPos(s.x/2-d+1, 0, s.z/2-d), KikiPos(s.x/2+d, 0, s.z/2-d))
world.addObjectLine("KikiWire(KikiFace.PY, 10)", KikiPos(s.x/2-d+1, 0, s.z/2+d), KikiPos(s.x/2+d, 0, s.z/2+d))
world.addObjectLine("KikiWire(KikiFace.PY, 5)", KikiPos(s.x/2-d, 0, s.z/2-d+1), KikiPos(s.x/2-d, 0, s.z/2+d))
world.addObjectLine("KikiWire(KikiFace.PY, 5)", KikiPos(s.x/2+d, 0, s.z/2-d+1), KikiPos(s.x/2+d, 0, s.z/2+d))
# corners of wire square
world.addObjectAtPos(KikiWire(KikiFace.PY, 6), KikiPos(s.x/2-d, 0, s.z/2-d))
world.addObjectAtPos(KikiWire(KikiFace.PY, 3), KikiPos(s.x/2-d, 0, s.z/2+d))
world.addObjectAtPos(KikiWire(KikiFace.PY, 9), KikiPos(s.x/2+d, 0, s.z/2+d))
world.addObjectAtPos(KikiWire(KikiFace.PY, 12), KikiPos(s.x/2+d, 0, s.z/2-d))
world.addObjectAtPos(KikiWire(KikiFace.PX, 1), KikiPos(0, 0, s.z/2))
world.addObjectAtPos(KikiWire(KikiFace.NX, 1), KikiPos(s.x-1, 0, s.z/2))
world.addObjectLine("KikiWire(KikiFace.PX, 5)", KikiPos( 0, 1, s.z/2), KikiPos( 0, s.y, s.z/2))
world.addObjectLine("KikiWire(KikiFace.NX, 5)", KikiPos(s.x-1, 1, s.z/2), KikiPos(s.x-1, s.y, s.z/2))
world.addObjectLine("KikiWire(KikiFace.NY, 10)", KikiPos(0, s.y-1, s.z/2), KikiPos(s.x, s.y-1, s.z/2))

24
levels/gold.coffee Normal file
View File

@ -0,0 +1,24 @@
module.exports =
name: "gold"
scheme: "yellow_scheme"
size: [3,11,3]
intro: "gold"
help: """
$scale(1.5)mission:
get to the exit!
move the stones to reach it
"""
player:
position: [0,-4,0]
exits: [
name: "exit"
active: 1
position: [0,4,0]
]
create: ->
s = world.getSize()
for y in range(-s.y/2+3, s.y/2, 2)
for x in range(-s.x/2+1, s.x/2+1)
for z in range(-s.z/2+1, s.z/2+1)
world.addObjectAtPos(KikiStone(), world.decenter(x, y, z))

45
levels/grasp.coffee Normal file
View File

@ -0,0 +1,45 @@
# level design by Owen Hay
module.exports =
name: "grasp"
scheme: "blue_scheme"
intro: "grasp"
size: [11,11,11]
help: """
$scale(1.5)mission:activate the exit!
to shoot, press $key(shoot)
"""
player:
coordinates: [3,0,3]
nostatus: 0
exits: [
name: "exit"
active: 0
position: [0,0,0]
]
create: ->
s = world.getSize()
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2-1, s.y/2+1, 0))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2+1, s.y/2+1, 0))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2+1, s.y/2-1, 0))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2-1, s.y/2-1, 0))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2-1, s.y/2, 0))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2+1, s.y/2, 0))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2, s.y/2-1, 0))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2, s.y/2+1, 0))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2, s.y/2, 1))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2+1, s.y/2, 2))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2-1, s.y/2, 2))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2+2, s.y/2, 1))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2-2, s.y/2, 1))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2+2, s.y/2, 4))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2-2, s.y/2, 4))
exit_switch = KikiSwitch()
exit_switch.getEventWithName("switched").addAction(continuous(()-> : world.toggle("exit")))
world.addObjectAtPos(exit_switch, KikiPos(s.x/2, s.y/2, 0))

65
levels/green.coffee Normal file
View File

@ -0,0 +1,65 @@
module.exports =
name: "green"
scheme: "green_scheme"
size: [13,5,13]
intro: "green"
help: """
$scale(1.5)mission:
activate the exit!
place a powered
wire stone next to it.
a wirestone is powered by
a rotating generator
or it shares at least one edge with
another powered wirestone.
this one is hard, really hard, but it's possible.
good luck!
"""
player: position: [1,1,1]
exits: [
name: "exit"
active: 0
position: [0,0,4]
]
create: ->
#
sx, sy, sz = 13,5,13
for z in range(-sz/2+2, sz/2)
world.addObjectAtPos(KikiWall(), world.decenter(-sx/2+2, 0, z))
world.addObjectAtPos(KikiWall(), world.decenter( sx/2-1, 0, z))
for z in range(-sz/2+4, sz/2-2)
world.addObjectAtPos(KikiWall(), world.decenter(-sx/2+4, 0, z))
world.addObjectAtPos(KikiWall(), world.decenter( sx/2-3, 0, z))
for x in range(-sx/2+3, sx/2-1)
world.addObjectAtPos(KikiWall(), world.decenter(x, 0, -sz/2+2))
world.addObjectAtPos(KikiWall(), world.decenter(x, 0, sz/2-1))
for x in range(-sx/2+4, sx/2-2)
world.addObjectAtPos(KikiWall(), world.decenter(x, 0, -sz/2+4))
world.addObjectAtPos(KikiWall(), world.decenter(x, 0, sz/2-3))
world.addObjectAtPos(KikiWireStone(), world.decenter(0,-1,0))
world.addObjectAtPos(KikiMotorGear(KikiFace.PY), world.decenter(0,0,0))
world.addObjectAtPos(KikiMotorCylinder(KikiFace.PY), world.decenter(0,1,0))
world.addObjectAtPos(KikiGenerator(KikiFace.PY), world.decenter(0,0,-4))
world.addObjectAtPos(KikiWireStone(), world.decenter(4,0,0))
world.addObjectAtPos(KikiWireStone(), world.decenter(-4,0,0))
world.addObjectAtPos(KikiWireStone(), world.decenter(0,-2,0))
world.addObjectAtPos(KikiBomb(), world.decenter(0, 2,0))
world.addObjectAtPos(KikiBomb(), world.decenter( 1, 0,0))
world.addObjectAtPos(KikiBomb(), world.decenter(-1, 0,0))
world.removeObject(world.getOccupantAtPos(world.decenter(0, 0, 3)))
world.addObjectAtPos(KikiWireStone(), world.decenter(0,0,3))

37
levels/grid.coffee Normal file
View File

@ -0,0 +1,37 @@
module.exports =
name: "grid"
scheme: "candy_scheme"
size: [9,9,9]
intro: "grid"
help: """
$scale(1.5)mission:
get to the exit!
to get to the exit,
use the stones
"""
player: position: [1,0,1]
exits: [
name: "exit"
active: 1
position: [0,0,0]
]
create: ->
#
s = world.getSize()
for y in [-1, 1]
for x in range(-s.x/2+3, s.x/2-1, 2)
for z in range(-s.z/2+3, s.z/2-1, 2)
world.addObjectAtPos(KikiWall (), world.decenter(x, y, z))
for y in [-4, 4]
for x in range(-s.x/2+1, s.x/2+1, 2)
for z in range(-s.z/2+1, s.z/2+1, 2)
world.addObjectAtPos(KikiWall (), world.decenter(x, y, z))
world.addObjectAtPos(KikiStone (), world.decenter(3,-3,0))
world.addObjectAtPos(KikiStone (), world.decenter(-3,-3,0))
world.addObjectAtPos(KikiStone (), world.decenter(3,3,0))
world.addObjectAtPos(KikiStone (), world.decenter(-3,3,0))
world.addObjectAtPos(KikiStone (), world.decenter(0,-3,0))
world.addObjectAtPos(KikiStone (), world.decenter(0,3,0))

75
levels/hidden.coffee Normal file
View File

@ -0,0 +1,75 @@
module.exports =
name: "hidden"
scheme: "metal_scheme"
size: [9,9,9]
intro: "hidden"
help: """
$scale(1.5)mission:
activate the exit!
to activate the exit,
activate the 5 switches
use the stones to
reach the exit
"""
player: position: [0,-3,1]
exits: [
name: "exit"
active: 0
position: [0,0,0]
],
create: ->
s = world.getSize()
world.addObjectAtPos(KikiStone(), KikiPos(0,0,1))
world.addObjectAtPos(KikiStone(), KikiPos(0,1,0))
world.addObjectAtPos(KikiStone(), KikiPos(1,0,1))
world.addObjectAtPos(KikiStone(), KikiPos(1,1,0))
world.addObjectAtPos(KikiStone(), KikiPos(2,0,0))
switch1 = KikiSwitch()
world.addObjectAtPos(switch1, KikiPos(1,0,0))
world.addObjectAtPos(KikiStone(), KikiPos(s.x-1,0,1))
world.addObjectAtPos(KikiStone(), KikiPos(s.x-1,1,0))
world.addObjectAtPos(KikiStone(), KikiPos(s.x-2,0,1))
world.addObjectAtPos(KikiStone(), KikiPos(s.x-2,1,0))
world.addObjectAtPos(KikiStone(), KikiPos(s.x-3,0,0))
switch2 = KikiSwitch()
world.addObjectAtPos(switch2, KikiPos(s.x-2,0,0))
world.addObjectAtPos(KikiStone(), KikiPos(0,0,s.z-2))
world.addObjectAtPos(KikiStone(), KikiPos(0,1,s.z-1))
world.addObjectAtPos(KikiStone(), KikiPos(1,0,s.z-2))
world.addObjectAtPos(KikiStone(), KikiPos(1,1,s.z-1))
world.addObjectAtPos(KikiStone(), KikiPos(2,0,s.z-1))
switch3 = KikiSwitch()
world.addObjectAtPos(switch3, KikiPos(1,0,s.z-1))
world.addObjectAtPos(KikiStone(), KikiPos(s.x-1,0,s.z-2))
world.addObjectAtPos(KikiStone(), KikiPos(s.x-1,1,s.z-1))
world.addObjectAtPos(KikiStone(), KikiPos(s.x-2,0,s.z-2))
world.addObjectAtPos(KikiStone(), KikiPos(s.x-2,1,s.z-1))
world.addObjectAtPos(KikiStone(), KikiPos(s.x-3,0,s.z-1))
switch4 = KikiSwitch()
world.addObjectAtPos(switch4, KikiPos(s.x-2,0,s.z-1))
world.addObjectPoly(KikiStone, [KikiPos(s.x/2-1,s.y-1,s.z/2-1), KikiPos(s.x/2-1,s.y-1,s.z/2+1), \
KikiPos(s.x/2+1,s.y-1,s.z/2+1), KikiPos(s.x/2+1,s.y-1,s.z/2-1)])
switch5 = KikiSwitch()
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2,s.y-2,s.z/2))
world.addObjectAtPos(switch5, KikiPos(s.x/2,s.y-1,s.z/2))
world.switch_counter = 0
switched = (switch) ->
world.switch_counter += switch.isActive() and 1 or -1
exit = kikiObjectToGate(world.getObjectWithName("exit"))
exit.setActive(world.switch_counter == 5)
switch1.getEventWithName("switched").addAction(continuous(()-> s=switch1: switched(s)))
switch2.getEventWithName("switched").addAction(continuous(()-> s=switch2: switched(s)))
switch3.getEventWithName("switched").addAction(continuous(()-> s=switch3: switched(s)))
switch4.getEventWithName("switched").addAction(continuous(()-> s=switch4: switched(s)))
switch5.getEventWithName("switched").addAction(continuous(()-> s=switch5: switched(s)))

129
levels/invisimaze.coffee Normal file
View File

@ -0,0 +1,129 @@
# level design by Owen Hay
module.exports =
name: "invisimaze"
scheme: "yellow_scheme"
size: [9,5,5]
intro: "invisimaze"
help: """
blindly fumbling through the maze
the switches move every time you play
there is only one way out!
"""
player: position: [0,1,0]
exits: [
name: "exit1"
active: 0
position: [-4,0,0]
,
name: "exit2"
active: 0
position: [4,0,0]
world: () -> outro()
]
create: ->
s = world.getSize()
def switched(switch):
world.switch_counter += switch.isActive() and 1 or -1
exit = kikiObjectToGate(world.getObjectWithName("exit"))
exit.setActive(world.switch_counter == 5)
def switchBoth():
world.toggle("exit1")
world.toggle("exit2")
#randomly assign the switches to different locations
tup_array = [(0,0,0),( 2, 1, -2),( -2, -2, 0),( -1, 2, 1),( -2, -2, -1),( 1, -1,2),]
random.shuffle(tup_array)
i0 = tup_array[0]
i1 = tup_array[1]
i2 = tup_array[2]
i3 = tup_array[3]
i4 = tup_array[4]
i5 = tup_array[5]
exit_switch = KikiSwitch()
exit_switch.getEventWithName("switched").addAction(continuous(()-> : switchBoth()))
world.addObjectAtPos(exit_switch, world.decenter(i0) )
exit2_switch = KikiSwitch()
exit2_switch.getEventWithName("switched").addAction(continuous(()-> : world.toggle("exit2")))
world.addObjectAtPos(exit2_switch, world.decenter(i1))
exit3_switch = KikiSwitch()
exit3_switch.getEventWithName("switched").addAction(continuous(()-> : world.toggle("exit1")))
world.addObjectAtPos(exit3_switch, world.decenter(i2))
exit4_switch = KikiSwitch()
exit4_switch.getEventWithName("switched").addAction(continuous(()-> : world.toggle("exit1")))
world.addObjectAtPos(exit4_switch, world.decenter(i3))
exit5_switch = KikiSwitch()
exit5_switch.getEventWithName("switched").addAction(continuous(()-> : world.toggle("exit1")))
world.addObjectAtPos(exit5_switch, world.decenter(i4))
# Invisimaze
for y in [0, 1, ]:
world.addObjectLine(KikiStone, KikiPos(4, y, 2), KikiPos(4, y, 5))
world.addObjectLine(KikiStone, KikiPos(5, y, 2), KikiPos(7, y, 2))
for y in [0,]:
for x in [2]:
world.addObjectPoly(KikiStone, [world.decenter(-2, 0, -2), world.decenter(-2, 0, 2), \
world.decenter(2, 0, 2), world.decenter(2, 0, -2)])
world.addObjectPoly(KikiStone, [KikiPos(2, 4, 2), KikiPos(2, 4, 4), \
KikiPos(4, 4, 4), KikiPos(4, 4, 2)])
world.addObjectAtPos(KikiStone(), KikiPos(2, 3, 2))
world.addObjectAtPos(KikiStone(), KikiPos(6, 3, 1))
world.addObjectAtPos(KikiStone(), KikiPos(6, 3, 3))
world.addObjectAtPos(KikiStone(), KikiPos(2, 1, 1))
world.addObjectAtPos(KikiStone(), KikiPos(3, 0, 1))
world.addObjectAtPos(KikiStone(), KikiPos(2, 1, 2))
world.addObjectAtPos(KikiStone(), KikiPos(2, 0, 2))
world.addObjectAtPos(KikiStone(), KikiPos(4, 2, 3))
world.addObjectAtPos(KikiStone(), KikiPos(5, 2, 2))
world.addObjectAtPos(KikiStone(), KikiPos(5, 2, 1))
world.addObjectAtPos(KikiStone(), KikiPos(4, 2, 1))
world.addObjectAtPos(KikiStone(), KikiPos(3, 2, 2))
world.addObjectAtPos(KikiStone(), KikiPos(3, 2, 3))
world.addObjectAtPos(KikiStone(), KikiPos(5, 3, 0))
world.addObjectAtPos(KikiStone(), KikiPos(6, 4, 0))
#the bombLock
world.addObjectAtPos(KikiStone(), KikiPos(7, 1, 2))
world.addObjectAtPos(KikiStone(), KikiPos(7, 1, 3))
world.addObjectAtPos(KikiStone(), KikiPos(7, 3, 2))
world.addObjectAtPos(KikiStone(), KikiPos(7, 2, 1))
world.addObjectAtPos(KikiStone(), KikiPos(7, 2, 2))
world.addObjectAtPos(KikiBomb(), KikiPos(7, 2, 2))
# Exit 1 is blocked!!!
world.addObjectAtPos(KikiMotorCylinder(), KikiPos(1, 2, 2))
# Walls
for y in [-4,]:
for x in [1, -1]:
world.addObjectPoly(KikiWall, [world.decenter(y, -x, -x), world.decenter(y, -x, x), \
world.decenter(y, x, x), world.decenter(y, x, -x)])
for y in [-3]:
for x in [2, -2]:
world.addObjectPoly(KikiWall, [world.decenter(y, -x, -x), world.decenter(y, -x, x), \
world.decenter(y, x, x), world.decenter(y, x, -x)])
for y in [4,]:
for x in [1, -1]:
world.addObjectPoly(KikiWall, [world.decenter(y, -x, -x), world.decenter(y, -x, x), \
world.decenter(y, x, x), world.decenter(y, x, -x)])
for y in [3]:
for x in [2, -2]:
world.addObjectPoly(KikiWall, [world.decenter(y, -x, -x), world.decenter(y, -x, x), \
world.decenter(y, x, x), world.decenter(y, x, -x)])

31
levels/jump.coffee Normal file
View File

@ -0,0 +1,31 @@
module.exports =
name: "jump"
scheme: "red_scheme"
size: [7,7,13]
intro: "jump"
help: """
$scale"""1.5)mission:
get to the exit!
jump on the stones to reach it
you can attach to a stone when falling by
if you move into its direction
"""
player: position: [0,0,5]
exits: [
name: "exit"
active: 1
position: [0,0,4]
]
create: ->
s = world.getSize()
world.addObjectAtPos(KikiWall(), world.decenter(0,0,1 - s.z/2))
world.addObjectAtPos(KikiWall(), world.decenter(0,0,3 - s.z/2))
world.addObjectAtPos(KikiWall(), world.decenter(0,0,6 - s.z/2))
world.addObjectAtPos(KikiWall(), world.decenter(0,1,10 - s.z/2))
world.addObjectAtPos(KikiWall(), world.decenter(1,0,10 - s.z/2))
world.addObjectAtPos(KikiWall(), world.decenter(-1,0,10 - s.z/2))
world.addObjectAtPos(KikiWall(), world.decenter(0,-1,10 - s.z/2))

23
levels/love.coffee Normal file
View File

@ -0,0 +1,23 @@
module.exports =
name: "love"
scheme: "red_scheme"
size: [13,13,13]
intro: "love"
help: "$scale(1.5)mission:\nget to the exit!"
player:
position: [0,1,-4]
orientation: rot0
exits: [
name: "peace"
active: 1
position: [0,0,4]
]
create: ->
heart = [[0,0], [ 1,1], [ 2,1], [ 3,0], [ 3,-1], [ 2,-2], [ 1,-3], [0,-4],
[-1,1], [-2,1], [-3,0], [-3,-1], [-2,-2], [-1,-3]]
for h in heart
world.addObjectAtPos(KikiBomb(), world.decenter(h[0],h[1]+1,4))
world.addObjectAtPos(KikiStone(), world.decenter(h[0],h[1]+1,-4))
world.addObjectAtPos(KikiMutant(), world.decenter(0,-4,0))

43
levels/machine.coffee Normal file
View File

@ -0,0 +1,43 @@
# level design by Michael Abel
module.exports =
name: "machine"
scheme: "tron_scheme"
size: [5,5,9]
intro: "machine"
help: "$scale(1.5)mission:\nactivate the exit!"
player:
position: [0,0,0]
orientation: roty270
exits: [
name: "exit"
active: 0
coordinates: [1,2,8]
]
create:
s = world.getSize()
world.addObjectAtPos(KikiMotorGear(KikiFace.X), KikiPos(0,2,4))
world.addObjectAtPos(KikiWall(), KikiPos(0,2,3))
world.addObjectAtPos(KikiWall(), KikiPos(0,2,5))
world.addObjectAtPos(KikiMotorCylinder(KikiFace.X), KikiPos(1,2,4))
world.addObjectAtPos(KikiWireStone(), KikiPos(0,2,6))
for i in range(1,9,2)
world.addObjectAtPos(KikiWall(), KikiPos(4,0,i))
world.addObjectAtPos(KikiWall(), KikiPos(4,4,i))
world.addObjectAtPos(KikiWall(), KikiPos(0,0,i))
world.addObjectAtPos(KikiWall(), KikiPos(0,4,i))
for i in range(2,8,2)
gear = KikiGear(KikiFace.X)
world.addObjectAtPos(gear, KikiPos(0,1,i))
if i == 4
gear.setActive(true)
gear = KikiGear(KikiFace.X)
world.addObjectAtPos(gear, KikiPos(0,3,i))
if i == 4
gear.setActive(true)
world.addObjectAtPos(KikiGenerator(KikiFace.X), KikiPos(0,2,2))

77
levels/maze.coffee Normal file
View File

@ -0,0 +1,77 @@
# level design by Michael Abel
module.exports =
name: "maze"
scheme: "default_scheme"
size: [4,4,4]
intro: "maze"
help: """
$scale(1.5)mission:
get to the exit!
but don't get confused :)
"""
player:
coordinates: [3,0,0]
nostatus: 0
orientation: rotz90
exits: [
name: "exit"
active: 1
coordinates: [3,3,1] #absolute coord
]
create: ->
#level 0| # |
# | # | ^ y
# | #| |
# | ##k| -> x
world.addObjectAtPos(KikiWall(), KikiPos(1,0,0))
world.addObjectAtPos(KikiWall(), KikiPos(2,0,0))
world.addObjectAtPos(KikiWall(), KikiPos(3,1,0))
world.addObjectAtPos(KikiWall(), KikiPos(1,2,0))
world.addObjectAtPos(KikiWall(), KikiPos(2,3,0))
#level 1|# # |
# |# ##|
# |## #|
# | # |
world.addObjectAtPos(KikiWall(), KikiPos(2,0,1))
world.addObjectAtPos(KikiWall(), KikiPos(0,1,1))
world.addObjectAtPos(KikiWall(), KikiPos(1,1,1))
world.addObjectAtPos(KikiWall(), KikiPos(3,1,1))
world.addObjectAtPos(KikiWall(), KikiPos(0,2,1))
world.addObjectAtPos(KikiWall(), KikiPos(2,2,1))
world.addObjectAtPos(KikiWall(), KikiPos(3,2,1))
world.addObjectAtPos(KikiWall(), KikiPos(0,3,1))
world.addObjectAtPos(KikiWall(), KikiPos(2,3,1))
#level 2| ###|
# |# ##|
# | #e#|
# |### |
world.addObjectAtPos(KikiWall(), KikiPos(0,0,2))
world.addObjectAtPos(KikiWall(), KikiPos(1,0,2))
world.addObjectAtPos(KikiWall(), KikiPos(2,0,2))
world.addObjectAtPos(KikiWall(), KikiPos(1,1,2))
world.addObjectAtPos(KikiWall(), KikiPos(3,1,2))
world.addObjectAtPos(KikiWall(), KikiPos(0,2,2))
world.addObjectAtPos(KikiWall(), KikiPos(2,2,2))
world.addObjectAtPos(KikiWall(), KikiPos(3,2,2))
world.addObjectAtPos(KikiWall(), KikiPos(1,3,2))
world.addObjectAtPos(KikiWall(), KikiPos(2,3,2))
world.addObjectAtPos(KikiWall(), KikiPos(3,3,2))
#level 3| # |
# | # |
# | ## |
# | |
world.addObjectAtPos(KikiWall(), KikiPos(1,1,3))
world.addObjectAtPos(KikiWall(), KikiPos(2,1,3))
world.addObjectAtPos(KikiWall(), KikiPos(2,2,3))
world.addObjectAtPos(KikiWall(), KikiPos(1,3,3))
world.addObjectAtPos(KikiLight(), KikiPos(3,0,0))
world.setCameraMode(world.CAMERA_INSIDE)

30
levels/mesh.coffee Normal file
View File

@ -0,0 +1,30 @@
# level design by Michael Abel
module.exports =
name: "mesh"
scheme: "default_scheme"
size: [11,11,11]
intro: "mesh"
help: "$scale(1.5)mission:\nget to the exit!"
player: coordinates: [0,0,5]
nostatus: 0
exits: [
name: "exit"
active: 1
position: [0,0,0]
]
create: ->
s=world.getSize()
middlemax = (u,v,w) ->
s=world.getSize()
d= 3.0/( (u-s.x/2.0)**2+ (v-s.y/2.0)**2 + (w-s.z/2.0)**2 + 1 )
return min(1.0 ,max(0.2,d))
middlemin = (u,v,w) ->
s=world.getSize()
d= ( (u-s.x/2.0)**2+ (v-s.y/2.0)**2 + (w-s.z/2.0)**2 )/25
return min(1.0 ,max(0.4,d))
for (i,j,l) in [ (m,n,o) for m in range(s.x) for n in range(s.y) for o in range(s.z)]
if (i+1)%2 and (j+1)%2 and (l+1)%2
world.addObjectAtPos(KikiStone(KColor(0.1*i,0.1*j,0.1*l,middlemin(i,j,l)), true) , KikiPos(i,j,l))

35
levels/mini.coffee Normal file
View File

@ -0,0 +1,35 @@
# level design by Michael Abel
module.exports =
name: "mini"
scheme: "tron_scheme"
size: [5,5,7]
intro: "mini"
help: "$scale(1.5)mission:\nget to the exit!"
player:
coordinates: [2,4,4]
nostatus: 0,
orientation: rotx90
exits: [
name: "exit"
active: 1
position: [0,0,1]
]
create: ->
world.addObjectAtPos( KikiWall(), KikiPos(1,1,0))
world.addObjectAtPos( KikiWall(), KikiPos(3,1,0))
world.addObjectAtPos( KikiWall(), KikiPos(1,3,0))
world.addObjectAtPos( KikiWall(), KikiPos(3,3,0))
world.addObjectAtPos( KikiWall(), KikiPos(1,1,6))
world.addObjectAtPos( KikiWall(), KikiPos(3,1,6))
world.addObjectAtPos( KikiWall(), KikiPos(1,3,6))
world.addObjectAtPos( KikiWall(), KikiPos(3,3,6))
world.addObjectAtPos( KikiStone(), KikiPos(1,1,1))
world.addObjectAtPos( KikiStone(), KikiPos(3,1,1))
world.addObjectAtPos( KikiStone(), KikiPos(1,3,1))
world.addObjectAtPos( KikiStone(), KikiPos(3,3,1))
world.addObjectAtPos( KikiStone(), KikiPos(2,4,0))

40
levels/move.coffee Normal file
View File

@ -0,0 +1,40 @@
module.exports =
name: "move"
scheme: "red_scheme"
intro: "move"
size: [7,7,7]
help: """
$scale(1.5)mission: activate the exit!
to activate the exit, activate the switch
to activate the switch,shoot it
to be able to shoot the switch, move the stones
to move a stone, press "$key(push)" while moving
to shoot, press "$key(shoot)"
"""
player:
coordinates: [3,5,5]
orientation: roty180
nostatus: 0
exits: [
name: "exit"
active: 0
position: [0,0,0]
]
create: ->
#
s = world.getSize()
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2-1, s.y/2+1, 0))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2+1, s.y/2+1, 0))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2+1, s.y/2-1, 0))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2-1, s.y/2-1, 0))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2-1, s.y/2, 0))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2+1, s.y/2, 0))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2, s.y/2-1, 0))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2, s.y/2+1, 0))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2, s.y/2, 1))
exit_switch = KikiSwitch()
exit_switch.getEventWithName("switched").addAction(continuous(()-> world.toggle("exit")))
world.addObjectAtPos(exit_switch, KikiPos(s.x/2, s.y/2, 0))

47
levels/mutants.coffee Normal file
View File

@ -0,0 +1,47 @@
module.exports =
name: "mutants"
scheme: "blue_scheme"
size: [9,9,9]
intro: "mutants"
help: """
$scale(1.5)mission:
deactivate the mutants!
to deactivate a mutant,
shoot him until it get's transparent
the exit will open,
when all mutant bots
are deactivated
"""
player: position: [0,-1,0]
exits: [
name: "exit"
active: 0
position: [0,0,0]
world: ()-> outro()
]
create: ->
#
s = world.getSize()
world.addObjectLine(KikiWall, [2, 2, 2], [s.x - 3, 2, 2])
world.addObjectLine(KikiWall, [s.x - 3, 2, 2], [s.x - 3, s.y - 3, 2])
world.addObjectLine(KikiWall, [s.x - 3, s.y - 3, 2], [s.x - 3, s.y - 3, s.z - 3])
world.addObjectLine(KikiWall, [s.x - 3, s.y - 3, s.z - 3], [2, s.y - 3, s.z - 3])
world.addObjectLine(KikiWall, [2, s.y - 3, s.z - 3], [2, 2, s.z - 3])
world.addObjectLine(KikiWall, [2, 2, s.z - 3], [2, 2, 2])
world.num_mutants = 5
world.death_counter = 0
botDied =() ->
world.death_counter += 1
if world.death_counter >= world.num_mutants
world.activate("exit")
for i in range(world.num_mutants)
mutant = KikiMutant()
mutant.getEventWithName("died").addAction(once(botDied))
world.setObjectRandom(mutant)

42
levels/nice.coffee Normal file
View File

@ -0,0 +1,42 @@
# level design by Michael Abel
module.exports =
name: "nice"
scheme: "tron_scheme"
size: [11,11,11]
intro: "nice"
help: "$scale(1.5)mission:\nget to the exit!"
player: position: [2,-1,0]
exits: [
name: "exit"
active: 1
position: [0,0,0]
]
create: ->
supercube = (point=(5,5,5),size=2,obj=KikiWall) ->
p=point
s=size
world.addObjectPoly(obj,[KikiPos(p[0]+s,p[1]+s,p[2]),
KikiPos(p[0]+s,p[1]-s,p[2]),
KikiPos(p[0]-s,p[1]-s,p[2]),
KikiPos(p[0]-s,p[1]+s,p[2]) ])
world.addObjectPoly(obj,[KikiPos(p[0]+s,p[1],p[2]+s),
KikiPos(p[0]+s,p[1],p[2]-s),
KikiPos(p[0]-s,p[1],p[2]-s),
KikiPos(p[0]-s,p[1],p[2]+s) ])
world.addObjectPoly(obj,[KikiPos(p[0],p[1]+s,p[2]+s),
KikiPos(p[0],p[1]+s,p[2]-s),
KikiPos(p[0],p[1]-s,p[2]-s),
KikiPos(p[0],p[1]-s,p[2]+s) ])
s = world.getSize()
world.addObjectLine(KikiWall, KikiPos(1,1,1) , KikiPos(9,9,9) )
world.addObjectLine(KikiWall, KikiPos(1,1,9) , KikiPos(9,9,1) )
world.addObjectLine(KikiWall, KikiPos(1,9,1) , KikiPos(9,1,9) )
world.addObjectLine(KikiWall, KikiPos(9,1,1) , KikiPos(1,9,9) )
world.deleteObject(world.getOccupantAtPos(world.decenter(0,0,0)))
supercube(point=(5,5,5),size=5,obj=KikiWall)
supercube(point=(5,5,5),size=3,obj=KikiStone)

34
levels/plate.coffee Normal file
View File

@ -0,0 +1,34 @@
# level design by Michael Abel
module.exports =
name: "plate"
scheme: "blue_scheme"
size: [7,7,9]
intro: "plate"
help: """
$scale(1.5)mission:\nget to the exit!
use the bombs :)
"""
player:
coordinates: [3,2,1]
nostatus: 0
orientation: KQuaternion.rotationAroundVector(270, KVector(1,0,0))
exits: [
name: "exit"
active: 1
position: [0,0,0]
]
create: ->
stone = () -> KikiStone(KColor(0.6,0.6,0.6),true)
world.addObjectAtPos(KikiStone(KColor(0.8,0.8,0.3),true), world.decenter(0,0,0))
world.addObjectPoly(stone, [world.decenter(1,1,0),world.decenter(1,-1,0), world.decenter(-1,-1,0),world.decenter(-1,1,0)], 1)
world.addObjectAtPos(KikiBomb(), world.decenter(0,1,-4))
world.addObjectAtPos(KikiBomb(), world.decenter(0,-1,-4))
world.addObjectAtPos(KikiBomb(), world.decenter(1,0,-4))
world.addObjectAtPos(KikiBomb(), world.decenter(-1,0,-4))
world.addObjectAtPos(KikiBomb(), world.decenter(0,0,-2))

35
levels/pool.coffee Normal file
View File

@ -0,0 +1,35 @@
# level design by Michael Abel
module.exports =
name: "pool"
scheme: "green_scheme"
size: [11,11,11]
intro: "pool"
help: "$scale(1.5)mission:\nget to the exit!"
player:
coordinates: [5,10,5]
nostatus: 0
orientation: rotx90
exits: [
name: "exit"
active: 1
position: [0,0,-1]
]
create:
s=world.getSize()
d=1
for (i,j,l) in [ (m,n,o) for m in range(s.x) for n in range(s.y) for o in range( s.z/2-1)]
if (-1)**(i+j+l) ==1 and not ( d<=i<=s.x-d-1 and d<=j<=s.y-d-1 and d<=l )
world.addObjectAtPos(KikiStone(KColor(0.3,0.3,1.0,0.9), true) , KikiPos(i,j,l))
stone=KikiWall
for h in [ s.z/2 -1, s.z-5]
world.addObjectPoly(stone,[ KikiPos(0,0,h),KikiPos(s.x-1,0,h),KikiPos(s.x-1,s.y-1,h),KikiPos(0,s.y-1,h)],close=1)
for (i,j) in [ (m,n) for m in range(s.x) for n in range(s.y) ]
if (-1)**(i+j) == 1
world.addObjectAtPos(KikiWall(), KikiPos(i,j,s.z-1))
world.addObjectAtPos(KikiWall(), KikiPos(i,j,s.z-2))
world.addObjectAtPos(KikiWall(), KikiPos(i,j,s.z-3))

236
levels/random.coffee Normal file
View File

@ -0,0 +1,236 @@
# level design by Michael Abel
module.exports =
name: "random"
scheme: "default_scheme"
size: [21,21,21]
intro: "random"
help: """
$scale(1.5)mission:
get to the exit!
jump and try
"""
player:
coordinates: [1,3,2]
nostatus: 0
exits: [
name: "exit"
active: 1
position: [0,0,0]
]
create: ->
#startblock
world.addObjectAtPos(KikiWall(), KikiPos(1,2,2))
world.addObjectAtPos(KikiWall(), KikiPos(1,18,2))
world.addObjectAtPos(KikiWall(), KikiPos(1,2,18))
world.addObjectAtPos(KikiWall(), KikiPos(1,18,18))
world.addObjectAtPos(KikiWall(), KikiPos(19,2,2))
world.addObjectAtPos(KikiWall(), KikiPos(19,18,2))
world.addObjectAtPos(KikiWall(), KikiPos(19,2,18))
world.addObjectAtPos(KikiWall(), KikiPos(19,18,18))
world.addObjectAtPos(KikiLight(), KikiPos(0,0,0))
world.addObjectAtPos(KikiLight(), KikiPos(20,20,20))
world.addObjectAtPos(KikiStone(), KikiPos(3,2,6))
world.addObjectAtPos(KikiStone(), KikiPos(5,2,6))
world.addObjectAtPos(KikiStone(), KikiPos(12,4,6))
world.addObjectAtPos(KikiStone(), KikiPos(14,16,6))
world.addObjectAtPos(KikiStone(), KikiPos(2,16,4))
world.addObjectAtPos(KikiStone(), KikiPos(2,14,15))
world.addObjectAtPos(KikiStone(), KikiPos(2,12,13))
world.addObjectAtPos(KikiStone(), KikiPos(4,4,13))
world.addObjectAtPos(KikiStone(), KikiPos(6,4,11))
world.addObjectAtPos(KikiStone(), KikiPos(8,4,13))
world.addObjectAtPos(KikiStone(), KikiPos(8,6,11))
world.addObjectAtPos(KikiStone(), KikiPos(6,6,4))
world.addObjectAtPos(KikiStone(), KikiPos(8,5,4))
world.addObjectAtPos(KikiStone(), KikiPos(10,6,4))
world.addObjectAtPos(KikiStone(), KikiPos(8,17,4))
world.addObjectAtPos(KikiStone(), KikiPos(10,15,4))
world.addObjectAtPos(KikiStone(), KikiPos(8,15,6))
world.addObjectAtPos(KikiStone(), KikiPos(8,13,10))
world.addObjectAtPos(KikiStone(), KikiPos(6,13,12))
world.addObjectAtPos(KikiStone(), KikiPos(5,15,12))
world.addObjectAtPos(KikiStone(), KikiPos(5,15,14))
world.addObjectAtPos(KikiStone(), KikiPos(3,17,14))
world.addObjectAtPos(KikiStone(), KikiPos(15,15,14))
world.addObjectAtPos(KikiStone(), KikiPos(9,13,14))
world.addObjectAtPos(KikiStone(), KikiPos(7,13,14))
world.addObjectAtPos(KikiStone(), KikiPos(7,15,12))
world.addObjectAtPos(KikiStone(), KikiPos(7,13,7))
world.addObjectAtPos(KikiStone(), KikiPos(7,12,5))
world.addObjectAtPos(KikiStone(), KikiPos(5,12,11))
world.addObjectAtPos(KikiStone(), KikiPos(7,7,11))
world.addObjectAtPos(KikiStone(), KikiPos(5,7,13))
world.addObjectAtPos(KikiStone(), KikiPos(3,17,13))
world.addObjectAtPos(KikiStone(), KikiPos(18,17,11))
world.addObjectAtPos(KikiStone(), KikiPos(18,7,9))
world.addObjectAtPos(KikiStone(), KikiPos(15,9,9))
world.addObjectAtPos(KikiStone(), KikiPos(17,11,9))
world.addObjectAtPos(KikiStone(), KikiPos(15,11,5))
world.addObjectAtPos(KikiStone(), KikiPos(13,11,3))
world.addObjectAtPos(KikiStone(), KikiPos(2,11,5))
world.addObjectAtPos(KikiStone(), KikiPos(2,13,18))
world.addObjectAtPos(KikiStone(), KikiPos(7,11,18))
world.addObjectAtPos(KikiStone(), KikiPos(7,9,18))
world.addObjectAtPos(KikiStone(), KikiPos(3,11,18))
world.addObjectAtPos(KikiStone(), KikiPos(3,9,10))
world.addObjectAtPos(KikiStone(), KikiPos(3,11,4))
world.addObjectAtPos(KikiStone(), KikiPos(3,13,10))
world.addObjectAtPos(KikiStone(), KikiPos(3,8,8))
world.addObjectAtPos(KikiStone(), KikiPos(3,6,16))
world.addObjectAtPos(KikiStone(), KikiPos(3,4,5))
world.addObjectAtPos(KikiStone(), KikiPos(18,6,5))
world.addObjectAtPos(KikiStone(), KikiPos(15,8,5))
world.addObjectAtPos(KikiStone(), KikiPos(15,6,8))
world.addObjectAtPos(KikiStone(), KikiPos(10,6,6))
world.addObjectAtPos(KikiStone(), KikiPos(8,6,10))
world.addObjectAtPos(KikiStone(), KikiPos(8,4,7))
world.addObjectAtPos(KikiStone(), KikiPos(10,4,12))
world.addObjectAtPos(KikiStone(), KikiPos(5,4,14))
world.addObjectAtPos(KikiStone(), KikiPos(8,6,14))
world.addObjectAtPos(KikiStone(), KikiPos(7,4,14))
world.addObjectAtPos(KikiStone(), KikiPos(7,6,16))
world.addObjectAtPos(KikiStone(), KikiPos(8,8,16))
world.addObjectAtPos(KikiStone(), KikiPos(8,10,7))
world.addObjectAtPos(KikiStone(), KikiPos(8,13,9))
world.addObjectAtPos(KikiStone(), KikiPos(8,15,4))
world.addObjectAtPos(KikiStone(), KikiPos(8,13,10))
world.addObjectAtPos(KikiStone(), KikiPos(8,7,8))
world.addObjectAtPos(KikiStone(), KikiPos(8,13,6))
world.addObjectAtPos(KikiStone(), KikiPos(4,13,8))
world.addObjectAtPos(KikiStone(), KikiPos(4,15,15))
world.addObjectAtPos(KikiStone(), KikiPos(4,18,17))
world.addObjectAtPos(KikiStone(), KikiPos(6,18,2))
world.addObjectAtPos(KikiStone(), KikiPos(10,18,4))
world.addObjectAtPos(KikiStone(), KikiPos(4,18,2))
world.addObjectAtPos(KikiStone(), KikiPos(18,16,2))
world.addObjectAtPos(KikiStone(), KikiPos(18,18,4))
world.addObjectAtPos(KikiStone(), KikiPos(16,5,4))
world.addObjectAtPos(KikiStone(), KikiPos(16,3,4))
world.addObjectAtPos(KikiStone(), KikiPos(3,5,4))
world.addObjectAtPos(KikiStone(), KikiPos(3,7,2))
world.addObjectAtPos(KikiStone(), KikiPos(13,9,2))
world.addObjectAtPos(KikiStone(), KikiPos(8,9,4))
world.addObjectAtPos(KikiStone(), KikiPos(2,9,2))
world.addObjectAtPos(KikiStone(), KikiPos(2,11,2))
world.addObjectAtPos(KikiStone(), KikiPos(4,11,12))
world.addObjectAtPos(KikiStone(), KikiPos(17,9,12))
world.addObjectAtPos(KikiStone(), KikiPos(17,7,14))
world.addObjectAtPos(KikiStone(), KikiPos(15,7,8))
world.addObjectAtPos(KikiStone(), KikiPos(17,15,8))
world.addObjectAtPos(KikiStone(), KikiPos(17,13,15))
world.addObjectAtPos(KikiStone(), KikiPos(6,11,15))
world.addObjectAtPos(KikiStone(), KikiPos(6,13,10))
world.addObjectAtPos(KikiStone(), KikiPos(6,2,12))
world.addObjectAtPos(KikiStone(), KikiPos(10,4,12))
world.addObjectAtPos(KikiStone(), KikiPos(12,4,10))
world.addObjectAtPos(KikiStone(), KikiPos(14,4,11))
world.addObjectAtPos(KikiStone(), KikiPos(14,2,12))
world.addObjectAtPos(KikiStone(), KikiPos(3,4,12))
world.addObjectAtPos(KikiStone(), KikiPos(5,14,12))
world.addObjectAtPos(KikiStone(), KikiPos(7,7,12))
world.addObjectAtPos(KikiStone(), KikiPos(7,5,2))
world.addObjectAtPos(KikiStone(), KikiPos(3,3,2))
world.addObjectAtPos(KikiStone(), KikiPos(3,5,9))
world.addObjectAtPos(KikiStone(), KikiPos(5,5,7))
world.addObjectAtPos(KikiStone(), KikiPos(7,6,7))
world.addObjectAtPos(KikiStone(), KikiPos(10,4,7))
world.addObjectAtPos(KikiStone(), KikiPos(12,10,7))
world.addObjectAtPos(KikiStone(), KikiPos(3,12,7))
world.addObjectAtPos(KikiStone(), KikiPos(5,12,7))
world.addObjectAtPos(KikiStone(), KikiPos(13,12,5))
world.addObjectAtPos(KikiStone(), KikiPos(8,12,3))
world.addObjectAtPos(KikiStone(), KikiPos(8,10,2))
world.addObjectAtPos(KikiStone(), KikiPos(8,8,13))
world.addObjectAtPos(KikiStone(), KikiPos(8,10,15))
world.addObjectAtPos(KikiStone(), KikiPos(8,12,17))
world.addObjectAtPos(KikiStone(), KikiPos(10,3,17))
world.addObjectAtPos(KikiStone(), KikiPos(11,3,15))
world.addObjectAtPos(KikiStone(), KikiPos(13,3,13))
world.addObjectAtPos(KikiStone(), KikiPos(13,5,12))
world.addObjectAtPos(KikiStone(), KikiPos(14,7,12))
world.addObjectAtPos(KikiStone(), KikiPos(16,18,12))
world.addObjectAtPos(KikiStone(), KikiPos(14,18,6))
world.addObjectAtPos(KikiStone(), KikiPos(12,18,14))
world.addObjectAtPos(KikiStone(), KikiPos(16,18,16))
world.addObjectAtPos(KikiStone(), KikiPos(2,18,14))
world.addObjectAtPos(KikiStone(), KikiPos(10,18,16))
world.addObjectAtPos(KikiStone(), KikiPos(7,18,14))
world.addObjectAtPos(KikiStone(), KikiPos(5,18,5))
world.addObjectAtPos(KikiStone(), KikiPos(3,18,12))
world.addObjectAtPos(KikiStone(), KikiPos(5,16,12))
world.addObjectAtPos(KikiStone(), KikiPos(5,16,14))
world.addObjectAtPos(KikiStone(), KikiPos(5,14,2))
world.addObjectAtPos(KikiStone(), KikiPos(8,12,2))
world.addObjectAtPos(KikiStone(), KikiPos(10,12,12))
world.addObjectAtPos(KikiStone(), KikiPos(12,6,12))
world.addObjectAtPos(KikiStone(), KikiPos(14,6,12))
world.addObjectAtPos(KikiStone(), KikiPos(14,9,14))
world.addObjectAtPos(KikiStone(), KikiPos(14,3,12))
world.addObjectAtPos(KikiStone(), KikiPos(11,3,10))
world.addObjectAtPos(KikiStone(), KikiPos(9,3,12))
world.addObjectAtPos(KikiStone(), KikiPos(7,3,12))
world.addObjectAtPos(KikiStone(), KikiPos(7,5,3))
world.addObjectAtPos(KikiStone(), KikiPos(7,7,14))
world.addObjectAtPos(KikiStone(), KikiPos(7,15,12))
world.addObjectAtPos(KikiStone(), KikiPos(18,17,12))
world.addObjectAtPos(KikiStone(), KikiPos(17,17,10))
world.addObjectAtPos(KikiStone(), KikiPos(17,15,15))
world.addObjectAtPos(KikiStone(), KikiPos(10,13,15))
world.addObjectAtPos(KikiStone(), KikiPos(8,11,15))
world.addObjectAtPos(KikiStone(), KikiPos(8,7,17))
world.addObjectAtPos(KikiStone(), KikiPos(18,9,17))
world.addObjectAtPos(KikiStone(), KikiPos(16,7,17))
world.addObjectAtPos(KikiStone(), KikiPos(14,3,17))
world.addObjectAtPos(KikiStone(), KikiPos(16,6,17))
world.addObjectAtPos(KikiStone(), KikiPos(14,6,14))
world.addObjectAtPos(KikiStone(), KikiPos(15,8,14))
world.addObjectAtPos(KikiStone(), KikiPos(17,8,12))
world.addObjectAtPos(KikiStone(), KikiPos(14,8,14))
world.addObjectAtPos(KikiStone(), KikiPos(16,2,14))
world.addObjectAtPos(KikiStone(), KikiPos(14,6,14))
world.addObjectAtPos(KikiStone(), KikiPos(16,6,14))
world.addObjectAtPos(KikiStone(), KikiPos(18,6,12))
world.addObjectAtPos(KikiStone(), KikiPos(18,4,12))
world.addObjectAtPos(KikiStone(), KikiPos(3,6,12))
world.addObjectAtPos(KikiStone(), KikiPos(3,6,14))
world.addObjectAtPos(KikiStone(), KikiPos(6,6,12))
world.addObjectAtPos(KikiStone(), KikiPos(10,4,12))
world.addObjectAtPos(KikiStone(), KikiPos(3,2,12))
world.addObjectAtPos(KikiStone(), KikiPos(3,2,10))
world.addObjectAtPos(KikiStone(), KikiPos(2,2,8))
world.addObjectAtPos(KikiStone(), KikiPos(2,4,13))
world.addObjectAtPos(KikiStone(), KikiPos(15,4,15))
world.addObjectAtPos(KikiStone(), KikiPos(13,4,15))
world.addObjectAtPos(KikiStone(), KikiPos(13,2,7))
world.addObjectAtPos(KikiStone(), KikiPos(11,15,7))
world.addObjectAtPos(KikiStone(), KikiPos(9,11,7))
world.addObjectAtPos(KikiStone(), KikiPos(7,2,7))
world.addObjectAtPos(KikiStone(), KikiPos(9,2,14))
world.addObjectAtPos(KikiStone(), KikiPos(9,4,18))
world.addObjectAtPos(KikiStone(), KikiPos(9,2,15))
world.addObjectAtPos(KikiStone(), KikiPos(7,2,4))
world.addObjectAtPos(KikiStone(), KikiPos(5,4,4))
world.addObjectAtPos(KikiStone(), KikiPos(5,6,2))
world.addObjectAtPos(KikiStone(), KikiPos(12,4,2))
world.addObjectAtPos(KikiStone(), KikiPos(3,4,4))
world.addObjectAtPos(KikiStone(), KikiPos(3,12,6))
world.addObjectAtPos(KikiStone(), KikiPos(2,12,4))
world.addObjectAtPos(KikiStone(), KikiPos(15,14,4))
world.addObjectAtPos(KikiStone(), KikiPos(7,12,4))
world.addObjectAtPos(KikiStone(), KikiPos(9,12,2))
world.addObjectAtPos(KikiStone(), KikiPos(14,12,4))
world.addObjectAtPos(KikiStone(), KikiPos(12,3,4))
world.addObjectAtPos(KikiStone(), KikiPos(14,10,4))
world.addObjectAtPos(KikiStone(), KikiPos(16,10,13))
world.addObjectAtPos(KikiStone(), KikiPos(15,8,13))
world.addObjectAtPos(KikiStone(), KikiPos(15,6,8))
world.addObjectAtPos(KikiStone(), KikiPos(17,15,8))
world.addObjectAtPos(KikiStone(), KikiPos(6,15,10))
world.addObjectAtPos(KikiStone(), KikiPos(3,13,10))
world.addObjectAtPos(KikiStone(), KikiPos(15,15,10))
world.addObjectAtPos(KikiStone(), KikiPos(19,4,4))

44
levels/regal.coffee Normal file
View File

@ -0,0 +1,44 @@
module.exports =
name: "regal"
scheme: "bronze_scheme"
size: [7,3,9]
intro: "regal"
help: "$scale(1.5)mission:\nactivate the exit!"
player: position: [0,0,0]
exits: [
name: "exit"
active: 0
position: [0,0,4]
]
create: ->
sx, sy, sz = 7,3,9
for z in range(-sz/2+1, sz/2+1)
world.addObjectAtPos(KikiWall(), world.decenter(-sx/2+1, 0, z))
world.addObjectAtPos(KikiWall(), world.decenter( sx/2, 0, z))
if z
world.addObjectAtPos(KikiWall(), world.decenter(-sx/2+2, 0, z))
world.addObjectAtPos(KikiWall(), world.decenter( sx/2-1, 0, z))
if z <> 4 and z <> -4
world.addObjectAtPos(KikiWall(), world.decenter(0, -sy/2+1, z))
if z <> 1 and z <> -1
world.addObjectAtPos(KikiWall(), world.decenter(0, sy/2, z))
for z in [-3, -1, 1, 3]
world.addObjectAtPos(KikiGear(KikiFace.PY), world.decenter(-sx/2+1, 1, z))
for z in [-3, 3]
world.addObjectAtPos(KikiGear(KikiFace.PY), world.decenter( sx/2, 1, z))
for z in [-1, 1]
world.addObjectAtPos(KikiGenerator(KikiFace.PY), world.decenter( sx/2, 1, z))
world.addObjectAtPos(KikiMotorGear(KikiFace.PY), world.decenter( 0, 0, z))
world.addObjectAtPos(KikiMotorCylinder(KikiFace.PY), world.decenter( 0, 1, z))
world.addObjectAtPos(KikiWireStone(), world.decenter(-sx/2+2, 1, 0))
world.addObjectAtPos(KikiWireStone(), world.decenter( sx/2-1, 1, 0))

31
levels/rings.coffee Normal file
View File

@ -0,0 +1,31 @@
module.exports =
name: "rings"
scheme: "default_scheme"
size: [9,7,9]
intro: "rings"
help: """
$scale(1.5)mission:
get to the exit!
to get to the exit,
use the stones
"""
player: position: [0,-1,0]
exits: [
name: "exit"
active: 1
position: [0,0,0]
]
create: ->
s = world.getSize()
for y in [-1, 1]
x = 3
world.addObjectPoly (KikiStone, [world.decenter(-x, y, -x), world.decenter(-x, y, x), \
world.decenter(x, y, x), world.decenter(x, y, -x)])
for y in [-3, 3]
for x in [-3, -1, 1, 3]
world.addObjectPoly (KikiStone, [world.decenter(-x, y, -x), world.decenter(-x, y, x), \
world.decenter(x, y, x), world.decenter(x, y, -x)])

56
levels/sandbox.coffee Normal file
View File

@ -0,0 +1,56 @@
# level design by Michael Abel
module.exports =
name: "sandbox"
scheme: "bronze_scheme"
size: [9,9,6]
intro: "sandbox"
help: """
$scale(1.5)mission:
activate the exit!
All you have to do
is to put nine stones
into the sandbox
and shoot at the switch
"""
player:
coordinates: [4,6,2]
orientation: rotx90
exits: [
name: "exit"
active: 0
position: [0,0,0]
]
create: ->
switched = ->
unoccupied = false
for (i,j) in [ (i,j) for i in range(3,6) for j in range(3,6) ]
if world.isUnoccupiedPos(KikiPos(i,j,0))
unoccupied=True
if not unoccupied:
world.toggle("exit")
switch = KikiSwitch()
switch.getEventWithName("switched").addAction ( continuous ( switched ))
world.addObjectAtPos(switch , KikiPos (0,5,0))
world.addObjectPoly(KikiWall, [ KikiPos(2,2,0),KikiPos(2,6,0),KikiPos(6,6,0),KikiPos(6,2,0)], 1)
#inside
world.addObjectAtPos(KikiStone() , KikiPos(3,4,2))
world.addObjectAtPos(KikiStone() , KikiPos(3,5,1))
world.addObjectAtPos(KikiStone() , KikiPos(5,3,1))
world.addObjectAtPos(KikiStone() , KikiPos(5,4,2))
#border
world.addObjectAtPos(KikiStone() , KikiPos(3,6,1))
world.addObjectAtPos(KikiStone() , KikiPos(4,6,1))
world.addObjectAtPos(KikiStone() , KikiPos(3,2,1))
world.addObjectAtPos(KikiStone() , KikiPos(5,2,1))
world.addObjectAtPos(KikiStone() , KikiPos(6,4,1))
world.addObjectAtPos(KikiStone() , KikiPos(6,3,1))
#outside
world.addObjectAtPos(KikiStone() , KikiPos(5,1,0))
world.addObjectAtPos(KikiStone() , KikiPos(1,7,0))

31
levels/slick.coffee Normal file
View File

@ -0,0 +1,31 @@
# level design by Michael Abel
module.exports =
name: "slick"
scheme: "tron_scheme"
size: (9,11,15)
intro: "slick"
help: """
$scale(1.5)mission:
get to the exit!
The green stone is slicky
you can't grab it while falling
"""
player:
coordinates: [4,10,0]
orientation: rotx90
exits: [
name: "exit"
active: 1
position: [0,0,4]
]
create:
s=world.getSize()
for b in range(1,4)
for (k,l) in [ (i,j) for i in range(b+1,s.x-b-1) for j in range(b+1,s.y-b-1) ]
world.addObjectAtPos(KikiStone(KColor(0,1,0,0.5), true), KikiPos(k,l,b*3))
world.addObjectAtPos(KikiWall(), KikiPos(s.x/2,s.y/2,0))
world.addObjectAtPos(KikiStone(KColor(0,1,0,0.5), true), KikiPos(s.x/2,s.y/2,2))

48
levels/spiral.coffee Normal file
View File

@ -0,0 +1,48 @@
# level design by Owen Hay
module.exports =
name: "spiral"
scheme: "zen_scheme"
intro: "spiral"
size: [5,25,5]
help: "Down the Rabbit Hole"
player:
coordinates: [3,1,3]
nostatus: 0
exits: [
name: "exit"
active: 0
position: [0,11,0]
]
create: ->
s = world.getSize()
for y in [ -7, -3, 1, 5]
x = 1
world.addObjectPoly(KikiStone, [world.decenter(-x, y, -x), world.decenter(-x, y, x), world.decenter(x, y, x), ])
for y in [-9, -5, -1, 3]
x = 1
world.addObjectPoly(KikiStone, [world.decenter(x, y, x), world.decenter(x, y, -x), world.decenter(-x, y, -x), ])
for y in [12, 11]
x = 2
world.addObjectPoly(KikiWireStone, [world.decenter(-x, y, -x), world.decenter(-x, y, x), world.decenter(x, y, x), world.decenter(x, y, -x)])
# KEY GEAR
world.addObjectAtPos(KikiGear(KikiFace.NY), world.decenter(0, -10, 0))
# LOCK MECHANISM
world.addObjectAtPos(KikiGenerator(KikiFace.NY), world.decenter(-1, 12, 0))
world.addObjectAtPos(KikiGenerator(KikiFace.NY), world.decenter(-1, 11, 0))
world.addObjectAtPos(KikiMotorCylinder(KikiFace.NY), world.decenter(1, 11, 0))
world.addObjectAtPos(KikiMotorGear(KikiFace.NY), world.decenter(1, 12, 0))
world.addObjectAtPos(KikiWireStone(), world.decenter(0, 11, 1))
world.addObjectAtPos(KikiWireStone(), world.decenter(0, 12, 1))
world.addObjectAtPos(KikiWireStone(), world.decenter(0, 11, -1))
world.addObjectAtPos(KikiWireStone(), world.decenter(0, 12, -1))

31
levels/start.coffee Normal file
View File

@ -0,0 +1,31 @@
module.exports =
name: "start"
scheme: "default_scheme"
size: [7,7,11]
intro: "start"
help: """
$scale(1.5)mission:
get to the exit!
to get to the exit,
jump on the stone
to jump,
press "$key(jump)"
while movin
to move, press "$key(move forward)" or "$key(move backward)"
to turn, press "$key(turn left)" or "$key(turn right)"
"""
player:
coordinates: [3,0,3]
nostatus: 0
exits: [
name: "exit"
active: 1
position: [0,0,3]
]
create: ->
world.addObjectAtPos(KikiWall(), world.decenter(0,0,-2))
world.addObjectAtPos(KikiWall(), world.decenter(0,0,-4))
world.addObjectAtPos(KikiWall(), world.decenter(0,0,1))

30
levels/steps.coffee Normal file
View File

@ -0,0 +1,30 @@
module.exports =
name: "steps"
scheme: "blue_scheme"
size: [7,7,13]
intro: "steps"
help: """
$scale(1.5)mission:
get to the exit!
to get to the exit,
jump on the stones
to jump, press "$key(jump)" while moving
to move, press "$key(move forward)" or "$key(move backward)",
to turn, press "$key(turn left)" or "$key(turn right)"
"""
player:
coordinates: [3,0,6]
nostatus: 0
exits:
name: "exit"
active: 1
position: [0,1,3]
]
create: ->
world.addObjectAtPos(KikiWall(), world.decenter(0,0,3))
world.addObjectAtPos(KikiWall(), world.decenter(0,-1,1))
world.addObjectAtPos(KikiWall(), world.decenter(0,-2,-1))
world.addObjectAtPos(KikiWall(), world.decenter(0,-3,-3))

43
levels/stones.coffee Normal file
View File

@ -0,0 +1,43 @@
module.exports =
name: "stones"
scheme: "blue_scheme",
size: (11,11,12),
intro: "stones",
help: """
$scale(1.5)mission:
get to the exit!
use the stones.
to move a stone,
press "$key(push)"
while moving
"""
player:
position: [0,-1,-1]
orientation: rotx90 * roty180
exits: [
name: "exit"
active: 1
coordinates: [5,5,6]
]
create: ->
s = world.getSize()
num = 4
for i in range(1,num+1):
world.addObjectPoly (KikiWall, [(s.x/2-i, s.y/2-i, i-1),
(s.x/2+i, s.y/2-i, i-1),
(s.x/2+i, s.y/2+i, i-1),
(s.x/2-i, s.y/2+i, i-1)])
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2-2, s.y/2, 3))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2+2, s.y/2, 3))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2, s.y/2+2, 3))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2, s.y/2-2, 3))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2-1, s.y/2, 2))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2+1, s.y/2, 2))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2, s.y/2+1, 2))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2, s.y/2-1, 2))

87
levels/switch.coffee Normal file
View File

@ -0,0 +1,87 @@
module.exports =
name: "switch"
scheme: "yellow_scheme"
size: [7,7,7]
intro: "switch"
help: """
$scale(1.5)mission:
activate the exit!
to activate the exit,
activate the 4 switches
to activate the switches,
shoot them
to be able to shoot the switches,
move the center stone
to move the center stone,
use the bomb.
the bomb will detonate if you shoot it
"""
player:
coordinates: [3,0,3]
nostatus: 0
exits: [
name: "exit"
active: 0
position: [0,-1,0]
]
create: ->
#
s = world.getSize ()
h = 0
# bomb and stones
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2, s.y/2, s.z/2))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2, s.y-2, s.z/2))
world.addObjectAtPos(KikiBomb(), KikiPos(s.x/2, 1, s.z/2))
# stone frames for switches
world.addObjectAtPos(KikiWall(), world.decenter( 0, h-1, s.z/2))
world.addObjectAtPos(KikiWall(), world.decenter( 0, h+1, s.z/2))
world.addObjectAtPos(KikiWall(), world.decenter( 1, h, s.z/2))
world.addObjectAtPos(KikiWall(), world.decenter(-1, h, s.z/2))
world.addObjectAtPos(KikiWall(), world.decenter(s.x/2, h-1, 0))
world.addObjectAtPos(KikiWall(), world.decenter(s.x/2, h+1, 0))
world.addObjectAtPos(KikiWall(), world.decenter(s.x/2, h, 1))
world.addObjectAtPos(KikiWall(), world.decenter(s.x/2, h, -1))
world.addObjectAtPos(KikiWall(), world.decenter( 0, h-1, -s.z/2+1))
world.addObjectAtPos(KikiWall(), world.decenter( 0, h+1, -s.z/2+1))
world.addObjectAtPos(KikiWall(), world.decenter( 1, h, -s.z/2+1))
world.addObjectAtPos(KikiWall(), world.decenter(-1, h, -s.z/2+1))
world.addObjectAtPos(KikiWall(), world.decenter(-s.x/2+1, h-1, 0))
world.addObjectAtPos(KikiWall(), world.decenter(-s.x/2+1, h+1, 0))
world.addObjectAtPos(KikiWall(), world.decenter(-s.x/2+1, h, 1))
world.addObjectAtPos(KikiWall(), world.decenter(-s.x/2+1, h, -1))
# switches
world.switch_counter = 0
switched = (switch) ->
world.switch_counter += switch.isActive() and 1 or -1
exit = kikiObjectToGate(world.getObjectWithName("exit"))
exit.setActive(world.switch_counter == 4)
switch1 = KikiSwitch()
switch1.getEventWithName("switched").addAction (continuous (()-> s=switch1: switched(s)))
switch2 = KikiSwitch()
switch2.getEventWithName("switched").addAction (continuous (()-> s=switch2: switched(s)))
switch3 = KikiSwitch()
switch3.getEventWithName("switched").addAction (continuous (()-> s=switch3: switched(s)))
switch4 = KikiSwitch()
switch4.getEventWithName("switched").addAction (continuous (()-> s=switch4: switched(s)))
world.addObjectAtPos(switch1, world.decenter(-s.x/2+1, 0, 0))
world.addObjectAtPos(switch2, world.decenter( s.x/2, 0, 0))
world.addObjectAtPos(switch3, world.decenter(0, 0, -s.z/2+1))
world.addObjectAtPos(switch4, world.decenter(0, 0, s.z/2))

32
levels/throw.coffee Normal file
View File

@ -0,0 +1,32 @@
# level design by Michael Abel
module.exports =
name: "throw"
scheme: "tron_scheme"
size: [5,7,7]
intro: "throw"
help: """
"$scale(1.5)mission:
get to the exit!
use the stones to reach it
push a stone and it will fall down
if nothing is below it
but remember:
you decide where down and below is!
"""
player:
position: [0,1,2]
orientation: rotx90 * rotx180 * roty270
exits: [
name: "exit"
active: 1
position: [0,0,0]
]
create: ->
world.addObjectAtPos( KikiWall(), world.decenter(-2,0,2))
world.addObjectAtPos( KikiStone(), world.decenter(0,1,3))
world.addObjectAtPos( KikiStone(), world.decenter(0,-1,3))

25
levels/towers.coffee Normal file
View File

@ -0,0 +1,25 @@
# level design by Ben "mrthoughtful" Griffin
module.exports =
name: "towers"
scheme: "metal_scheme"
size: [9,9,15]
intro: "towers"
help: "$scale(1.5)mission:\nget to the exit!\n\nto get to the exit,\nmove the stones"
player:
coordinates: [4,5,0]
orientation: rotx90
exits: [
name: "exit"
active: 1
position: [0,0,-3]
],
create: ->
s = world.getSize()
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2-1, s.y/2+1, 0))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2-1, s.y/2+1, 1))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2-1, s.y/2+1, 2))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2+1, s.y/2+1, 0))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2+1, s.y/2+1, 1))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2+1, s.y/2+1, 2))
world.addObjectAtPos(KikiStone(), KikiPos(s.x/2+1, s.y/2+1, 3))

41
levels/walls.coffee Normal file
View File

@ -0,0 +1,41 @@
# level design by Michael Abel
module.exports =
name: "walls"
scheme: "default_scheme"
size: [7,5,5]
intro: "walls"
help: """
$scale(1.5)mission:
get to the exit!
The exit is hidden
in the middle of
the central wall
"""
player:
coordinates: [0,0,2]
nostatus: 0
exits: [
name: "exit"
active: 1
position: [0,0,0]
]
create: ->
s=world.getSize()
middlemax = (u,v,w) ->
s=world.getSize()
d= 3.0/( (u-s.x/2.0)**2+ (v-s.y/2.0)**2 + (w-s.z/2.0)**2 + 1 )
return min(1.0 ,max(0.2,d))
middlemin = (u,v,w) ->
s=world.getSize()
d= 2* ( (u-s.x/2.0)**2+ (v-s.y/2.0)**2 + (w-s.z/2.0)**2 )/25
return min(1.0 ,max(0.4,d))
for (i,j,l) in [ (m,n,o) for m in range(s.x) for n in range(s.y) for o in range(s.z)]
if i==s.x/2 or i==s.x/2-2 or i==s.x/2+2
world.addObjectAtPos(KikiStone(KColor(0.1*i,0.1*j,0.1*l,0.6) , false) , KikiPos(i,j,l))