~ubuntu-branches/ubuntu/intrepid/enigma/intrepid

« back to all changes in this revision

Viewing changes to data/levels/duffy5.lua

  • Committer: Bazaar Package Importer
  • Author(s): Erich Schubert
  • Date: 2005-08-28 15:30:09 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20050828153009-sky64kb6tcq37xt5
Tags: 0.92.1-1
* New upstream subversion checkout
* Remove menu.s3m, which we are allowed to distributed but not to modify
  also copyright notice is confusing... (Closes: #321669)
* Rebuild with new libzipios (Closes: #325405)
  I hope this works without a versioned build-dependency
* Added "enigma replaces enigma-data" for upgrades (Closes: #308558)
* Added notes about the fonts copyright.
* updated to policy 3.6.2.1 (no changes)

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
 
2
 
levelw=80
3
 
levelh=20
4
 
 
5
 
create_world( levelw, levelh)
6
 
 
7
 
fill_floor("fl-leaves", 0,0,levelw,levelh)
8
 
enigma.ConserveLevel=FALSE
9
 
enigma.SetCompatibility("oxyd1")
10
 
 
11
 
function renderLine( line, pattern)
12
 
    for i=1, strlen(pattern) do
13
 
        local c = strsub( pattern, i, i)
14
 
        if c =="#" then
15
 
            set_stone( "st-glass", i-1, line)
16
 
        elseif c == "o" then
17
 
            oxyd( i-1, line)
18
 
        elseif c == "!" then
19
 
            abyss(i-1,line)
20
 
            --                  fill_floor("fl-water", i-1,line, 1,1)
21
 
        elseif c=="z" then
22
 
            set_actor("ac-blackball", i-.5,line+.5)
23
 
        elseif c=="+" then
24
 
            set_stone( "st-wood", i-1, line)
25
 
        elseif c=="W" then
26
 
            set_attrib(laser(i-1,line, FALSE, WEST), "name", "laser")
27
 
        elseif c=="L" then
28
 
            set_stone("st-key_a", i-1,line, {action="on", target="laser"})
29
 
        elseif c=="k" then
30
 
            set_item("it-key_a", i-1,line)
31
 
        elseif c=="`" then
32
 
            mirrorp(i-1,line,FALSE,TRUE, 2)
33
 
        elseif c=="/" then
34
 
            mirrorp(i-1,line,FALSE,TRUE, 4)
35
 
        elseif c=="B" then
36
 
            set_stone("st-bombs", i-1,line)
37
 
        elseif c=="d" then
38
 
            set_stone("st-oneway-s", i-1,line)  
39
 
        elseif c=="l" then
40
 
            set_stone("st-oneway-w", i-1,line)
41
 
        elseif c=="F" then      
42
 
            set_item("it-floppy", i-1,line)
43
 
        elseif c=="c" then      
44
 
            set_item("it-coin2", i-1,line)
45
 
        elseif c=="5" then      
46
 
            set_item("it-odometer", i-1,line)
47
 
        elseif c=="4" then      
48
 
            set_item("it-coin4", i-1,line,{value=3})
49
 
        elseif c=="P" then
50
 
            set_item("it-wrench",i-1,line)
51
 
        elseif c=="h" then
52
 
            hammer(i-1,line)
53
 
        elseif c=="H" then
54
 
            set_stone("st-stone_break", i-1,line)
55
 
        elseif c=="f" then
56
 
            set_stone( "st-floppy", i-1,line,{action="openclose",target="unimportantdoor"})
57
 
        elseif c=="A" then
58
 
            doorv( i-1,line, {name="door1"})
59
 
        elseif c=="b" then
60
 
            doorv( i-1,line, {name="door2"})
61
 
        elseif c=="C" then
62
 
            --                  doorh( i-1,line, {name="door3"})
63
 
            set_floor("fl-bridge", i-1,line, {name="bridge1", type="yy"})
64
 
        elseif c=="D" then
65
 
            set_floor("fl-bridge", i-1,line, {name="bridge2", type="yy"})
66
 
        elseif c=="1" then
67
 
            set_stone("st-switch", i-1,line, {action="callback",target="funcc"})
68
 
        elseif c=="2" then
69
 
            doorh( i-1,line, {name="unimportantdoor"})
70
 
        elseif c=="9" then
71
 
            set_stone("st-coinslot", i-1,line, {action="openclose", target="unimportantdoor"})
72
 
        end
73
 
    end 
74
 
end
75
 
 
76
 
 
77
 
renderLine(00,"####################B###9###fL###9###1####################")
78
 
renderLine(01,"#/                 #                  #                 `#")
79
 
renderLine(02,"#/                 #P   z        k   F#                 `#")
80
 
renderLine(03,"#/                 #                  #                 `#")
81
 
renderLine(04,"#                  ####d####CD####d####                  #")
82
 
renderLine(05,"#                  #       #  #       #       #2#        #")
83
 
renderLine(06,"#                  #+++++++#ch#+++++++#                  #")
84
 
renderLine(07,"#                  #       #  #       #                  #")
85
 
renderLine(08,"#                  #+++++++#  #+++++++#                  #")
86
 
renderLine(09,"#                  #   H   #  #   H   #                  #")
87
 
renderLine(10,"#                  ###++####  ####++###                  #")
88
 
renderLine(11,"#`                 # A 4          5 b #                //#")
89
 
renderLine(12,"####################o################o####################")
90
 
renderLine(13,"#`                                                     `W#")
91
 
 
92
 
oxyd_shuffle()
93
 
 
94
 
SendMessage("door1", "openclose")
95
 
SendMessage("door2", "openclose")
96
 
 
97
 
through=0
98
 
function funcc()
99
 
    through = 1-through
100
 
    if through==0 then
101
 
        SendMessage("door1", "openclose")
102
 
        SendMessage("door2", "openclose")
103
 
--      SendMessage("door3", "openclose")
104
 
        SendMessage("bridge1", "openclose")
105
 
        SendMessage("bridge2", "openclose")
106
 
    end
107
 
end
 
 
b'\\ No newline at end of file'