Jump to content

[Solved] Bonemeal Event not working on Crops any help would be lovely.


Recommended Posts

Posted

Hello, well this is my 1st post and its somthing that is pickling me. Since am new to coding (literally just started doing it yesterday,) I have been looking through as many tuts as possible to learn the basic's of coding before I start making my own mod, so I have manged to get alot of the coding for basic ore, item, block etc to work.

 

But like I said the bonemeal event is not working and I have looked around for other bonemeal events, even looked into the itemdye.java to find out if am using the correct use.

 

Like I said to no luck.

 

Anyway here is the Bonemeal Event: http://pastebin.com/F59d6Qq0

I have also put the Event Bus into the PreInit section of my testingmod.

MinecraftForge.EVENT_BUS.register(new Science_EventBonemeal());

 

The only thing its telling thats wrong is the fertilize, its underlining it in red and its only creating a method in the crop.java file that literally does nothing.

 

I have testing the crop, food and seeds that all work and it does grow. But Bonemeal didn't work on it before and the Bonemeal won't work the now.

 

Any help, direction or hints will be greatly helpful.

 

Thanks for taking the time to read my issue.  :-*

 

Posted

This work for me.


if(event.world.getBlockId(event.X, event.Y, event.Z) == ScienceBase.TestingCrop.blockID){
(ScienceBase.TestingCrop).fertilize(event.world, event.X, event.Y, event.Z, event.entityPlayer);
}

Posted

I tried that and its just doing the same issue.

 

It seems the issue is around a undefined method around the bonemeal/cropblock and it just crashes the minecraft it is rightclicked. So am now clueless completely.

 

(edited because of terrible spelling errors and sentence structure.)

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



×
×
  • Create New...

Important Information

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