Jump to content

Add another render player event


TrashCaster

Recommended Posts

In the Render Player class, we have 2 events. The first one is called right at the beginning of the method, and the second at the very end. My proposal is to add one "in-between". Particularly, after the function call that updates the player model (func_177137_d), but before the player is rendered (super.doRender).

 

This would give us the ability to change the model transforms before the render has occurred. Otherwise, we have to cancel the render, and re-render with our own code. And I am almost certain this could conflict with other mods with the same goals.

 

If there is another way to do this, by all means, share. But if the only way to do this is with awkward, and ridiculous work arounds, then I think this is a very fair proposal.

Link to comment
Share on other sites

  • 2 weeks later...

The player model. The various ModelRenderer parts. If we could change that before the render based on certain conditions, such as certain items being equipped, or certain other attributes. Player size too, by calling GlStateManager.scale(), and so on. Otherwise we are using RenderPlayer API, and I feel it would be best to have an event fired from Forge, rather than have an "API mod" to handle it. This way it would always behave as intended, and it would mean that any bugs that are fixed remain consistent, and not have to wait for an update to said "API mod".

Link to comment
Share on other sites

In 1.7.10 you could use RenderPlayerEvent.Specials.

Now since is depercated, you supposed to use LayerRenderer, wich i can see its advantage, but i think you can only add additional models(layers) to the player model.

Maybe if you check the various layers within RenderPlayer, you could achieve whatever you want.

 

If not, wait for RenderPlayerAPI or beg more to Lex.

 

 

Link to comment
Share on other sites

Specials was never designed to allow you to modify other people's rendering.

The problem with 'RenderPlayer API' is it's a 'slap everything together and unmanage everything because people will fuck with everything' Which is extremely bad practice when it comes to an 'api'

Who 'wins' in situations when more then one person wants to do something. The layer system has a constant base that people append to.

You'll need to be VARY specific about what you want. So far you've just said you want to change 'scale' and 'some rotation'

If you actually talk specifics maybe Fry can come along and design something that isn't a 'lets throw it all together and *hope* it works!'

I do Forge for free, however the servers to run it arn't free, so anything is appreciated.
Consider supporting the team on Patreon

Link to comment
Share on other sites

Just to be clear, Lex, your concern is deciding which mod would get the "priority" of the render changes, correct?

 

I can try to think up something that could be implemented to introduce "compatibility" between mods.

 

I'm thinking something along the lines of an animation registry with different compatibility parameters, like "mix", "dominant", "submissive", and so on.

 

Like if you register an animation key for your mod, decide how that animation should "play with other mods", and have an event that fires on animation call to the correct mod with the animation name as a parameter.

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.

Announcements



×
×
  • Create New...

Important Information

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