Are we allowed to request ideas for mods, or just give input on what we think would be a cool mod?
Input is always fun. We have a modder that is looking for an idea. Also, HotBarGRO has been added to the mod list, as well as being downloadable. Big mod, and little mods, coming soon!
I am working on a mod where I need a translucent entity. I would like to use the mod here, but it is for 1.0 and the download link doesn't work. If the download worked I could look at the source and see what you did, or maybe you could share?
EDIT
I figured it out. For anyone else wondering, MC renders several "passes". The first pass is the main model, and this pass does not support transparency (alpha). In order to get around this restriction, do not render the main model at all. Instead, render an "extra" model. This extra model does support transparency, and you can change the amount of transparency with GL11.glColor4f(float red, float green, float blue, float alpha) in shouldRenderPass(...) in the Render file for the Entity. Each argument is on a scale of 0.0 - 1.0. If you have a texture that is already transparent, and this is what you want to use, you don't need the call to glColor4f(...). Here is an example for my mob. It becomes more transparent with more light:
The texture I'm using is completely solid. The code dynamically adds the transparency. If you only need a certain amount of transparency, regardless of any conditions, you should instead add the transparency in the texture (and leave out glColor4f(...)).
The renderer goes through the main pass (which we ignore), then it goes through 4 extra passes (numbered 0-3). My code is similar to that of the slime: it enables blending and sets the model to the secondary main model, which is identical to the main model except the main model won't be rendered. On the first pass, it enables transparency (blending) and sets the amount of transparency, and finally returns a positive number.
All positive return values are treated the same for this function ("yes, render this pass"), except for 15. Zero and all negative numbers mean "no, don't render anything this pass".
A return value of 15 does the same as other positive numbers, but it also enables the "glint" texture for that pass.
I hope I've explained all this well enough for anyone here looking for information on making mobs translucent!
Input is always fun. We have a modder that is looking for an idea. Also, HotBarGRO has been added to the mod list, as well as being downloadable. Big mod, and little mods, coming soon!
It has similar effects, with fewer side effects and targeting the hotbar instead, but we are not directly affiliated with Pfizer or its affiliates.
EDIT
I figured it out. For anyone else wondering, MC renders several "passes". The first pass is the main model, and this pass does not support transparency (alpha). In order to get around this restriction, do not render the main model at all. Instead, render an "extra" model. This extra model does support transparency, and you can change the amount of transparency with GL11.glColor4f(float red, float green, float blue, float alpha) in shouldRenderPass(...) in the Render file for the Entity. Each argument is on a scale of 0.0 - 1.0. If you have a texture that is already transparent, and this is what you want to use, you don't need the call to glColor4f(...). Here is an example for my mob. It becomes more transparent with more light:
The texture I'm using is completely solid. The code dynamically adds the transparency. If you only need a certain amount of transparency, regardless of any conditions, you should instead add the transparency in the texture (and leave out glColor4f(...)).
The renderer goes through the main pass (which we ignore), then it goes through 4 extra passes (numbered 0-3). My code is similar to that of the slime: it enables blending and sets the model to the secondary main model, which is identical to the main model except the main model won't be rendered. On the first pass, it enables transparency (blending) and sets the amount of transparency, and finally returns a positive number.
All positive return values are treated the same for this function ("yes, render this pass"), except for 15. Zero and all negative numbers mean "no, don't render anything this pass".
A return value of 15 does the same as other positive numbers, but it also enables the "glint" texture for that pass.
I hope I've explained all this well enough for anyone here looking for information on making mobs translucent!