-New function to create IPos objects from a long
IPos:
-fromLong() now mutates the calling IPos object
This commit is contained in:
Luis C.M committed 2023-06-03 14:32:43 -05:00
1 parent 29fb8d1dcf
commit 3a6255d98f
2 files changed
+6 -1

No files matched your search

@@ -288,6 +288,10 @@ public class NpcAPI extends AbstractNpcAPI {
return this.getIPos((int)x,(int)y,(int)z);
}
public IPos getIPos(long serializedPos) {
return this.getIPos(BlockPos.fromLong(serializedPos));
}
public IPos[] getAllInBox(IPos from, IPos to, boolean sortByDistance) {
ArrayList<IPos> list = new ArrayList<>();
if (from != null && to != null) {