删了依托史
This commit is contained in:
parent
8c0d82a2c8
commit
23816807e3
1 changed files with 0 additions and 41 deletions
|
@ -1,41 +0,0 @@
|
|||
package net.mcreator.target.procedures;
|
||||
|
||||
import net.mcreator.target.init.TargetModItems;
|
||||
import net.minecraft.resources.ResourceLocation;
|
||||
import net.minecraft.tags.ItemTags;
|
||||
import net.minecraft.world.entity.Entity;
|
||||
import net.minecraft.world.entity.LivingEntity;
|
||||
import net.minecraft.world.item.ItemStack;
|
||||
import net.minecraft.world.level.LevelAccessor;
|
||||
import net.minecraftforge.event.TickEvent;
|
||||
import net.minecraftforge.eventbus.api.Event;
|
||||
import net.minecraftforge.eventbus.api.SubscribeEvent;
|
||||
import net.minecraftforge.fml.common.Mod;
|
||||
|
||||
import javax.annotation.Nullable;
|
||||
|
||||
|
||||
@Mod.EventBusSubscriber
|
||||
public class GunsDataProcedure {
|
||||
@SubscribeEvent
|
||||
public static void onPlayerTick(TickEvent.PlayerTickEvent event) {
|
||||
if (event.phase == TickEvent.Phase.END) {
|
||||
execute(event, event.player.level(), event.player);
|
||||
}
|
||||
}
|
||||
|
||||
public static void execute(LevelAccessor world, Entity entity) {
|
||||
execute(null, world, entity);
|
||||
}
|
||||
|
||||
private static void execute(@Nullable Event event, LevelAccessor world, Entity entity) {
|
||||
if (entity == null)
|
||||
return;
|
||||
ItemStack itemstackiterator;
|
||||
itemstackiterator = (entity instanceof LivingEntity _livEnt ? _livEnt.getMainHandItem() : ItemStack.EMPTY);
|
||||
|
||||
if (itemstackiterator.is(ItemTags.create(new ResourceLocation("target:gun")))) {
|
||||
}
|
||||
}
|
||||
|
||||
}
|
Loading…
Add table
Reference in a new issue