| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
|
| 18 |
import adonthell |
| 19 |
import events |
| 20 |
|
| 21 |
class cellar_to_bjarn(object): |
| 22 |
|
| 23 |
|
| 24 |
|
| 25 |
|
| 26 |
|
| 27 |
|
| 28 |
def __init__ (self, eventinstance, smdest, xdest, ydest, destdir): |
| 29 |
self.smdest = smdest |
| 30 |
self.xdest = xdest |
| 31 |
self.ydest = ydest |
| 32 |
self.destdir = destdir |
| 33 |
|
| 34 |
def run (self, submap, x, y, dir, name): |
| 35 |
p = adonthell.gamedata_get_character (name) |
| 36 |
|
| 37 |
open = adonthell.gamedata_get_quest ("demo").get_val("bjarn_door_open") |
| 38 |
if open == 0 or open == 1: |
| 39 |
if p.get_name () == adonthell.gamedata_player ().get_name (): |
| 40 |
adonthell.gamedata_get_character ("Bjarn Fingolson").launch_action (p) |
| 41 |
p.stand () |
| 42 |
p.go_west () |
| 43 |
else: |
| 44 |
events.switch_submap (p, self.smdest, self.xdest, self.ydest, self.destdir) |