当前位置: 首页>>代码示例>>Python>>正文


Python engine.Engine类代码示例

本文整理汇总了Python中gemuo.engine.Engine的典型用法代码示例。如果您正苦于以下问题:Python Engine类的具体用法?Python Engine怎么用?Python Engine使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


在下文中一共展示了Engine类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: __init__

    def __init__(self, client, path):
        Engine.__init__(self, client)

        self.player = client.world.player
        self.path = list(path)

        self._next_walk()
开发者ID:cculianu,项目名称:gemuo,代码行数:7,代码来源:walk.py

示例2: __init__

    def __init__(self, client, goal):
        Engine.__init__(self, client)

        self.goal = goal

        d = deferred_skills(client)
        d.addCallbacks(self._got_skills, self._failure)
开发者ID:cculianu,项目名称:gemuo,代码行数:7,代码来源:jojo.py

示例3: __init__

    def __init__(self, client, target):
        Engine.__init__(self, client)

        self.target = target

        d = deferred_find_item_in_backpack(client, lambda x: x.item_id == ITEM_BANDAGE)
        d.addCallbacks(self._found_bandage, self._failure)
开发者ID:cculianu,项目名称:gemuo,代码行数:7,代码来源:heal.py

示例4: __init__

    def __init__(self, client, container, ids):
        Engine.__init__(self, client)
        self.container = container
        self.ids = ids

        d = OpenContainer(client, container).deferred
        d.addCallbacks(self._opened, self._failure)
开发者ID:cculianu,项目名称:gemuo,代码行数:7,代码来源:items.py

示例5: __init__

    def __init__(self, client, map):
        Engine.__init__(self, client)
        self._map = map
        self.tries = 5

        print "Bank"
        self._walk()
开发者ID:cculianu,项目名称:gemuo,代码行数:7,代码来源:lumber.py

示例6: __init__

    def __init__(self, client, server, port, channel):
        Engine.__init__(self, client)

        self.channel = channel
        self.irc = None

        d = reactor.connectTCP(server, port, self)
开发者ID:cculianu,项目名称:gemuo,代码行数:7,代码来源:irc.py

示例7: __init__

    def __init__(self, client, responses):
        Engine.__init__(self, client)

        assert len(responses) > 0
        self.responses = list(responses)

        self.call_id = reactor.callLater(5, self._timeout)
开发者ID:cculianu,项目名称:gemuo,代码行数:7,代码来源:menu.py

示例8: __init__

    def __init__(self, client, spell, target):
        Engine.__init__(self, client)

        self.spell = spell
        self.target = target

        self.target_mutex = client.target_mutex
        self.target_mutex.get_target(self._target_ok, self._target_abort)
开发者ID:cculianu,项目名称:gemuo,代码行数:8,代码来源:magery.py

示例9: __init__

 def __init__(self, client, red_friends, house_rectangle):
     Engine.__init__(self, client)
     self.target = None
     self.red_friends = red_friends
     self.xmin = house_rectangle[0]
     self.xmax = house_rectangle[2]
     self.ymin = house_rectangle[1]
     self.ymax = house_rectangle[3]
开发者ID:cculianu,项目名称:gemuo,代码行数:8,代码来源:housekeeper.py

示例10: __init__

    def __init__(self, client, map):
        Engine.__init__(self, client)

        self.map = map
        self.min_x, self.min_y = 1429,1540
        self.max_x, self.max_y = 1516,1734
        self.random = random.Random()
        self._next_walk()
开发者ID:cculianu,项目名称:gemuo,代码行数:8,代码来源:stroll.py

示例11: __init__

 def __init__(self, client, itemid, amount):
     Engine.__init__(self, client)
     self.buy_items = list()
     self.vendor = None
     self.itemid = itemid
     self.amount = amount
     self.call_id = reactor.callLater(2, self._timeout)
     self.get_offer()
开发者ID:cculianu,项目名称:gemuo,代码行数:8,代码来源:buy.py

示例12: __init__

    def __init__(self, client, items, container):
        Engine.__init__(self, client)

        self._items = []
        self._items.extend(items)
        self._container = container

        self._next()
开发者ID:cculianu,项目名称:gemuo,代码行数:8,代码来源:restock.py

示例13: __init__

    def __init__(self, client, username, password, character):
        Engine.__init__(self, client)

        self._username = username
        self._password = password
        self._character = character

        self._client.send(p.AccountLogin(username, password))
开发者ID:cculianu,项目名称:gemuo,代码行数:8,代码来源:login.py

示例14: __init__

    def __init__(self, client, to):
        Engine.__init__(self, client)

        self._to = to

        d = deferred_find_player_item(client, lambda x: x.item_id == ITEM_GOLD)
        # No gold is success, because this engine is meant for use
        # cases where you donate all your money to raise Karma
        d.addCallbacks(self._donate, self._success)
开发者ID:cculianu,项目名称:gemuo,代码行数:9,代码来源:donate.py

示例15: __init__

 def __init__(self, client):
     Engine.__init__(self, client)
     self.mutex = thread.allocate_lock()
     self.entities = dict()
     self.player = None
     self.walk = None
     self.combatant = None
     self.map_width = None
     self.map_height = None
开发者ID:cculianu,项目名称:gemuo,代码行数:9,代码来源:world.py


注:本文中的gemuo.engine.Engine类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。