def fake_team(duration, ex): bak = env.root env.root = { '1p.name': '_Faketeam', 'target.name': 'dummy', 'ex': ex, 'duration': duration, 'sample': 1, 'condi': True } env.run() skada.div(duration, 1) d = skada.sum(q=1) env.root = bak env.root['team_dps'] = d['_Faketeam']['dps'] return env.root['team_dps']
def solo(name, duration=120, ex=default_ex, condi=True): env.root = { '1p.name': name, '2p.name': '_Faketeam', 'target.name': 'dummy', 'ex': ex, 'duration': duration, 'sample': 1, 'condi': condi } ctx1 = env.run() Ctx() tmp = skada.get() skada.reset() #### fake_team(duration, ex) #### ctx1() skada.set(tmp) skada.div(env.root['duration'], env.root['sample'])
def solo_range(name, duration=120, ex=default_ex, condi=True): env.root = { '1p.name': name, '2p.name': '_Faketeam', 'target.name': 'dummy', 'ex': ex, 'duration': duration, 'sample': 256, 'condi': condi } ctx1 = env.run() skada.div(env.root['duration'], env.root['sample']) dmin = env.root['range']['min'][name] / env.root['duration'] dmax = env.root['range']['max'][name] / env.root['duration'] tmin = env.root['range']['min']['_Faketeam'] / env.root['duration'] tmax = env.root['range']['max']['_Faketeam'] / env.root['duration'] Ctx() tmp = skada.get() skada.reset() #### a = fake_team(duration, ex) #### ctx1() skada.set(tmp) bmin = (tmin / env.root['team_dps'] - 1) * 10000 bmax = (tmax / env.root['team_dps'] - 1) * 10000 env.root['range'] = {} env.root['range']['dmin'] = int(dmin) env.root['range']['dmax'] = int(dmax) env.root['range']['tmin'] = int(tmin) env.root['range']['tmax'] = int(tmax) env.root['range']['bmin'] = int(bmin) env.root['range']['bmax'] = int(bmax)
def team(conf): env.root = conf env.run() skada.div(env.root['duration'], env.root['sample'])