Esempio n. 1
0
def main():
    print(sm64net.VERSION_STR + "\n"
          "Copyright (C) 2019 - 2022  devwizard\n"
          "This project is licensed under the terms of the GNU General Public "
          "License\n"
          "version 2.  See LICENSE for more information.")
    server.init()
    ui.init()
    try:
        while ui.update():
            server.update()
            time.sleep(1.0 / 60)
    finally:
        ui.exit()
        server.exit()
    return 0
Esempio n. 2
0
def upadate_command():
    server.update(selected_tuple[0], title_text.get(), author_text.get(),
                  year_text.get(), isbn_text.get())
Esempio n. 3
0
def setup():
    update(target_plugin, 1)
    return __name__
Esempio n. 4
0
def handle(data, status):
    next = status[__name__] + status[target_plugin]
    print '{} : {} @ {}', __name__, next, target_plugin
    update(target_plugin, next)
    #data is a json object
    pass
Esempio n. 5
0
            session.close()
        self.sessions = {}


if __name__ == "__main__":
    server = server.Server("0.0.0.0", 7120)
    session_manager = SessionManager(server)

    world = World()
    world.load_state()
    login_manager = LoginManager(server)
    view_updater = ViewUpdater(world, session_manager)

    global_stop = False
    while not global_stop:
        server.update()
        session_manager.update()
        world.update()

    server.stop()
    world.save_state()
    session_manager.close_all()

    # Login process:
    # Client connects
    # Client sends login credentials
    # Attempt to authenticate
    # If not authorized:
    #   drop connection
    # If authorized:
    #   Client sends character request:
Esempio n. 6
0
def handle(data,status):
    next=status[__name__]+status[target_plugin]
    print '{} : {} @ {}',__name__,next,target_plugin
    update(target_plugin,next)
    #data is a json object
    pass
Esempio n. 7
0
def setup():
    update(target_plugin,1)
    return __name__