Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Featured Replies

Minecraft#getRenderViewEntity

is returning

null

for some reason. Does your mod mess with the render view entity at all?

Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.

The change log shows a couple NPE fixes since build 1887, so there's a chance that updating Forge could help. However, you should first set a few relevant break points and step to the crash in the debugger to see if anything jumps out at you. Find what's null, where it should have been initialized, and then try to see why it wasn't.

 

If neither effort helps, then get ready to post lots of source code.

 

PS: If you don't need examplemod, then get rid of it

The debugger is a powerful and necessary tool in any IDE, so learn how to use it. You'll be able to tell us more and get better help here if you investigate your runtime problems in the debugger before posting.

  • Author

Still, error when I load a save

 

Main mod file:

package com.h41v0r.dchem;

 

 

import net.minecraft.block.Block;

import net.minecraft.block.material.Material;

import net.minecraft.init.Blocks;

import net.minecraft.init.Items;

import net.minecraft.item.Item;

import net.minecraft.item.ItemStack;

import net.minecraftforge.fml.common.Mod;

import net.minecraftforge.fml.common.SidedProxy;

import net.minecraftforge.fml.common.event.FMLInitializationEvent;

import net.minecraftforge.fml.common.event.FMLPostInitializationEvent;

import net.minecraftforge.fml.common.event.FMLPreInitializationEvent;

import net.minecraftforge.fml.common.registry.GameRegistry;

 

import java.util.logging.Logger;

 

@Mod(modid=dchem.MODID, name=dchem.MODNAME, version=dchem.MODVER)

public class dchem

{

 

 

 

  @SidedProxy(clientSide = "com.h41v0r.dchem.ClientProxy", serverSide = "com.h41v0r.dchem.ServerProxy")

public static CommonProxy proxy;

 

 

@Mod.Instance

public static dchem instance;

 

public static Logger logger;

 

/*@Mod.EventHandler

public void preInit(FMLPreInitializationEvent event) {

logger = event.getModLog();

proxy.preInit(event);

}*/

   

    @Mod.EventHandler

    public void init(FMLInitializationEvent event)

    {

}

 

}

Well, for starters, it looks like you've completely commented out your preInit event handler, so it looks like your mod main does nothing.

The debugger is a powerful and necessary tool in any IDE, so learn how to use it. You'll be able to tell us more and get better help here if you investigate your runtime problems in the debugger before posting.

  • Author

Its not the mod, I tried w/ a empty src folder and still got the same error

 

EDIT: After trying it in eclipse, it worked. Perhaps I should've mentioned that I was using IDEA

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...

Important Information

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

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.