Jump to content
  • Home
  • Files
  • Docs
  • Merch
Topics
  • All Content

  • This Topic
  • This Forum

  • Advanced Search
  • Existing user? Sign In  

    Sign In



    • Not recommended on shared computers


    • Forgot your password?

  • Sign Up
  • All Activity
  • Home
  • Mod Developer Central
  • Modder Support
  • Custom milk from custom cow
1.13 Update Notes for Mod Creators
Sign in to follow this  
Followers 0
Chlod

Custom milk from custom cow

By Chlod, August 24, 2016 in Modder Support

  • Start new topic

Recommended Posts

Chlod    0

Chlod

Chlod    0

  • Tree Puncher
  • Chlod
  • Members
  • 0
  • 9 posts
Posted August 24, 2016

I have a cow. He's just basic, doesn't even have a walking animation. So, I want to get a custom milk bucket from him, the filled bucket is named "GMMilk."

 

What I wish to learn: How to get that milk bucket instead of the normal one

So... breakdown.

1. Right click the custom cow with an empty vanilla bucket

2. Get a "GMMilk" bucket but NOT a "milk_bucket" bucket

 

Thanks in advance! Have a nice day :)

Share this post


Link to post
Share on other sites

Ernio    597

Ernio

Ernio    597

  • Reality Controller
  • Ernio
  • Forge Modder
  • 597
  • 2638 posts
Posted August 24, 2016

Have you looked into EntityCow source? Without looking I am pretty sure code responsible for filling bucket with milk is in onInteract (or similar name) method. If it's not in entity, it might also be located in ItemBucket (again - something along interaction).

Override it, and do almost same thing but differently.

Share this post


Link to post
Share on other sites

Chlod    0

Chlod

Chlod    0

  • Tree Puncher
  • Chlod
  • Members
  • 0
  • 9 posts
Posted August 24, 2016

Found it! Thanks :D

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.
Sign in to follow this  
Followers 0
Go To Topic Listing



  • Recently Browsing

    No registered users viewing this page.

  • Posts

    • plugsmustard
      on/off button for custom furnace

      By plugsmustard · Posted 4 minutes ago

      you said get the pos from the packet buffer. how exactly do i do that?
    • loordgek
      on/off button for custom furnace

      By loordgek · Posted 6 minutes ago

      what part do you not understand?
    • plugsmustard
      on/off button for custom furnace

      By plugsmustard · Posted 26 minutes ago

      okay, i think i know what you mean. could you give me a little more descriptions if possible?
    • LorenzoPapi
      Double-part block breaking problem

      By LorenzoPapi · Posted 28 minutes ago

      I've got my "block_afp" block. It's formed by two parts, "TOP" and "DOWN". The block can be placed both on walls, on the floor and under the roof and it works perfectly but, when I break a part of the block, there's a problem. If the block isn't on the floor, the other part gets detroyed too. If the block IS on the floor, I don't know how to check for the other part to get destroyed. Here is a working and updated repo of my mod, with my test worlds too: https://github.com/LorenzoPapi/Test-1.12.2
    • loordgek
      on/off button for custom furnace

      By loordgek · Posted 46 minutes ago

      https://github.com/drmdgg/marijuanacraft1.14.4/blob/master/src/main/java/drmdgg/marijuanacraft/network/PacketButtonClicked.java#L29 you need to get the pos from the packetbuffer   the ide will tell whats wrong
  • Topics

    • plugsmustard
      35
      on/off button for custom furnace

      By plugsmustard
      Started Wednesday at 03:11 PM

    • LorenzoPapi
      0
      Double-part block breaking problem

      By LorenzoPapi
      Started 28 minutes ago

    • solitone
      5
      Distinguish singleplayer vs. multiplayer

      By solitone
      Started 18 hours ago

    • mlaticka_007
      4
      Forge 1.12.2 crash on launch unknown error

      By mlaticka_007
      Started September 23

    • saxon564
      3
      [1.14.4] [UNSOLVED] Server Thread Freezes After Entity Explodes

      By saxon564
      Started 10 hours ago

  • Who's Online (See full list)

    • plugsmustard
    • vaartis
    • Simon_kungen
    • Pfidget
    • loordgek
    • LorenzoPapi
    • TimeConqueror
    • Meldexun
    • Zimphire
  • All Activity
  • Home
  • Mod Developer Central
  • Modder Support
  • Custom milk from custom cow
  • Theme
  • Contact Us
  • Discord

Copyright © 2019 ForgeDevelopment LLC · Ads by Curse Powered by Invision Community