调整数据
This commit is contained in:
parent
ede0c20711
commit
0f9513bac2
3 changed files with 6 additions and 6 deletions
|
@ -181,9 +181,9 @@ public class JavelinItem extends GunItem implements GeoItem, AnimatedItem {
|
|||
tag.putInt("max_ammo", getAmmoCount(player));
|
||||
|
||||
if (tag.getBoolean("Seeking")) {
|
||||
Entity targetEntity = player.level().getEntitiesOfClass(LivingEntity.class, player.getBoundingBox().inflate(256))
|
||||
Entity targetEntity = player.level().getEntitiesOfClass(LivingEntity.class, player.getBoundingBox().inflate(384))
|
||||
.stream().filter(e -> e.getStringUUID().equals(tag.getString("TargetEntity"))).findFirst().orElse(null);
|
||||
Entity seekingEntity = SeekTool.seekEntity(player, player.level(), 256, 9);
|
||||
Entity seekingEntity = SeekTool.seekEntity(player, player.level(), 384, 7);
|
||||
if (seekingEntity != null && seekingEntity == targetEntity) {
|
||||
tag.putInt("SeekTime", tag.getInt("SeekTime") + 1);
|
||||
} else {
|
||||
|
|
|
@ -117,7 +117,7 @@ public class FireMessage {
|
|||
}
|
||||
|
||||
if (handItem.getItem() == ModItems.JAVELIN.get() && player.getCapability(ModVariables.PLAYER_VARIABLES_CAPABILITY, null).orElse(new ModVariables.PlayerVariables()).zooming && tag.getInt("ammo") > 0) {
|
||||
Entity seekingEntity = SeekTool.seekEntity(player, player.level(), 256, 9);
|
||||
Entity seekingEntity = SeekTool.seekEntity(player, player.level(), 384, 7);
|
||||
if (seekingEntity != null) {
|
||||
tag.putString("TargetEntity",seekingEntity.getStringUUID());
|
||||
tag.putBoolean("Seeking",true);
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
{
|
||||
"zoom_speed": 0.72,
|
||||
"zoom": 4,
|
||||
"min_zoom": 4,
|
||||
"max_zoom": 9,
|
||||
"zoom": 2,
|
||||
"min_zoom": 2,
|
||||
"max_zoom": 6,
|
||||
"spread": 5,
|
||||
"zoomSpread": 5,
|
||||
"mag": 1,
|
||||
|
|
Loading…
Add table
Reference in a new issue