Jump to content

[1.19.2] Creating a Boat?


DakotaPride

Recommended Posts

I've done this with fabric using a library but noticed that the classes related to Boats in Forge also handle it in a similar fashion, using an enum for boat types, making it harder to create a custom boat. Is there any documentation or anything that would help as a reference or guide to this?

Link to comment
Share on other sites

11 hours ago, DakotaPride said:

Here's the crash report for this and here's the git repo (Forge) in case it may help.

It's saying that an "entityrender" variable is null, check that. 

Funnily enough, I once played on a server where the BYG boats crashed the game and they had to make a rule where crafting BYG boats was not allowed, but that was in 1.16.5.

I'm not good at modding, but at least I can read a crash report (well enough). That's something, right?

Link to comment
Share on other sites

2 hours ago, Hipposgrumm said:

It's saying that an "entityrender" variable is null, check that. 

Is there any easy way to check where this variable is located? As I have gone through the files and haven't found a null entityrender variable. Unless I'm just missing it somehow

Or do you know how BYG managed to fix their issue?

Edited by DakotaPride
Link to comment
Share on other sites

46 minutes ago, DakotaPride said:

Is there any easy way to check where this variable is located? As I have gone through the files and haven't found a null entityrender variable. Unless I'm just missing it somehow

You must check the shouldrender method in your renderer class. If you can't find it, try searching for it in the parent class (that minecraft has).

48 minutes ago, DakotaPride said:

Or do you know how BYG managed to fix their issue?

All I know is that BYG had a similar issue and it was with other mods. I didn't think to look at the crash report back then.

I'm not good at modding, but at least I can read a crash report (well enough). That's something, right?

Link to comment
Share on other sites

1 hour ago, Hipposgrumm said:

You must check the shouldrender method in your renderer class. If you can't find it, try searching for it in the parent class (that minecraft has).

What exactly am I checking it for? (I know that I should check it since that seems to be where the problem is. However, the method doesn't seem to even have an entityrenderer variable inside of the parent class.) Again, I may just be missing something, sorry.

Link to comment
Share on other sites

16 hours ago, DakotaPride said:

here's the git repo (Forge)

I checked your code; instead of creating a new renderer for your boat, just extend the original BoatRenderer class.

I'm not good at modding, but at least I can read a crash report (well enough). That's something, right?

Link to comment
Share on other sites

10 minutes ago, Hipposgrumm said:

 just extend the original BoatRenderer class.

Still comes out with the same crash report sadly. I think I may just wait until 1.20 releases and see if there are any more effective ways of doing this or any new documentation/guides (would've liked it to be sooner, but can't really control that)

Link to comment
Share on other sites

Boilerplate:

If you don't post your logs/debug.log we can't help you. For curseforge you need to enable the forge debug.log in its minecraft settings. You should also post your crash report if you have one.

If there is no error in the log file and you don't have a crash report then post the launcher_log.txt from the minecraft folder. Again for curseforge this will be in your curseforge/minecraft/Install

Large files should be posted to a file sharing site like https://gist.github.com  You should also read the support forum sticky post.

Link to comment
Share on other sites

On 3/16/2023 at 3:50 PM, warjort said:

Is there any examples of how this is used? I've never really used events before, so I'm not sure how I would get started with this. (sidenote, sorry for the long reply. Have been having Pc issues for the past couple of days)

Link to comment
Share on other sites

Boilerplate:

If you don't post your logs/debug.log we can't help you. For curseforge you need to enable the forge debug.log in its minecraft settings. You should also post your crash report if you have one.

If there is no error in the log file and you don't have a crash report then post the launcher_log.txt from the minecraft folder. Again for curseforge this will be in your curseforge/minecraft/Install

Large files should be posted to a file sharing site like https://gist.github.com  You should also read the support forum sticky post.

Link to comment
Share on other sites

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.



×
×
  • Create New...

Important Information

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