Jump to content

Recommended Posts

Posted

My mod does not work on the server. What's wrong with my code?

Error:

 

  Reveal hidden contents

 

 

main class

@Mod (modid = Info.ID, name = Info.NAME, version = Info.VERSION)
@NetworkMod(clientSideRequired=true, serverSideRequired=false) 


public class BaseClassMod {
 @SidedProxy(clientSide = "mbk.mods.heavy_engine.proxi.ClientProxy", serverSide = "mbk.mods.heavy_engine.proxi.CommonProxy")
 public static CommonProxy proxy;
 public static Block blockGorn ;
 public static Block blockCrucible ;
 public static Block blockBellow;


 public static int BlockGornBlockID;
 public static int BlockCrucibleBlockID;
 public static int BlockBellowBlockID;


 public static int renderBlockGornID;
 public static int renderBlockCrucibleID;
 public static int renderBlockBellowID;

static CreativeTabs tabMod = new TabMod(CreativeTabs.getNextID(),Info.NAME);



 @Instance(Info.ID)
     public BaseClassMod instance;

     // Mark this method for receiving an FMLEvent (in this case, it's the FMLPreInitializationEvent)
     @EventHandler public void preInit(FMLPreInitializationEvent event)
     {
    	 int beginBlockID=4020;
    	 
    	
    	 
    	 Configuration config = new Configuration(event.getSuggestedConfigurationFile());
    	 config.load();
    	
    	 BlockCrucibleBlockID = config.getBlock("BlockCrucible",  beginBlockID++).getInt();
    	 BlockGornBlockID = config.getBlock("BlockGorn", beginBlockID++).getInt();
    	 BlockBellowBlockID = config.getBlock("BlockBellow",  beginBlockID++).getInt();
    	 config.save();
    	 
     }
     
     @EventHandler
     public void init(FMLInitializationEvent event)
     {
    	 
    	
    	 blockCrucible = new BlockCrucible(BlockCrucibleBlockID, true).setCreativeTab(BaseClassMod.tabMod).setHardness(0.0F).setUnlocalizedName("BlockCrucible");
    	 blockGorn = new BlockGorn(BlockGornBlockID, true).setCreativeTab(BaseClassMod.tabMod).setHardness(0.0F).setUnlocalizedName("BlockGorn");
    	 blockBellow = new BlockBellow(BlockBellowBlockID, true).setCreativeTab(BaseClassMod.tabMod).setHardness(0.0F).setUnlocalizedName("BlockBellow");
    	 
    	 GameRegistry.registerBlock(blockCrucible,"BlockCrucible");
    	 GameRegistry.registerBlock(blockGorn, "BlockGorn");
    	 GameRegistry.registerBlock(blockBellow, "BlockBellow");
    	 
    	
    	 
    	 GameRegistry.registerTileEntity( mbk.mods.heavy_engine.blocks.TileEntity.TileEntityCrucible.class, "TileEntityBlockCrucible" );
    	 GameRegistry.registerTileEntity( mbk.mods.heavy_engine.blocks.TileEntity.TileEntityGorn.class, "TileEntityBlockGorn" );
    	 GameRegistry.registerTileEntity( mbk.mods.heavy_engine.blocks.TileEntity.TileEntityBellow.class, "TileEntityBlockBellow" );
    	 
    	 ClientRegistry.bindTileEntitySpecialRenderer(TileEntityCrucible.class, new RendererCrucible());
    	 ClientRegistry.bindTileEntitySpecialRenderer(TileEntityGorn.class, new RendererGorn());
    	 ClientRegistry.bindTileEntitySpecialRenderer(TileEntityBellow.class, new RendererBellow());
    	 
    	 renderBlockCrucibleID = RenderingRegistry.getNextAvailableRenderId();
    	 renderBlockGornID = RenderingRegistry.getNextAvailableRenderId();
    	 renderBlockBellowID = RenderingRegistry.getNextAvailableRenderId();
    	 
    	 RenderingRegistry.registerBlockHandler(renderBlockCrucibleID, new HandlerCrucible());
    	 RenderingRegistry.registerBlockHandler(renderBlockGornID, new HandlerGorn());
    	 RenderingRegistry.registerBlockHandler(renderBlockBellowID, new HandlerBellow());
    	 
    	 proxy.registerRenderers();
     }


}

 

