示例#1
0
文件: buildings.py 项目: btdevel/bt
 def __init__(self, filename, message, location=""):
     DefaultBuildingHandler.__init__(self, filename, message, exit_action=action.turn_back(), location=location)
示例#2
0
文件: buildings.py 项目: btdevel/bt
class IronGateHandler(TurnBackHandler):
    def __init__(self, filename, message, location=""):
        DefaultBuildingHandler.__init__(self, filename, message, exit_action=action.turn_back(), location=location)

iron_gate_mangar = IronGateHandler("city/gate.png", "You stand before an iron gate, beyond which stands Mangar's tower.", location="Iron Gate")
iron_gate_kylearan = IronGateHandler("city/gate.png", "You stand before an iron gate, beyond which stands Kylearan's tower.", location="Iron Gate")


city_gate = TurnBackHandler("city/city_gate.png", "You stand before the city gates, which are blocked by a gigantic snow drift.", location="City Gate")

app.values["charname"] = "DESMET IRKM"





# Entrance to sewers
class SewersEntryHandler(MultiScreenHandler):
    pass

sewers_entrance = SewersEntryHandler(None, location="Portal...")

screen = Screen()
screen.add_message("There is an entrance to the city sewers here. Do you wish to take it?\n ")
screen.add_option('Yes', 'yY', action.turn_back())
screen.add_option('No', 'nN', action.turn_back())
sewers_entrance.add_screen("main", screen)


示例#3
0
文件: buildings.py 项目: btdevel/bt
 def __init__(self, filename, message, location=""):
     EventHandler.__init__(self, location=location)
     self.add_key_event("lL", action.turn_back())
     self.add_key_event("aA", action.compose(action.enter_city(), action.message("The statue gives up...")))
     self.filename = filename
     self.message = message
示例#4
0
文件: review.py 项目: btdevel/bt
from bt.game.handler import MultiScreenHandler, Screen, continue_screen
from bt.game.movement import Direction


class ReviewHandler(MultiScreenHandler):
    pass


review = ReviewHandler("inside/review.png", location="Review board")

screen = Screen()
screen.add_message("Wouldst thou like to be reviewed for:\n ")
screen.add_option("Advancement", "aA", action.change_screen("advancement"))
screen.add_option("Spell Acquiring", "sS", action.change_screen("spell_acquiring"))
screen.add_option("Class Change", "cC", action.change_screen("class_change"))
screen.add_option("(EXIT)", "eE", action.turn_back(), pos=-1, center=True)
review.add_screen("main", screen)


def not_implemented():
    return continue_screen("\nNot implemented yet.", target="main")


review.add_screen("advancement", not_implemented())
review.add_screen("spell_acquiring", not_implemented())
review.add_screen("class_change", not_implemented())


# The review Board is closed for the evening. The guild
# leaders will meet with you in the morning.
#