mirror of
				https://github.com/mcMMO-Dev/mcMMO.git
				synced 2025-11-04 11:03:43 +01:00 
			
		
		
		
	Run GreenThumbTimer on the current tick
It avoids onBlockBreak to be called twice (which basically launched the task twice). I don't know what were the consequences but that wasn't right anyway. Also it would be better if we wouldn't have to cancel the event, because there is a possibility that plugins like LogBlock don't have a chance to process it.
This commit is contained in:
		@@ -289,7 +289,7 @@ public class Herbalism {
 | 
			
		||||
                break;
 | 
			
		||||
            }
 | 
			
		||||
 | 
			
		||||
            plugin.getServer().getScheduler().scheduleSyncDelayedTask(plugin, new GreenThumbTimer(block, profile, type), 1);
 | 
			
		||||
            plugin.getServer().getScheduler().scheduleSyncDelayedTask(plugin, new GreenThumbTimer(block, profile, type), 0);
 | 
			
		||||
            player.updateInventory();   // Needed until replacement available
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user