ClientProxy:

public class ClientProxy extends CommonProxy
{

 @Override

     public void registerRenderers() {
	 renderBlockBellowID = RenderingRegistry.getNextAvailableRenderId();
         RenderingRegistry.registerBlockHandler(renderBlockBellowID, new HandlerBellow());
         ClientRegistry.bindTileEntitySpecialRenderer(TileEntityBellow.class, new RendererBellow());


	 renderBlockCrucibleID = RenderingRegistry.getNextAvailableRenderId();
         RenderingRegistry.registerBlockHandler(renderBlockCrucibleID, new HandlerCrucible());
	 ClientRegistry.bindTileEntitySpecialRenderer(TileEntityCrucible.class, new RendererCrucible());

	 renderBlockGornID = RenderingRegistry.getNextAvailableRenderId();
         RenderingRegistry.registerBlockHandler(renderBlockGornID, new HandlerGorn());
	 ClientRegistry.bindTileEntitySpecialRenderer(TileEntityGorn.class, new RendererGorn());

     }
}

CommonProxy:

public class CommonProxy {
public static int renderBlockBellowID;
public static int renderBlockCrucibleID;
public static int renderBlockGornID;
public void registerRenderers() {
         // Nothing here as the server doesn't render graphics or entities!

}
}

Renderer file:

@SideOnly(Side.CLIENT)
public class RendererBellow extends TileEntitySpecialRenderer
{
  
   private   ModelBellow model;
  

   private ResourceLocation TEXTURE;

   public RendererBellow()
   {
	  
      model = new ModelBellow();
     
      
   }

   public void renderTileEntityAt(TileEntity tileEntity, double x, double y, double z, float f)
   {
	  
	  
      this.renderTileEntity((TileEntityBellow)tileEntity, x, y, z, f);
   }

   public void renderTileEntity(TileEntityBellow tileEntity, double x, double y, double z, float f)
   {
	   int metadata =0;
	   if(tileEntity.worldObj != null){
		   metadata = tileEntity.getBlockMetadata();
	   }
	  
	   
	   int rotationAngle = 0;
	   if(metadata%4 == 0 ){
	    rotationAngle = 270;
	   }
	   if(metadata%4 == 1 ){
	    rotationAngle = 90;
	   }
	   if(metadata%4 == 2 ){
	    rotationAngle = 0;
	   }
	   if(metadata%4 == 3 ){
	    rotationAngle = 180;
	   }
	  
	   GL11.glPushMatrix();
	   GL11.glTranslatef((float)x + 0.5F, (float)y + 1.5F, (float)z + 0.5F);
	   GL11.glPushMatrix();
	   GL11.glRotatef(180, 0.0F, 0.0F, 1.0F);
	   GL11.glRotatef(rotationAngle, 0.0F, 1.0F, 0.0F);    	
	   this.TEXTURE = new ResourceLocation("heavy_engine", "textures/blocks/Bellow.png");
       this.bindTexture(TEXTURE);
       //Minecraft.getMinecraft().renderEngine.bindTexture(TEXTURE);
      
       this.model.activ(tileEntity.getActiv());
      
       
       
       this.model.render();
      
      
      

       GL11.glPopMatrix();
       GL11.glPopMatrix();
   }
   
   
}

Posted
Capture.png

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Posted

I apologize, my native language is not English. I understand that my code in the above lines is crazy. I was in despair (Tutorials not help me) when I wrote these lines (renderBlockBellowID = RenderingRegistry.getNextAvailableRenderId()...) in proxy, I saw them in the same solution in the forums.

 

What exactly do I have to register for the custom model block in the proxy?

Posted

Thank you very much. I think I understand the concept of client-server, rewrote the code and server running. However, sometimes I have warning when creating a new world:

[WARNING] [Minecraft-Client] Memory connection overburdened; after processing 2500 packets, we still have 680 to go!

What does it mean?

Posted

