• Recently Browsing

    No registered users viewing this page.

  • Posts

    • `itemList` -> First, you should never name a class using lowercase as the start. You should read this: https://www.geeksforgeeks.org/java-naming-conventions/   If you're in the same package, it doesn't need to be public, but public is good for other reasons.   Then you didn't actually reference the field, you need to understand the basics of referencing fields from other classes.   is is class... oh wait no,  you're talking about your original code. You can't have a class inside a method. Also, 'static' has nothing to do with 'nothing in it changes', it is a access modifier, it means that you don't need to have a instance of the containing class to refernece the method/field. You can call it directly.   Yup, this will automatically scan the annotated class and register everything to the event bus. Making every annotated event function inside be called for the proper event. THIS IS A PROBLEM! Stop copy/pasting code from 'tutorials' if the 'tutorial' doesn't teach you WHY the code exists then it's a horrible tutorial and you should not use it. The @EventBusSubscriber annotation goes on classes, it then scans the entire class for any static method that has the SubscribeEvent annotation and automatically adds them to the eventbus specified in the EventBusSubscriber annotation. That annotation can go on ANY class, it doesn't need to be a class inside a class. So you could simplify your code a lot. Good, that's what SubscribeEvent does yes.   Why do you have 'itemList.hair_fibre =' ? What does that do? Why are you doing it?   This one is a little weird, you're making a helper method, that is being used in a inner class, in the parent class... Why are there so many damn classes in this file!   Overall, I think you should look into learning some of the basic standards and practices of java coding. Namely access levels, how to reference things from other classes, what a nested class is. As well as the standard naming scemes, as if you ever post code for others to read, following these naming formats allows the reader to understand your code structure from any line.   You also have not shown me anything the explains why you are trying to call anything from your 'main' code. Everything is done for you. Thats the POINT of the @EventBusSubscriber and @SubscribeEvent 
    • I create my own capability class is this a good idea ? because it compiled but doesn't work... I copy the code from EnergyCapability...
    • https://github.com/Cerandior/VanillaExtended/blob/master/src/main/java/teabx/vanillaextended/client/models/SkeletonKingModel.java That's one of my own models, but it is in 1.14. Some things will be different for you.
    • what is happening is that when i installed forge, the installation works but when i open my launcher it does not appear in the versions but when i go to the .minecraft folder and i click on versions the forge folder with the .jar file and everything alright but doesn't appear in launcher   WARNING: I am using a pirate launcher I do not approve of the practice and I have no money to buy the game but if I could I would buy the game. the launcher i'm using is (Shiginima Launcher Sponge Edition V4300 which is the latest version of the launcher) and the latest version of (java 64 bit) i would be very grateful if anyone could help me forge-1.14.4-28.1.103-installer.jar.log
    • The method registerMessage(int, Class<MSG>, BiConsumer<MSG,PacketBuffer>, Function<PacketBuffer,MSG>, BiConsumer<MSG,Supplier<NetworkEvent.Context>>) in the type SimpleChannel is not applicable for the arguments (int, Class<PacketButtonClicked>, PacketButtonClicked::encode, PacketButtonClicked::decode, PacketButtonClicked.Handler::handle)   there's also errors over each portion "The type PacketButtonClicked does not define encode(MSG, PacketBuffer) that is applicable here"
  • Topics

  • Who's Online (See full list)