| 
						
						
							
								
							
						
						
					 | 
					 | 
					@ -179,23 +179,23 @@ public class Mine extends AbstractGameObject { | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    } | 
					 | 
					 | 
					 | 
					    } | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					
 | 
					 | 
					 | 
					 | 
					
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    private void setNextMineWindow() { | 
					 | 
					 | 
					 | 
					    private void setNextMineWindow() { | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    	 | 
					 | 
					 | 
					 | 
					
 | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    	//default time, 9 pm est
 | 
					 | 
					 | 
					 | 
							int nextMineHour = MBServerStatics.MINE_EARLY_WINDOW;; | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    	int mineHour = 21; | 
					 | 
					 | 
					 | 
							LocalDateTime nextOpenDate = LocalDateTime.now().withMinute(0).withSecond(0).withNano(0); | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    	 | 
					 | 
					 | 
					 | 
					
 | 
				
			
			
				
				
			
		
	
		
		
	
		
		
	
		
		
	
		
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
							// Use the new owners Mine WOO.  If errant use Early window for this server.
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    	if (this.owningGuild != null || this.owningGuild.isErrant() == false) | 
					 | 
					 | 
					 | 
					    	if (this.owningGuild != null || this.owningGuild.isErrant() == false) | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    		mineHour = this.owningGuild.getNation().getMineTime(); | 
					 | 
					 | 
					 | 
								nextMineHour = this.owningGuild.getMineTime(); | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    	int days = 1; | 
					 | 
					 | 
					 | 
					
 | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    	 | 
					 | 
					 | 
					 | 
					    	if ((this.openDate.getHour() == 0 || this.openDate.getHour() == 24) && | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    	//midnight hours
 | 
					 | 
					 | 
					 | 
								(this.owningGuild.getMineTime() != 0 && this.owningGuild.getMineTime() != 24)) | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    	if (this.openDate.getHour() != 0 && this.openDate.getHour() != 24 && (this.openDate.getDayOfMonth() == LocalDateTime.now().getDayOfMonth())) | 
					 | 
					 | 
					 | 
								nextOpenDate = nextOpenDate.withHour(nextMineHour); | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    		if (mineHour == 0 || mineHour == 24) | 
					 | 
					 | 
					 | 
							else | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    			days = 2; | 
					 | 
					 | 
					 | 
								nextOpenDate = nextOpenDate.withHour(nextMineHour).plusDays(1); | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    	 | 
					 | 
					 | 
					 | 
					
 | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    	LocalDateTime newTime = this.openDate.plusDays(days).withHour(mineHour).withMinute(0).withSecond(0).withNano(0); | 
					 | 
					 | 
					 | 
					    	DbManager.MineQueries.CHANGE_MINE_TIME(this, nextOpenDate); | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    	 | 
					 | 
					 | 
					 | 
							this.openDate = nextOpenDate; | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    	DbManager.MineQueries.CHANGE_MINE_TIME(this, newTime); | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
							this.openDate = newTime; | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
	
		
		
	
		
		
	
		
		
	
		
		
	
		
		
	
		
		
	
		
		
	
		
		
	
		
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
						} | 
					 | 
					 | 
					 | 
						} | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					
 | 
					 | 
					 | 
					 | 
					
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
						public static void loadAllMines() { | 
					 | 
					 | 
					 | 
						public static void loadAllMines() { | 
				
			
			
		
	
	
		
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
					 | 
					@ -576,16 +576,9 @@ try{ | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
							Guild nation = this.owningGuild.getNation(); | 
					 | 
					 | 
					 | 
							Guild nation = this.owningGuild.getNation(); | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
							this.nationName = nation.getName(); | 
					 | 
					 | 
					 | 
							this.nationName = nation.getName(); | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
							this.nationTag = nation.getGuildTag(); | 
					 | 
					 | 
					 | 
							this.nationTag = nation.getGuildTag(); | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
							 | 
					 | 
					 | 
					 | 
					
 | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
							LocalDateTime guildDate = LocalDateTime.now().withHour(this.owningGuild.getMineTime()).withMinute(0).withSecond(0).withNano(0); | 
					 | 
					 | 
					 | 
							setNextMineWindow(); | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
							 | 
					 | 
					 | 
					 | 
							setLastChange(System.currentTimeMillis()); | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
							if (this.openDate.getDayOfMonth() == LocalDateTime.now().getDayOfMonth()) | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
							if (this.owningGuild.getMineTime() == 0 || this.owningGuild.getMineTime() == 24) | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
								guildDate = guildDate.plusDays(1); | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
							 | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
							guildDate = guildDate.withHour(this.owningGuild.getMineTime()).withMinute(0).withSecond(0).withNano(0); | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
							this.openDate = guildDate; | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
							Mine.setLastChange(System.currentTimeMillis()); | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
	
		
		
	
		
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					
 | 
					 | 
					 | 
					 | 
					
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
							if (mineBuilding.getRank() < 1){ | 
					 | 
					 | 
					 | 
							if (mineBuilding.getRank() < 1){ | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					
 | 
					 | 
					 | 
					 | 
					
 | 
				
			
			
		
	
	
		
		
			
				
					| 
						
							
								
							
						
						
						
					 | 
					 | 
					
  |