Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 11/07/18 in all areas

  1. Object#toString will return a fully qualified class name appended by @ and the object's hashcode in hex. Item doesn't override that method so you get this. In any case don't use metadata for buckets, use capabilities to store the fluid. As for the model - forge uses a custom model for it's buckets - ModelDynBucket. It is needed because any mod can add any fluid it wants and the forge bucket must be able to contain it and display the propper fluid textures. You can utilize forge's bucket model in json - the parent model becomes forge:forgebucket, and the textures it expects are: base: The bucket's empty texture fluid: The dummy fluid texture. I think this is basically the mask for the fluid's actual texture to apply to, and anything outside of the mask is discarded. You can use the dummy fluid texture provided by forge - forge:items/bucket_fluid if your bucket is of the same shape as vanilla's, otherwise you need to create it yourself. cover: The bucket's texture that has fluid in it, but the fluid's pixels are transparent. If you are using forge's blockstates you can also pass some custom data: fluid: the name of the fluid to put in the bucket when baking. If this is not specified water is used as a default fluid. flipGas: whether or not to flip your texture upside-down when the fluid is a gas. applyTint: whether to tint the fluid's textures based on the fluid's colour. Actually you can read the javadoc yourself - ModelDynBucket#process. If you need an example of using the dynamic bucket model with custom buckets - here is one. Note that the example uses forge's blockstates to define the bucket's model, not a model json. And yeah, these parameter names make no sense. I can kinda see naming strings as str_something, although that is actually what's called a Hungarian notation(kinda, but close enough for me to classify this as one) and has absolutely no place in modern programming whatsoever(and I think you are the first person I've ever seen to apply it to java code, congratulations), but why is Item also named like that? Or an int? This makes zero sense.
    1 point
×
×
  • Create New...

Important Information

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