Unless the xxx to go number gets larger with each printing of it, there's nothing to worry about.

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



  • Recently Browsing

    • No registered users viewing this page.
  • Posts

    • 🌍 TITLE:   Herobrine vs Null – Rise of Prime   > “Rewrite Minecraft history. Witness the rise… and the fall.”         ---   🧩 MOD VERSION:   Minecraft Forge 1.20.1   Built with MCreator   Ultra-cinematic style, custom mobs, weapons, quests, effects, emotional cutscenes       ---   📖 FULL STORY (Final Draft):   ⚔️ ACT 1: Alex’s Death – The Beginning of Darkness   Peaceful world. Alex and Steve explore a new cave.   Suddenly, Null appears from the shadows, corrupts the land, and strikes Alex with a void blade.   A powerful cinematic cutscene plays. Alex dies in Steve’s arms.   Steve collapses crying, lightning and rain begin, music swells.       ---   ⚔️ ACT 2: Broken and Angry – The Herobrine Awakening   Days pass. Steve visits ancient ruins. He decides to face Null without powers.   He finds Null again — and gets hit violently, almost dying.   This triggers a transformation:   > “Awaken... Herobrine.”       Cinematic animation: glowing eyes, thunderstorm, ancient symbols appear. Steve transforms into Herobrine Ascendant.   Emotional soundtrack + glowing UI changes.       ---   ⚔️ ACT 3: The Rift of Eternity – The Legendary Path   The world is glitching. Shadow minions appear.   Herobrine travels through corrupted biomes: 🔹 Glitch Wastes 🔹 Soul Caverns 🔹 Void Forest 🔹 Darkstorm Mountains   Defeats powerful bosses:   🩸 Glitch Revenant   🔥 Flamebound Brute   ⚡ Stormcaller   🧊 Entity 303 (secret optional boss!)   🗡️ Shadowbound Warrior         ---   ⚔️ FINAL ACT: Rise of Prime – The Final War Begins   Arrives at The Rift of Eternity (final battle map): ⛰️ Floating mountains 🔥 Lava eruptions ⛓️ Chains from sky 🌩️ Storm and glitch FX everywhere   Final Cutscene Begins:   > "So… Herobrine finally wakes." – Prime Null         👑 FINAL BATTLE:   Boss Fight: Prime Null vs Herobrine Ascendant   3 Phases: Teleportation, Blade of the Void, Summon Minions   Environment collapses: blocks fly, camera shakes   Epic soundtrack plays with subtitles (EN + Sinhala)   Cutscene finishes with Null screaming:   > “I… will come back… from the Dark Prison!”       Black screen: “Season 2 Coming Soon”         ---   💥 WHAT’S INCLUDED IN THE MOD:   🎮 GAMEPLAY   4–6 hours of playtime   Hard mode with permadeath   Questline system with cutscene triggers   Save/load checkpoints       ---   🦸 CHARACTERS (Fully Animated)   Steve / Herobrine Ascendant   Alex (dies early)   Null (base + Prime Null final form)   Optional Bosses:   Entity 303   Flamebound Brute   Soul Warden   Shadowbound Warrior   Stormcaller   Glitch Revenant         ---   🧩 QUESTS   12+ main quests   6+ side quests (some unlock alternate endings)   Ritual quests to summon Herobrine powers       ---   🔫 WEAPONS / ITEMS   ⚡ Lightning Staff   🗡️ Void Piercer Blade   🔥 Flame Reaper   🧊 Frozen Thunder Shuriken   💎 Alex’s Amulet (used in story)       ---   💥 PARTICLE EFFECTS & CINEMATICS   Crying, rain, lightning, fire   Custom shaders (optional but NOT required)   Camera shake, blur, glow   Flying blocks during battles   Realistic terrain destruction       ---   🎬 TRAILER   Cinematic shots   Text overlays   Background score   Your name and mine: Developed by: Navindu Heshan & The Golden Friend   Ends with🌍 TITLE:   Herobrine vs Null – Rise of Prime   > “Rewrite Minecraft history. Witness the rise… and the fall.”         ---   🧩 MOD VERSION:   Minecraft Forge 1.20.1   Built with MCreator   Ultra-cinematic style, custom mobs, weapons, quests, effects, emotional cutscenes       ---   📖 FULL STORY (Final Draft):   ⚔️ ACT 1: Alex’s Death – The Beginning of Darkness   Peaceful world. Alex and Steve explore a new cave.   Suddenly, Null appears from the shadows, corrupts the land, and strikes Alex with a void blade.   A powerful cinematic cutscene plays. Alex dies in Steve’s arms.   Steve collapses crying, lightning and rain begin, music swells.       ---   ⚔️ ACT 2: Broken and Angry – The Herobrine Awakening   Days pass. Steve visits ancient ruins. He decides to face Null without powers.   He finds Null again — and gets hit violently, almost dying.   This triggers a transformation:   > “Awaken... Herobrine.”       Cinematic animation: glowing eyes, thunderstorm, ancient symbols appear. Steve transforms into Herobrine Ascendant.   Emotional soundtrack + glowing UI changes.       ---   ⚔️ ACT 3: The Rift of Eternity – The Legendary Path   The world is glitching. Shadow minions appear.   Herobrine travels through corrupted biomes: 🔹 Glitch Wastes 🔹 Soul Caverns 🔹 Void Forest 🔹 Darkstorm Mountains   Defeats powerful bosses:   🩸 Glitch Revenant   🔥 Flamebound Brute   ⚡ Stormcaller   🧊 Entity 303 (secret optional boss!)   🗡️ Shadowbound Warrior         ---   ⚔️ FINAL ACT: Rise of Prime – The Final War Begins   Arrives at The Rift of Eternity (final battle map): ⛰️ Floating mountains 🔥 Lava eruptions ⛓️ Chains from sky 🌩️ Storm and glitch FX everywhere   Final Cutscene Begins:   > "So… Herobrine finally wakes." – Prime Null         👑 FINAL BATTLE:   Boss Fight: Prime Null vs Herobrine Ascendant   3 Phases: Teleportation, Blade of the Void, Summon Minions   Environment collapses: blocks fly, camera shakes   Epic soundtrack plays with subtitles (EN + Sinhala)   Cutscene finishes with Null screaming:   > “I… will come back… from the Dark Prison!”       Black screen: “Season 2 Coming Soon”         ---   💥 WHAT’S INCLUDED IN THE MOD:   🎮 GAMEPLAY   4–6 hours of playtime   Hard mode with permadeath   Questline system with cutscene triggers   Save/load checkpoints       ---   🦸 CHARACTERS (Fully Animated)   Steve / Herobrine Ascendant   Alex (dies early)   Null (base + Prime Null final form)   Optional Bosses:   Entity 303   Flamebound Brute   Soul Warden   Shadowbound Warrior   Stormcaller   Glitch Revenant         ---   🧩 QUESTS   12+ main quests   6+ side quests (some unlock alternate endings)   Ritual quests to summon Herobrine powers       ---   🔫 WEAPONS / ITEMS   ⚡ Lightning Staff   🗡️ Void Piercer Blade   🔥 Flame Reaper   🧊 Frozen Thunder Shuriken   💎 Alex’s Amulet (used in story)       ---   💥 PARTICLE EFFECTS & CINEMATICS   Crying, rain, lightning, fire   Custom shaders (optional but NOT required)   Camera shake, blur, glow   Flying blocks during battles   Realistic terrain destruction       ---   🎬 TRAILER   Cinematic shots   Text overlays   Background score   Your name and mine: Developed by: Navindu Heshan & The Golden Friend   Ends with release date: JULY 16       ---   🧠 SPECIAL FEATURES:   Secret ending (if you don’t kill Null)   Killcam-style boss finishers   Hidden rooms + “Void Realm” area   Hard mode unlocks Glitched Steve as final secret .can you make it real.       ---   🧠 SPECIAL FEATURES:   Secret ending (if you don’t kill Null)   Killcam-style boss finishers   Hidden rooms + “Void Realm” area   Hard mode unlocks Glitched Steve as final secret .can you make it
    • Make a test with another Launcher like the Curseforge Launcher, MultiMC or AT Launcher
    • can anyone help me i am opening forge and add modpacks and then it says unable to update native luancher and i redownlaod java and the luancher it self?
    • The problem occurs also in 1.20.1 Forge, but with an "Error executing task on client" instead. I have "Sinytra Connector" installed. On 1.21.5 Fabric, there is no problem. When this happens, the chat message before the death screen appears gets sent, with an extra dash added.
    • Well, as usual, it was user error. Naming mismatch in sounds.json.  Please delete this post if you find it necessary. 
  • Topics

  • Who's Online (See full list)

×
×
  • Create New...

Important Information

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