Exemple #1
0
def create_game_handler(loop):
    logging.basicConfig(level=logging.INFO)

    scheduler = AsyncIOScheduler(loop)
    handler = WSHandlerSubject()

    # todo: find a place where it can gracefully shutdown
    players = Subject()

    handler \
        .map(register) \
        .subscribe(players)

    players \
        .subscribe(send_init)

    # refactor
    manage(players, scheduler)

    return handler
from manager import manage

manage()
Exemple #3
0
                   font=('Helvetica', 12),
                   no_titlebar=False,
                   alpha_channel=1,
                   keep_on_top=False,
                   element_padding=(2, 3),
                   default_element_size=(100, 23),
                   default_button_element_size=(120, 30),
                   # background_image='colors.png',
                   ).Layout(layout)
event, values = window.Read()
print(event, values)
print(values[0].replace('file:///', ''))  # this gets rid of file:///
filename = values[0].replace('file:///', '')
window.Close()

if os.path.isfile(filename):
    manage(filename)
    sg.Popup('Done!',
             'the data in ' + filename + ' has been updated!', )
else:
    sg.Popup('Title',
             'your filename was inaccurate')

# todo load small/mid-sized images into a file system
# todo create file that saves and logs images
# todo create layer in GUI that reads file and loads image
# todo progress bar
# todo settings bar
# todo I don't like how huge the file is
# todo I don't like how f*****g slow the boot time is
Exemple #4
0
def agent_manager(*args, **kwargs):
    manage(*args, **kwargs)