mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-20 05:19:41 +00:00
Full Imports and Code Format Optimization
This commit is contained in:
1 parent
250edf099c
commit
6815f579a7
1192 files changed
+60344
-62167
No files matched your search
@@ -11,23 +11,23 @@ import java.util.List;
|
||||
|
||||
public class Utils {
|
||||
|
||||
static public <T> List<T> getNearbeEntityFromPlayer(Class<? extends T> cls,EntityPlayerMP player, int dis) {
|
||||
static public <T> List<T> getNearbeEntityFromPlayer(Class<? extends T> cls, EntityPlayerMP player, int dis) {
|
||||
AxisAlignedBB range = player.boundingBox.expand(dis, dis, dis);
|
||||
List<T> list = player.worldObj.getEntitiesWithinAABB(cls, range);
|
||||
return list;
|
||||
}
|
||||
|
||||
static public EntityPlayer getOnlinePlayer(String playername){
|
||||
static public EntityPlayer getOnlinePlayer(String playername) {
|
||||
return MinecraftServer.getServer().getConfigurationManager().func_152612_a(playername);
|
||||
}
|
||||
|
||||
static public World getWorld(String t){
|
||||
WorldServer[] ws=MinecraftServer.getServer().worldServers;
|
||||
for (WorldServer w:ws){
|
||||
if (w!=null){
|
||||
if ((w.provider.dimensionId + "").equalsIgnoreCase(t)){
|
||||
return w;
|
||||
}
|
||||
static public World getWorld(String t) {
|
||||
WorldServer[] ws = MinecraftServer.getServer().worldServers;
|
||||
for (WorldServer w : ws) {
|
||||
if (w != null) {
|
||||
if ((w.provider.dimensionId + "").equalsIgnoreCase(t)) {
|
||||
return w;
|
||||
}
|
||||
}
|
||||
}
|
||||
return null;
|
||||
|
||||
Reference in new issue
Block a user