Removed usage of deprecated time.clock()
This commit is contained in:
		
							parent
							
								
									fe6a032f09
								
							
						
					
					
						commit
						ce19713209
					
				| 
						 | 
				
			
			@ -7,7 +7,7 @@ from Rom import LocalRom, Sprite, apply_rom_settings
 | 
			
		|||
 | 
			
		||||
 | 
			
		||||
def adjust(args):
 | 
			
		||||
    start = time.clock()
 | 
			
		||||
    start = time.process_time()
 | 
			
		||||
    logger = logging.getLogger('')
 | 
			
		||||
    logger.info('Patching ROM.')
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			@ -31,6 +31,6 @@ def adjust(args):
 | 
			
		|||
    rom.write_to_file(output_path('%s.sfc' % outfilebase))
 | 
			
		||||
 | 
			
		||||
    logger.info('Done. Enjoy.')
 | 
			
		||||
    logger.debug('Total Time: %s', time.clock() - start)
 | 
			
		||||
    logger.debug('Total Time: %s', time.process_time() - start)
 | 
			
		||||
 | 
			
		||||
    return args
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
							
								
								
									
										4
									
								
								Main.py
								
								
								
								
							
							
						
						
									
										4
									
								
								Main.py
								
								
								
								
							| 
						 | 
				
			
			@ -21,7 +21,7 @@ from Utils import output_path
 | 
			
		|||
__version__ = '0.6.3-pre'
 | 
			
		||||
 | 
			
		||||
def main(args, seed=None):
 | 
			
		||||
    start = time.clock()
 | 
			
		||||
    start = time.process_time()
 | 
			
		||||
 | 
			
		||||
    # 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)
 | 
			
		||||
| 
						 | 
				
			
			@ -172,7 +172,7 @@ def main(args, seed=None):
 | 
			
		|||
        world.spoiler.to_file(output_path('%s_Spoiler.txt' % outfilebase))
 | 
			
		||||
 | 
			
		||||
    logger.info('Done. Enjoy.')
 | 
			
		||||
    logger.debug('Total Time: %s', time.clock() - start)
 | 
			
		||||
    logger.debug('Total Time: %s', time.process_time() - start)
 | 
			
		||||
 | 
			
		||||
    return world
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -20,7 +20,7 @@ from Main import create_playthrough
 | 
			
		|||
__version__ = '0.2-dev'
 | 
			
		||||
 | 
			
		||||
def main(args):
 | 
			
		||||
    start_time = time.clock()
 | 
			
		||||
    start_time = time.process_time()
 | 
			
		||||
 | 
			
		||||
    # 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)
 | 
			
		||||
| 
						 | 
				
			
			@ -89,7 +89,7 @@ def main(args):
 | 
			
		|||
        world.spoiler.to_file('%s_Spoiler.txt' % outfilebase)
 | 
			
		||||
 | 
			
		||||
    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
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue