File tree Expand file tree Collapse file tree 2 files changed +4
-8
lines changed 
paper-api/src/main/java/com/destroystokyo/paper/entity 
paper-server/src/main/java/com/destroystokyo/paper/entity Expand file tree Collapse file tree 2 files changed +4
-8
lines changed Original file line number Diff line number Diff line change @@ -58,7 +58,10 @@ public interface Pathfinder {
5858     * @param target the Entity to navigate to 
5959     * @return The closest Location the Entity can get to for this navigation, or null if no path could be calculated 
6060     */ 
61-     @ Nullable  PathResult  findPath (LivingEntity  target );
61+     @ Nullable 
62+     default  PathResult  findPath (LivingEntity  target ) {
63+         return  this .findPath ((Entity )target );
64+     }
6265
6366    /** 
6467     * Calculates a destination for the Entity to navigate to to reach the target entity, 
Original file line number Diff line number Diff line change 88import  net .minecraft .world .level .pathfinder .Node ;
99import  net .minecraft .world .level .pathfinder .Path ;
1010import  org .bukkit .Location ;
11- import  org .bukkit .craftbukkit .entity .CraftLivingEntity ;
1211import  org .bukkit .craftbukkit .entity .CraftEntity ;
1312import  org .bukkit .craftbukkit .util .CraftLocation ;
1413import  org .bukkit .entity .LivingEntity ;
@@ -57,12 +56,6 @@ public PathResult findPath(Location loc) {
5756        return  path  != null  ? new  PaperPathResult (path ) : null ;
5857    }
5958
60-     @ Nullable 
61-     @ Override 
62-     public  PathResult  findPath (LivingEntity  target ) {
63-         return  this .findPath ((Entity )target );
64-     }
65- 
6659    @ Nullable 
6760    @ Override 
6861    public  PathResult  findPath (Entity  target ) {
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments