22w16b with massive Component changes
This commit is contained in:
1 parent
8101abb431
commit
746c8548e9
31 files changed
+153
-162
No files matched your search
@@ -4,7 +4,7 @@ import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import net.minecraft.commands.CommandSourceStack;
|
||||
import net.minecraft.network.chat.BaseComponent;
|
||||
import net.minecraft.network.chat.Component;
|
||||
import net.minecraft.util.Mth;
|
||||
import net.minecraft.world.phys.Vec3;
|
||||
|
||||
@@ -17,7 +17,7 @@ public class DistanceCalculator
|
||||
return START_POINT_STORAGE.containsKey(source.getTextName());
|
||||
}
|
||||
|
||||
public static List<BaseComponent> findDistanceBetweenTwoPoints(Vec3 pos1, Vec3 pos2)
|
||||
public static List<Component> findDistanceBetweenTwoPoints(Vec3 pos1, Vec3 pos2)
|
||||
{
|
||||
double dx = Mth.abs((float)pos1.x-(float)pos2.x);
|
||||
double dy = Mth.abs((float)pos1.y-(float)pos2.y);
|
||||
@@ -25,7 +25,7 @@ public class DistanceCalculator
|
||||
double manhattan = dx+dy+dz;
|
||||
double spherical = Math.sqrt(dx*dx + dy*dy + dz*dz);
|
||||
double cylindrical = Math.sqrt(dx*dx + dz*dz);
|
||||
List<BaseComponent> res = new ArrayList<>();
|
||||
List<Component> res = new ArrayList<>();
|
||||
res.add(Messenger.c("w Distance between ",
|
||||
Messenger.tp("c",pos1),"w and ",
|
||||
Messenger.tp("c",pos2),"w :"));
|
||||
|
||||
Reference in new issue
Block a user