Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make enchanted items emit light #89

Closed
MithicSpirit opened this issue Nov 14, 2021 · 6 comments
Closed

Make enchanted items emit light #89

MithicSpirit opened this issue Nov 14, 2021 · 6 comments
Labels
enhancement New feature or request

Comments

@MithicSpirit
Copy link

It would be nice if enchanted items emitted a bit of light when being held/worn or on the ground. IMO the effect should be subtle, at around the same brightness as light level 3.

@MithicSpirit MithicSpirit added the enhancement New feature or request label Nov 14, 2021
@magnus-ISU
Copy link

I second this idea, came here to suggest this. I find myself very often

It would even be a fun extra mechanic if cursed enchanted items emit more light, like 6? That way there is some conceivable reason someone would want to make them, if Mojang won't add such an incentive themselves. Of course, this is maybe too stylized a decision in a functional mod.

If it doesn't seem to hard though, I might try to make this.

@magnus-ISU
Copy link

This was easy to implement (for items, not armor - might look into that next) and exists on my fork, which I will make a merge request for in a moment.

You can get the compiled binary here for now.

@LambdAurora
Copy link
Owner

Not to be rude but it isn't "as easy", what you did is half-assed in a way:

  • configuration?
  • what if this should only apply to some enchanted items?
  • etc.

@magnus-ISU
Copy link

... Generally when I think of how difficult a feature is to implement, I think of how difficult it is to actually get it working, not how difficult it is to add tons of customization options to it.
Considering this issue is open for months without any reply, that could indicate it is technically challenging to implement, which it clearly is not.

To respond to your ideas:
Configuration: okay, maybe you want a toggle which lets me turn on or off enchantment-glowing. Personally, I'm not sure if this is useful.
Dynamic lights are a feature which exists to give a player a specific kind of experience. There is no gameplay advantage to having them. In that scenario, I feel I would rather find the best experience as a developer and make that the mod than to add a dozen toggles for each feature that 1% of people will use. Even worse if you default to old, worse settings to make sure nothing ever changes. I was of the opinion that it makes sense for glowing magic tools you enchant to glow faintly (along with the other things that start magically glowing, the one making the most sense is enchanted apples, the least is probably written books but the textures glow so they should too), so I added that. I don't think this mod needs a comprehensive config screen giving the players tons of options, nor does it have one at the moment, so configuration didn't seem important.
But okay, you could even make a slider that goes from 0 to 15. Super configurable. The mod is also worse, because people are just going to set it to 15 and not need to use torches to see in caves rather than try to think about lighting.
But anyway, assuming the mod is well structured, this should not be a monumental task for you to add an int config option and an if statement around my addition.

Now if you want extra configuration for whatever reason, to exclude some glowing items from glowing or make them glow extra hard, that is going to be harder, regardless of whether the player or a modpack writer using whatever json api you've cooked up is doing.
However, you also have to ask yourself if this is useful. Every item that glints has the same glint animation, so some not glowing would be weird, and not add to the feature of "make stuff that glows actually glow" especially in the first iteration.

You gave two things about configuration, so I guess etc relates to even more configuration. This mod doesn't need it :P

Is there anything specific you feel should be changed?

@LambdAurora
Copy link
Owner

@magnus-ISU so, first of all I'm not asking for sliders, a lot of items can actually be modified using resource packs.

The thing is, mods are pretty opinionated and often reflect the views of the author, I'm not entirely convinced that an enchanted item should glow, tho a Flame bow or a Fire Aspect sword giving up light would make sense to me.

This is why I'm adding toggles, with defaults which reflect how I play the game.
I added toggles for every entities because there is 2 group of people: those who want glow item frame emitting and those who don't. I personally don't like it emitting actual light since it gives another kind of light.

Those toggles are here to compromise, if I don't have them then I constantly have one group of people yelling at me because it doesn't fit their playstyle.

I'm not sure I'm entirely satisfied with just a toggle, maybe 2 toggles: glow and fire enchants, unsure yet.

@LambdAurora
Copy link
Owner

In LambDynamicLights 3.0.0 you can now match specific enchantments, please refer yourself to the resource pack API guide.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants