~ubuntu-branches/ubuntu/saucy/enigma/saucy

« back to all changes in this revision

Viewing changes to data/levels/enigma_iii/duffy49_1.xml

  • Committer: Bazaar Package Importer
  • Author(s): Erich Schubert
  • Date: 2010-05-26 02:27:26 UTC
  • mfrom: (5.1.3 sid)
  • Revision ID: james.westby@ubuntu.com-20100526022726-7tnbf65s6btbibu2
Tags: 1.10~~pre-alpha+r2100-1
* New SVN checkout, shortly after upstream "pre-alpha" release
* Target unstable, to get more testing for enigma
* Remove spelling patches included upstream

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
 
2
<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">
 
3
  <el:protected>
 
4
    <el:info el:type="level">
 
5
      <el:identity el:title="Sacrifice" el:subtitle="" el:id="duffy49"/>
 
6
      <el:version el:score="1" el:release="1" el:revision="1" el:status="released"/>
 
7
      <el:author  el:name="Jacob Scott" el:email="" el:homepage=""/>
 
8
      <el:copyright>Copyright © 2003 Jacob Scott</el:copyright>
 
9
      <el:license el:type="GPL v2.0 or above" el:open="true"/>
 
10
      <el:compatibility el:enigma="0.92">
 
11
      </el:compatibility>
 
12
      <el:modes el:easy="false" el:single="true" el:network="false"/>
 
13
      <el:comments>
 
14
        <el:code>Lua 5.1 and XML converted by Leveladministrators</el:code>
 
15
      </el:comments>
 
16
      <el:score el:easy="-" el:difficult="-"/>
 
17
    </el:info>
 
18
    <el:luamain><![CDATA[
 
19
rooms_wide=3
 
20
rooms_high=1
 
21
 
 
22
levelw=1+(19*rooms_wide) +1
 
23
levelh=1+(12*rooms_high)
 
24
 
 
25
create_world( levelw, levelh)
 
26
enigma.ConserveLevel = 0
 
27
 
 
28
fill_floor("fl-leaves")
 
29
 
 
30
function renderLine( line, pattern)
 
31
    for i=1, strlen(pattern) do
 
32
        local c = strsub( pattern, i, i)
 
33
        if c =="#" then
 
34
            set_stone( "st-greenbrown", i-1, line)
 
35
        elseif c == "o" then
 
36
            oxyd( i-1, line)
 
37
        elseif c == "w" then
 
38
            set_stone( "st-glass", i-1, line)
 
39
        elseif c == "!" then
 
40
            abyss(i-1,line)
 
41
            fill_floor("fl-water", i-1,line, 1,1)
 
42
        elseif c=="z" then
 
43
            set_actor("ac-blackball", i-.5,line+.5)
 
44
        elseif c=="+" then
 
45
            set_stone( "st-wood",i-1,line)
 
46
        elseif c=="=" then
 
47
            fill_floor("fl-space", i-1,line, 1,1)
 
48
        elseif c=="B" then
 
49
            set_stone("st-bombs", i-1,line)
 
50
        elseif c=="d" then
 
51
            set_stone("st-oneway-s", i-1,line)
 
52
        elseif c=="l" then
 
53
            set_stone("st-oneway-w", i-1,line)
 
54
        elseif c=="s" then
 
55
            set_stone("st-stoneimpulse",i-1,line)
 
56
        elseif c=="S" then
 
57
            set_stone( "st-stoneimpulse-hollow", i-1,line)
 
58
        elseif c=="M" then
 
59
            mirrorp(i-1,line,FALSE,TRUE, 4)
 
60
        elseif c=="N" then
 
61
            mirrorp(i-1,line,TRUE,FALSE, 3)
 
62
        elseif c=="L" then
 
63
            set_attrib(laser(i-1,line, TRUE, EAST), "name", "laser")
 
64
        elseif c == "R" then
 
65
            set_stone("st-bolder-e", i-1,line)
 
66
        elseif c == "a" then
 
67
            set_stone( "st-switch", i-1, line, {target="start_ferry", action="callback"})
 
68
        end
 
69
    end
 
70
end
 
71
-- Floor:  " "
 
72
-- Border: "#"
 
73
-- Oxyd:   "o"
 
74
 
 
75
renderLine(00,"####################################################ooo###")
 
76
renderLine(01,"#a         w  w        ====== = = =   w   w  w   w w   wo#")
 
77
renderLine(02,"#      w   w   ww ww   ======= = = =  w w  w   w w w   ww#")
 
78
renderLine(03,"#      ww ww w     w   ====== = = =      w   w w   w     o")
 
79
renderLine(04,"#z           ww  w     ======= = = =  w    w   w w w     o")
 
80
renderLine(05,"#     w   w      w w   ====== = = =   w w w  w   w N     o")
 
81
renderLine(06,"#         w  ww  w     ======= = = =  w    w   w w w     o")
 
82
renderLine(07,"#               w  w   ====== = = =      w   w w   w     o")
 
83
renderLine(08,"#      ww    w    ww   ======= = = =  w w  w   w w w     o")
 
84
renderLine(09,"#       w    w     w   ====== = = =   w   w  w   w w     o")
 
85
renderLine(10,"#wwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwww###o #")
 
86
renderLine(11,"#L  MMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMw #")
 
87
renderLine(12,"##########################################################")
 
88
 
 
89
oxyd_shuffle()
 
90
 
 
91
ferry_started = nil
 
92
ferry_x = 2
 
93
ferry_y = 10
 
94
ferry_width = 1
 
95
ferry_end = 54
 
96
 
 
97
function move_ferry()
 
98
    set_stone("st-greenbrown",ferry_x+ferry_width-2,ferry_y)
 
99
    set_stone("st-greenbrown",ferry_x+ferry_width-1,ferry_y)
 
100
    set_stone("st-greenbrown",ferry_x+ferry_width,ferry_y)
 
101
    if ferry_x>2 then
 
102
        set_stone("st-glass",ferry_x+ferry_width-3, ferry_y)
 
103
    end
 
104
    ferry_x = ferry_x + 1
 
105
end
 
106
 
 
107
function timer_callback()
 
108
    if ferry_x==ferry_end then
 
109
        ferry_x=2
 
110
    end
 
111
    if ferry_started and ferry_x < ferry_end then
 
112
        move_ferry()
 
113
    end
 
114
end
 
115
 
 
116
function start_ferry()
 
117
    if not ferry_started then
 
118
        move_ferry()
 
119
        ferry_started = 1
 
120
    end
 
121
end
 
122
 
 
123
set_stone( "st-timer", 58,0 ,{target="timer_callback", action="callback",name="timer", interval=.6})
 
124
    ]]></el:luamain>
 
125
    <el:i18n>
 
126
      <el:string el:key="title">
 
127
        <el:english el:translate="false"/>
 
128
      </el:string>
 
129
    </el:i18n>
 
130
  </el:protected>
 
131
</el:level>