forked from MapComplete/MapComplete
		
	First part of a huge refactoring
This commit is contained in:
		
							parent
							
								
									0c22b15c8d
								
							
						
					
					
						commit
						11150a258d
					
				
					 56 changed files with 1425 additions and 1324 deletions
				
			
		
							
								
								
									
										14
									
								
								Utils.ts
									
										
									
									
									
								
							
							
						
						
									
										14
									
								
								Utils.ts
									
										
									
									
									
								
							|  | @ -191,7 +191,7 @@ In the case that MapComplete is pointed to the testing grounds, the edit will be | |||
|         return newArr; | ||||
|     } | ||||
| 
 | ||||
|     public static Dupicates(arr: string[]): string[] { | ||||
|     public static Dupiclates(arr: string[]): string[] { | ||||
|         if (arr === undefined) { | ||||
|             return undefined; | ||||
|         } | ||||
|  | @ -618,5 +618,17 @@ In the case that MapComplete is pointed to the testing grounds, the edit will be | |||
|             b: parseInt(hex.substr(5, 2), 16), | ||||
|         } | ||||
|     } | ||||
| 
 | ||||
|     /** | ||||
|      * Deepclone an object by serializing and deserializing it | ||||
|      * @param x | ||||
|      * @constructor | ||||
|      */ | ||||
|     static Clone<T>(x: T): T { | ||||
|         if(x === undefined){ | ||||
|             return undefined; | ||||
|         } | ||||
|         return JSON.parse(JSON.stringify(x)); | ||||
|     } | ||||
| } | ||||
| 
 | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue