<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
<el:level xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://enigma-game.org/schema/level/1 level.xsd" xmlns:el="http://enigma-game.org/schema/level/1">
  <el:protected>
    <el:info el:type="level">
      <el:identity el:title="Block its way!" el:subtitle="" el:id="wb5"/>
      <el:version el:score="2" el:release="2" el:revision="1" el:status="released"/>
      <el:author  el:name="Jon 'WB' Sneyers" el:email="" el:homepage=""/>
      <el:copyright>Copyright © 2003 Jon 'WB' Sneyers</el:copyright>
      <el:license el:type="GPL v2.0 or above" el:open="true"/>
      <el:compatibility el:enigma="0.92">
       <el:dependency el:path="lib/ant" el:id="lib/ant" el:release="1" el:preload="true"/>
      </el:compatibility>
      <el:modes el:easy="true" el:single="true" el:network="false"/>
      <el:score el:easy="-" el:difficult="-"/>
    </el:info>
    <el:luamain><![CDATA[
cells={}

cells[";"]=cell{floor="fl-tigris"}
cells[":"]=cell{floor="fl-samba"}
cells["/"]=cell{floor="fl-stone"}
cells[" "]=cell{floor="fl-leaves"}
cells["%"]=cell{floor="fl-sand"}
cells["w"]=cell{stone="st-wood"}
cells["W"]=cell{parent=cells[":"], stone={"st-wood"}}
cells["i"]=cell{stone="st-stoneimpulse"}
cells["I"]=cell{stone="st-stoneimpulse-hollow"}
cells["#"]=cell{stone="st-rock6"}
cells["="]=cell{stone="st-rock1"}
cells["R"]=cell{stone="st-rock8"}
cells["B"]=cell{parent=cells[":"],stone="st-black4"}
cells["b"]=cell{parent=cells[":"],stone="st-white4"}
cells["@"]=cell{floor="fl-abyss"}
cells["."]=cell{floor="fl-water"}
cells["H"]=cell{stone="st-chameleon"}
cells["&"]=cell{{{oneway, EAST}}}
cells["l"]=cell{{{oneway, SOUTH}}}
cells["j"]=cell{{{oneway, NORTH}}}
cells["V"]=cell{parent=cells[" "], stone="st-bolder-s"}
cells[">"]=cell{parent=cells[" "], stone="st-bolder-e"}
cells["<"]=cell{parent=cells[" "], stone="st-bolder-w"}
cells["^"]=cell{parent=cells[" "], stone="st-bolder-n"}
cells["t"]=cell{stone={face="st-door", attr={name="doorA", type="v"}}}
cells["T"]=cell{item= {face="it-trigger", attr={action="callback", target="close_doors"}}}
cells["U"]=cell{item= {face="it-trigger", attr={action="open", target="doorA"}}}
cells["O"]=cell{actor={face="ac-blackball", attr={player=0}}}
cells["o"]=cell{actor={face="ac-whiteball", attr={player=1}}}
cells["0"]=oxyd
cells["y"]=cell{item= {face="it-yinyang"}}
cells["1"]=cell{{{document, "text1"}}}
cells["2"]=cell{{{document, "text2"}}}
cells["3"]=cell{{{document, "text3"}}}
cells["4"]=cell{{{document, "text4"}}}

if not difficult then
    cells["u"]=cell{floor="fl-leaves"}
else
    cells["u"]=cell{stone={face="st-door-v-open", attr={name="doorB", type="v"}}}
end

level = {      
--  012345678901234567890123456789012345678
   "...................====================",
   ".iiiiiiiiiiiiiiii#iV:=::::::::::::::::=",
   ".iUu     #######i#i#:=::===========:W:=",
   ".i## O 1 & 2   ii#ii:=::=:::::::::=:::=",
   ".i0#     #####.wI0#i:=::=:::====:==:::=",
   ".i4iiiiiiIIIIIIi##ii:=B==:::=0:=...:::=",
   ".ijI##wwww########i#:=::::::.=:=:==:W:=",
   ".i II#....#IIIIIIii#:=======:=b=:=::::=",
   ".i wiw....wI     w##::B:::::W=:::=::W:=",
   ".i0 i# ww  IIII 3  .::======.=====::===",
   ".i0y t II     I  w#:::=0::::.=0::::==:=",
   ".iiiiiiiiiiiiiiiii##T=======.=======::=",
   "...................===:::::WWW::&:::::0",
   "...........RRR%%....=:::::::::::==l====",
   "..%%%%%%%..R w %..;;;:::::::::::::::::=",
   "..%  w w%..%  w%R...===W============BB=",
   "..% wow %..%%%%RR...=::W::::::::::::::=",
   "..%  w  %.....RR....=::===========::::=",
   "..%%%%%%%...........=bb=:::::::::==W===",
   "....................=:::::=====:::::::=",
   ".%%RRRRR..%RRRRRRR%.=======0=0=======B=",
   ".% y  0R..%      0%.=:::::::::::::::::=",
   ".RRR  RR..%w  w w %.=WWWWWWWWWWWWWWWWW=",
   "...RR%%...%%%%%%%%%.=:::::::::::::::::=",
   "....................==0==0=======0==0==",
--  012345678901234567890123456789012345678
}

function close_doors()
	SendMessage("doorA", "close")
	SendMessage("doorB", "close")
end

set_default_parent(cells[" "])
create_world_by_map(level)
oxyd_shuffle()
enigma.ConserveLevel = FALSE
oxyd_default_flavor = "d"
document(21,21,"text5")
    ]]></el:luamain>
    <el:i18n>
      <el:string el:key="title">
        <el:english el:translate="false"/>
      </el:string>
      <el:string el:key="text1">
        <el:english el:translate="true">Don't forget to open the door ...</el:english>
      </el:string> 
      <el:string el:key="text2">
        <el:english el:translate="true">Good Luck!</el:english>
      </el:string> 
      <el:string el:key="text3">
        <el:english el:translate="true">Hurry!</el:english>
      </el:string> 
      <el:string el:key="text4">
        <el:english el:translate="true">Congratulations! (or try again)</el:english>
      </el:string> 
      <el:string el:key="text5">
        <el:english el:translate="true">Almost finished ...</el:english>
      </el:string> 
    </el:i18n>
  </el:protected>
</el:level>
