Beispiel #1
0
    def after_start(self):
        log.info('[subgame]app(%s) start', self.name)
        import grpc
        gl = dict(g=Game, )
        grpc.shell_locals.update(self.frame.names)
        grpc.shell_locals.update(gl)

        #初始化完成,抛出开始消息
        Game.safe_pub(MSG_FRAME_START)
Beispiel #2
0
 def before_stop(self):
     """ 准备关闭 """
     log.info('[subgame]app(%s) before_stop', self.name)
     Game.safe_pub(MSG_FRAME_STOP)