Removed usage of deprecated time.clock()

This commit is contained in:
Bonta-kun 2019-10-16 08:20:28 +02:00
parent fe6a032f09
commit ce19713209
3 changed files with 6 additions and 6 deletions

View File

@ -7,7 +7,7 @@ from Rom import LocalRom, Sprite, apply_rom_settings
def adjust(args): def adjust(args):
start = time.clock() start = time.process_time()
logger = logging.getLogger('') logger = logging.getLogger('')
logger.info('Patching ROM.') logger.info('Patching ROM.')
@ -31,6 +31,6 @@ def adjust(args):
rom.write_to_file(output_path('%s.sfc' % outfilebase)) rom.write_to_file(output_path('%s.sfc' % outfilebase))
logger.info('Done. Enjoy.') logger.info('Done. Enjoy.')
logger.debug('Total Time: %s', time.clock() - start) logger.debug('Total Time: %s', time.process_time() - start)
return args return args

View File

@ -21,7 +21,7 @@ from Utils import output_path
__version__ = '0.6.3-pre' __version__ = '0.6.3-pre'
def main(args, seed=None): def main(args, seed=None):
start = time.clock() start = time.process_time()
# initialize the world # initialize the world
world = World(args.multi, args.shuffle, args.logic, args.mode, args.swords, args.difficulty, args.item_functionality, args.timer, args.progressive, args.goal, args.algorithm, not args.nodungeonitems, args.accessibility, args.shuffleganon, args.quickswap, args.fastmenu, args.disablemusic, args.keysanity, args.retro, args.custom, args.customitemarray, args.shufflebosses, args.hints) world = World(args.multi, args.shuffle, args.logic, args.mode, args.swords, args.difficulty, args.item_functionality, args.timer, args.progressive, args.goal, args.algorithm, not args.nodungeonitems, args.accessibility, args.shuffleganon, args.quickswap, args.fastmenu, args.disablemusic, args.keysanity, args.retro, args.custom, args.customitemarray, args.shufflebosses, args.hints)
@ -172,7 +172,7 @@ def main(args, seed=None):
world.spoiler.to_file(output_path('%s_Spoiler.txt' % outfilebase)) world.spoiler.to_file(output_path('%s_Spoiler.txt' % outfilebase))
logger.info('Done. Enjoy.') logger.info('Done. Enjoy.')
logger.debug('Total Time: %s', time.clock() - start) logger.debug('Total Time: %s', time.process_time() - start)
return world return world

View File

@ -20,7 +20,7 @@ from Main import create_playthrough
__version__ = '0.2-dev' __version__ = '0.2-dev'
def main(args): def main(args):
start_time = time.clock() start_time = time.process_time()
# initialize the world # initialize the world
world = World(1, 'vanilla', 'noglitches', 'standard', 'normal', 'none', 'on', 'ganon', 'freshness', False, False, False, args.quickswap, args.fastmenu, args.disablemusic, False, False, False, None, 'none', False) world = World(1, 'vanilla', 'noglitches', 'standard', 'normal', 'none', 'on', 'ganon', 'freshness', False, False, False, args.quickswap, args.fastmenu, args.disablemusic, False, False, False, None, 'none', False)
@ -89,7 +89,7 @@ def main(args):
world.spoiler.to_file('%s_Spoiler.txt' % outfilebase) world.spoiler.to_file('%s_Spoiler.txt' % outfilebase)
logger.info('Done. Enjoy.') logger.info('Done. Enjoy.')
logger.debug('Total Time: %s', time.clock() - start_time) logger.debug('Total Time: %s', time.process_time() - start_time)
return world return world