mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-23 08:41:27 +01:00
Add getEntitiesByClass(Class<T>) and getEntitiesByClasses(Class<?>...), deprecate getEntitiesByClass(Class<T>...)
By: Mike Primm <mike@primmhome.com>
This commit is contained in:
parent
91946d8857
commit
9f2ca0a844
@ -347,8 +347,23 @@ public interface World extends PluginMessageRecipient {
|
||||
*
|
||||
* @return A List of all Entities currently residing in this world that match the given class/interface
|
||||
*/
|
||||
@Deprecated
|
||||
public <T extends Entity> Collection<T> getEntitiesByClass(Class<T>... classes);
|
||||
|
||||
/**
|
||||
* Get a collection of all entities in this World matching the given class/interface
|
||||
*
|
||||
* @return A List of all Entities currently residing in this world that match the given class/interface
|
||||
*/
|
||||
public <T extends Entity> Collection<T> getEntitiesByClass(Class<T> cls);
|
||||
|
||||
/**
|
||||
* Get a collection of all entities in this World matching any of the given classes/interfaces
|
||||
*
|
||||
* @return A List of all Entities currently residing in this world that match one or more of the given classes/interfaces
|
||||
*/
|
||||
public Collection<Entity> getEntitiesByClasses(Class<?>... classes);
|
||||
|
||||
/**
|
||||
* Get a list of all players in this World
|
||||
*
|
||||
|
Loading…
Reference in New Issue
Block a user