Everything posted by warjort
-
I've got a problem while registering projectile entity
public static final RegistryObject<EntityType<FriedSnowball>> FRIED_SNOWBALL_ENTITY = ENTITY_TYPES.register("fried_snowball_entity", () -> EntityType.Builder.<FriedSnowball>of(FriedSnowball::new, MobCategory.MISC) .sized(0.25F, 0.25F).clientTrackingRange(4).updateInterval(10).build(null)); You are not calling build() for your builder and you need to tell it the type parameter for the builder because its one of those things where java's type inference doesn't work, it's trying to use EntityType<Entity> from the ENTITY_TYPES.
-
Errors by tring to install Forge 1.18.2 to Minecraft Launcher, Pleas help
Update your java to a recent version.
-
Custom Player Attribute Crashes 1.18
You can also do it like this: @Mod.EventBusSubscriber(modid = MODID, bus = Mod.EventBusSubscriber.Bus.MOD) public class EventHandler { @SubscribeEvent public static void onEntityAttributeModificationEvent(EntityAttributeModificationEvent event) { event.add(EntityType.PLAYER, modAttributes.CRIT_CHANCE.get()); } }
-
Custom Player Attribute Crashes 1.18
That code is still not using the Mod EventBus, your "bus" variable.
-
Game Crashing During Initialization (with exception)
This looks like this issue? https://github.com/MinecraftForge/MinecraftForge/issues/8649 which was fixed in forge 40.1.33, you have 40.1.0 try updating forge (latest is 40.1.67) to see if fixes your problem.
-
The game crashed whilst unexpected error Error: org.spongepowered.asm.mixin.transformer.throwables.MixinTransformerError: An une
https://github.com/BluSunrize/ImmersiveEngineering/issues/5280
-
Custom Player Attribute Crashes 1.18
Its a good idea to put configuration and runtime code in different classes.
-
Custom Player Attribute Crashes 1.18
The error says it doesn't have the attribute. Hard to tell because you don't show the full context, but I guess you are listening on the main event bus instead of the mod event bus for the EntityAttributeModificationEvent?
-
Minecraft Forge API high level questions and clarification
It downloads the mojang jar(s) at installation and modifies them. You still need a minecraft license. How are users creating their mods from scratch, are users decompiling mojangs servers fat jars and starting there for their mods? As in, if I wanted to create a mod that introduced a new custom mob, wouldn't I need to somehow look at how actual mobs are being built by decompiling then make a similar model and repackage the jar and rerun the app? The mdk is an example mod. You actually just need ForgeGradle that the mdk uses. Mods are gradle projects. https://docs.minecraftforge.net/en/latest/gettingstarted/ Forge for 1.12 is old and no longer supported. Use 1.18.2 if you are getting started.
-
Game giving error code 805306369
Also your log contains some message about mystical agriculture not finding a tinkers construct registry. So you may have a mismatch between versions of these mods.
-
Game giving error code 805306369
You have a broken config file. config/buildinggadgets-server.toml Delete it and it will recreate it with default values. Usually this happens when your computer doesn't shut down properly (e.g. power outage) and you end up with more than 1 corrupted config file. So if it happens again, check your log to find a similar error message and see what the next broken file is.
-
[1.19] Invalid type when registering packet
Your code compiles fine for me. Just a guess, but what is your import for Supplier? It should be from java.util.function, not the one from google or netty. Otherwise, check your other imports with the types used by registerMessage(). Not related to your problem and just a style thing, but you would normally define the encoder as a class instance method, then the first parameter is implicitly passed as "this". And methods that not getters are usually named using the verb rather than the noun, e.g. public void encode(FriendlyByteBuf buffer){ buffer.writeInt(this.tAccessed); buffer.writeInt(this.tCrafted); buffer.writeBoolean(this.hAccessed); buffer.writeBoolean(this.hCrafted); }
-
minecraft 1.19 forgeserver missingforge
Update forge, twighlight forest needs a later version
-
Failed to run processor: javax.net.ssl.SSLHandshakeException
Update java to a recent version.
-
[SOLVED] [1.19] I got some errors while porting my 1.18 mod to 1.19
But you only need it if you have extra data to pass. For future reference using IContainerFactory would look something like this () -> new MenuType<>((IContainerFactory<Crate_WhiteOakGuiInv>) Crate_WhiteOakGuiInv::new) where the constructor has signature (int, Inventory, FriendlyByteBuf)
-
[SOLVED] [1.19] I got some errors while porting my 1.18 mod to 1.19
The null is the "extraData". It's from forge's IContainerFactory, which you can pass to the MenuType constructor instead. It's a subclass of MenuType.MenuSupplier. Using a lambda means it won't be an IContainerFactory, so the parameter is redundant. Using that IContainerFactory means you can pass extra data to the client when you open the screen. See the NetworkHooks.openScreen() methods and MenuType.create()
-
[SOLVED] [1.19] I got some errors while porting my 1.18 mod to 1.19
public static final RegistryObject<MenuType<Crate_WhiteOakGUIMenu>> WHITE_OAK_CRATE_GUI = REGISTRY.register("white_oak_crate_gui", () -> new MenuType<>((id, inv) -> new Crate_WhiteOakGUIMenu(id, inv))); You are also not even using the MenuType constructor, or using a supplier for the object. It should be more like the above.
-
I want to make a server in version 1.18.2 and I get this error, can someone help me?
delete the mod's jar from the mods folder.
-
[SOLVED] [1.19] I got some errors while porting my 1.18 mod to 1.19
Look at the MenuType constructor. It takes a MenuType.MenuSupplier. That functional interface's method takes 2 parameters while you have 3 in your lambda.
-
I want to make a server in version 1.18.2 and I get this error, can someone help me?
Remove rubidium from the server, you don't need it. Maybe one day, the rubidium developer will fix this bug? ๐
-
[SOLVED] [1.19] I got some errors while porting my 1.18 mod to 1.19
You will probably find it easier to get rid of the registerMenu() method and just write the register directly in the static initializer(s). That way the compiler will have more opportunity to infer the correct generic parameters.
-
[SOLVED] [1.19] I got some errors while porting my 1.18 mod to 1.19
That is probably because you are trying to register MenuTypes in a DeferredRegister<Container> Like I said above, try to figure this out for yourself. That means spending time on it to understand what the compiler is telling you, not dumping the compiler errors here for us to fix without you engaging your brain. ๐
-
[SOLVED] [1.19] I got some errors while porting my 1.18 mod to 1.19
I think you need to take a step back and understand what you are doing. You can't just keep posting compiler errors from random code you write here.
-
[SOLVED] [1.19] I got some errors while porting my 1.18 mod to 1.19
Its more like <T extends AbstractContainerMenu> RegistryObject<MenuType<T>> Your return type is the RegistryObject, the T is a generic parameter definition. I was too hung up on the weird double brackets. ๐
-
[SOLVED] [1.19] I got some errors while porting my 1.18 mod to 1.19
- RegistryObject<<T extends AbstractContainerMenu> MenuType<T>> + RegistryObject<T extends AbstractContainerMenu> MenuType<T>
IPS spam blocked by CleanTalk.