Esempio n. 1
0
async def init_tutorial(logger: Logger, connection: LeagueConnection):
    ''' Initializes tutorial '''
    logger.log('Initiating tutorial...')
    future1 = connection.async_patch('/lol-npe-tutorial-path/v1/tutorials/init')
    future2 = connection.async_post('/telemetry/v1/events/new_player_experience',
                                    json={"eventName": "show_screen",
                                          "plugin": "rcp-fe-lol-new-player-experience",
                                          "screenName": "npe_tutorial_modules"})
    future3 = connection.async_put('/lol-npe-tutorial-path/v1/settings',
                                   json={"hasSeenTutorialPath": True,
                                         "hasSkippedTutorialPath": False,
                                         "shouldSeeNewPlayerExperience": False})
    future1.result()
    future2.result()
    future3.result()
Esempio n. 2
0
async def post_honor_ack(connection: LeagueConnection):
    ''' Posts honor ack '''
    future = connection.async_post('/lol-honor-v2/v1/level-change/ack')
    await asyncio.sleep(0)
    future.result()
Esempio n. 3
0
async def npe_opt_in(connection: LeagueConnection):
    ''' Opt into npe rewards '''
    future = connection.async_post('/lol-npe-rewards/v1/challenges/opt')
    await asyncio.sleep(0)
    future.result()