Jump to content

[Solved] [1.15.2] Can someone explain this (Vanilla drops related))


axilirate

Recommended Posts

Subclasses of EntityLiving automatically support drawing from a loot table upon death. This is done by overriding the getLootTable method to return a ResourceLocation to the desired table. This serves as the mob’s default table; the tables of both your and other mods’ mobs can be overridden for a single entity by setting the deathLootTable field of the entity.

 

Example code would be welcome.

Edited by axilirate
Link to comment
Share on other sites

51 minutes ago, axilirate said:

Example code would be welcome.

Example code of what? You never asked a question.

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.

Link to comment
Share on other sites

12 minutes ago, Draco18s said:

Example code of what? You never asked a question.

Sorry I'll be more clear, I wonder how to change Vanilla mobs item drop and that's what they say in the documentation.
I wanted to see an example of how to modify or remove vanilla mobs loot table.

Link to comment
Share on other sites

7 minutes ago, Cyborgmas said:

You do that with data packs which you can read about on the official minecraft wiki. Also are your really on 1.15 ? EntityLiving is 1.12...

Will I be able to add my own item to the drop and if so, how do I do that? Also it was on the documentation of 1.15.x version.

 

Link to comment
Share on other sites

44 minutes ago, Cyborgmas said:

Ah yes it is outdated, and do tell people when you are copy pasting documentation. And yes data packs allow you to completely override vanilla loot table. Here is the info on the wiki:

https://minecraft.gamepedia.com/Data_pack

 

In a dev environment you place your json in resources/data/minecraft/loot_tables

Thank you so much. It worked!

Edited by axilirate
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.