Jump to content

Alanor Miga

Members
  • Posts

    14
  • Joined

  • Last visited

Alanor Miga's Achievements

Tree Puncher

Tree Puncher (2/8)

0

Reputation

  1. Sorry for the late response! Pre and Post events are from here: https://paste.gg/p/anonymous/83ac3cee914c44d5804261f1a56e7c69 And BURST is never used before
  2. Ayye! Works almost like a charm! It does not crash, however, none of the postShoot/preShoot events trigger, these are in charge of making the shooting sound and spending ammo upon shooting. Log be here: https://paste.gg/p/anonymous/e8f630c32007453cbd86b0cf65a22a7c Back to the drawing board it goes!
  3. So this is a code for a "burst-type" gun, what it does is that it stops the onKeyPressed (holding) after a couple of ticks, effectively making a burst-like click. https://paste.gg/p/anonymous/e2996b28a8dd4c4287393e86bf48572a I was told that the error is that the server does not what player to reference so it just dies and crashes the server
  4. AYYYYYYYYYE IT WORKS, IT WAS THE WRONG BUS ALL ALONG! THANK YOU SO MUCH!!!
  5. It straight up does not run in runClient, it has to be the normal launcher
  6. There it is! https://github.com/AlanorMiga/Mo-Guns-1.16.5
  7. @Mod.EventBusSubscriber(modid = MoGuns.MOD_ID, bus = Mod.EventBusSubscriber.Bus.MOD) yep
  8. I mean this is the whole event bus package moguns.events; import moguns.MoGuns; import moguns.events.loot.AKMBodyStructureAdditionModifier; import net.minecraft.util.ResourceLocation; import net.minecraftforge.common.loot.GlobalLootModifierSerializer; import net.minecraftforge.event.RegistryEvent; import net.minecraftforge.eventbus.api.SubscribeEvent; import net.minecraftforge.fml.common.Mod; import javax.annotation.Nonnull; @Mod.EventBusSubscriber(modid = MoGuns.MOD_ID, bus = Mod.EventBusSubscriber.Bus.FORGE) public class LootEventBusEvents { @SubscribeEvent public static void registerModifierSerializers(@Nonnull final RegistryEvent.Register<GlobalLootModifierSerializer<?>> event) { event.getRegistry().registerAll( new AKMBodyStructureAdditionModifier.Serializer().setRegistryName (new ResourceLocation(MoGuns.MOD_ID,"akm_body_dungeon")) ); } }
  9. Thanks for the quick reply! Isnt this the registering process? @Mod.EventBusSubscriber(modid = MoGuns.MOD_ID, bus = Mod.EventBusSubscriber.Bus.FORGE) public class LootEventBusEvents { @SubscribeEvent public static void registerModifierSerializers(@Nonnull final RegistryEvent.Register<GlobalLootModifierSerializer<?>> event) { event.getRegistry().registerAll( new AKMBodyStructureAdditionModifier.Serializer().setRegistryName (new ResourceLocation(MoGuns.MOD_ID,"akm_body_dungeon")) ); } }
  10. I'm currently modifying the Simple Dungeon loot table to allow an AKM Body from my mod to appear on the chests too, but I keep getting this error: [main/ERROR] [net.minecraftforge.common.loot.LootModifierManager/]: Couldn't parse loot modifier moguns:akm_body_dungeon java.lang.NullPointerException: null These are my files (java and json) https://paste.gg/p/anonymous/4a74e4fe437f48509fa8c5d2193301b4 And here my latest.log https://paste.gg/p/anonymous/82401acb7fd045e781ea8538bae02323
  11. So I'm trying to make an addon for Mr. Crayfish's Gun mod, what I'm trying to achieve right now is to add a new gun, but I got this error while adding the max stack size property to the item and I don't know how to get around it: 'maxStackSize' has private access in 'net.minecraft.item.Item.Properties' The line of code is this one: public static final Item.Properties genericProperties = new Item.Properties().maxStackSize(1).group(MoGuns.GROUP); And the whole code is this: package ttv.alanormiga.moguns.core.registry; import ttv.alanormiga.moguns.core.MoGuns; import com.mrcrayfish.guns.item.GunItem; import net.minecraft.item.Item; import net.minecraftforge.fml.RegistryObject; import net.minecraftforge.registries.DeferredRegister; import net.minecraftforge.registries.ForgeRegistries; public class ItemRegistry { public static final DeferredRegister<Item> ITEMS = DeferredRegister.create(ForgeRegistries.ITEMS, MoGuns.ID); public static final Item.Properties genericProperties = new Item.Properties().maxStackSize(1).group(MoGuns.GROUP); public static final RegistryObject<Item> SCAR = ITEMS.register("scar", () -> new GunItem(genericProperties)); } Also here is my github repo: https://github.com/AlanorMiga/MoGuns Any help is greatly appreciated! Thanks in advance!
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.