mirror of
https://github.com/GTNewHorizons/FindIt.git
synced 2026-11-19 08:09:05 +00:00
Search Fluids; Changed Block Highlighter (#13)
* Search Fluids; Changed Block Highlighter * fix hightlight when use rotate view --------- Co-authored-by: slprime <[email protected]>
This commit is contained in:
1 parent
9d6ce05d9e
commit
fc025b3b85
12 files changed
+303
-381
No files matched your search
@@ -7,21 +7,16 @@ import net.minecraft.util.Vec3;
|
||||
import net.minecraft.world.ChunkPosition;
|
||||
|
||||
import com.gtnh.findit.service.blockfinder.BlockFoundResponse;
|
||||
import com.gtnh.findit.service.itemfinder.ItemFoundResponse;
|
||||
|
||||
public class ClientFinderHelperUtils {
|
||||
|
||||
public static void lookAtTarget(EntityClientPlayerMP player, ItemFoundResponse response) {
|
||||
rotateViewHelper(player, response.getPositions());
|
||||
}
|
||||
|
||||
public static void lookAtTarget(EntityClientPlayerMP player, BlockFoundResponse response) {
|
||||
rotateViewHelper(player, response.getPositions());
|
||||
}
|
||||
|
||||
public static void rotateViewHelper(EntityClientPlayerMP player, List<ChunkPosition> targets) {
|
||||
Vec3 playerVec = player.getPosition(1.0F);
|
||||
Vec3 first = center(targets.remove(0));
|
||||
Vec3 first = center(targets.get(0));
|
||||
|
||||
AxisUtils.AxisPair pair = AxisUtils.calculateAxisPair(playerVec, first);
|
||||
|
||||
|
||||
Reference in new issue
Block a user