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

Better cool down #35

Open
FlowpxD opened this issue Aug 11, 2022 · 28 comments
Open

Better cool down #35

FlowpxD opened this issue Aug 11, 2022 · 28 comments

Comments

@FlowpxD
Copy link

FlowpxD commented Aug 11, 2022

Geysermc Attack cooldown sucks. Its very annoying to see. Can u change the cooldown so its matches java edition.

@hw2007
Copy link

hw2007 commented Apr 27, 2023

Yes, I think that should be improved! Great idea!

@onebeastchris
Copy link
Member

onebeastchris commented Apr 27, 2023

How do you imagine us doing that?
We offer 3 options atm, which each player can choose while playing (pause menu -> settings -> server settings tab while on the server with geyser). Or in the geyser config as a server default.
There are three options for the cooldown:

  • actionbar
  • title
  • no cooldown indicator.
    That's what's currently implemented - if you have a specific idea for an indicator that's possible with the technical limitations of bedrock, feel free to tell us ;)

@hw2007
Copy link

hw2007 commented Apr 28, 2023

In response to @onebeastchris: I'm not fully aware of how texture packs work, but could you have it so that a select set of unicode characters are retextured to show the cooldown stages? Then, rather than showing those dots under your crosshair, you cycle through the retextured characters?

@letsgoawaydev
Copy link
Contributor

It could be changed using unicode, and a custom texture, however this would cause issues for players who dont have the texture pack because texture packs arent forced to on in geysers config.

If there was a "enable-geyser-optional-pack-features" option in the geyser config, or even, "start-cooldown-text","middle-cooldown-text","end-cooldown-text" in the geyser config, this could be made.

@letsgoawaydev
Copy link
Contributor

a better name could be "enable-optional-pack-cooldown"

@letsgoawaydev
Copy link
Contributor

1 similar comment
@letsgoawaydev
Copy link
Contributor

@letsgoawaydev
Copy link
Contributor

this line seems to be the line that defines what text the cooldown shows: https://github.com/GeyserMC/Geyser/blob/90c4ea78a7285aa734e94400ec7f75e5b2f8ef0e/core/src/main/java/org/geysermc/geyser/util/CooldownUtils.java#L129C12-L129C12

so ill mess around with the code and see if i can make a better cooldown

@letsgoawaydev
Copy link
Contributor

I have just created the java cooldown in minecraft bedrock with the same texture, however this requires changes to the geysermc code itsself, here is how it looks https://www.youtube.com/watch?v=DrMvQ_-YxNU

@hw2007
Copy link

hw2007 commented Aug 26, 2023

I have just created the java cooldown in minecraft bedrock with the same texture, however this requires changes to the geysermc code itsself, here is how it looks https://www.youtube.com/watch?v=DrMvQ_-YxNU

That looks way better!! It would be really cool if that could get implimented

@hw2007
Copy link

hw2007 commented Aug 26, 2023

I have just created the java cooldown in minecraft bedrock with the same texture, however this requires changes to the geysermc code itsself, here is how it looks https://www.youtube.com/watch?v=DrMvQ_-YxNU

That looks way better!! It would be really cool if that could get implimented

Also, could you send me the bedrock resource pack just for interest..?

@letsgoawaydev
Copy link
Contributor

ill do that when i get home but thanks for your interest! ill also make a fork of geyser with the code changed for it and i might make a pull request but obviously make it toggleable

@letsgoawaydev
Copy link
Contributor

like i said, it wont work with the current geyser code. so you cant use the texture pack on any geyser server, unless its my fork of geyser that ill make public when i get home

@letsgoawaydev
Copy link
Contributor

but im planning to make a pull request when its properly implemented so it can be added to the main geyser plugin

@hw2007
Copy link

hw2007 commented Aug 27, 2023

Okay cool!

@letsgoawaydev
Copy link
Contributor

the plan for the geyser code is that it will auto detect if the geyseroptionalpack is in the packs folder, then if it is, if the player accepts it then use the custom cooldown.

i also need to figure out how i can extract the java attack indicator texture to be used in the bedrock texture pack automatically in the prepare_packs.sh file but it seems like it will be really hard as java only uses two textures for the cooldown and overlaps them

@Camotoy
Copy link
Member

Camotoy commented Aug 27, 2023

For complete transparency, it has been in long-term plans to create the GeyserOptionalPack within Geyser and make it a mandatory pack (for things like block and item display entities). The only time this would be an inconvenience would be proxies, which can be easily rectified if we still provide a place to download or create the pack separately.

@letsgoawaydev
Copy link
Contributor

if you make it mandatory, then maybe geyser could generate the pack when it downloads the locale's from the minecraft jar, because correct me if im wrong but isnt that the full minecraft jar? meaning we could extract the assets and generate the pack that way

and why would it be an issue for some proxies? im not sure why proxies could mess up downloading texture packs

@letsgoawaydev
Copy link
Contributor

letsgoawaydev commented Aug 27, 2023

Also, here is the custom geyser code i was talking about
https://github.com/letsgoawaydev/Geyser
and the pack with the texture: https://github.com/letsgoawaydev/GeyserOptionalPack

Also just wanted to add, because this only uses one character at a time, it should lag less on lower end devices like the Nintendo Switch that struggle with rendering text.

@hw2007
Copy link

hw2007 commented Aug 28, 2023

Also, here is the custom geyser code i was talking about https://github.com/letsgoawaydev/Geyser and the pack with the texture: https://github.com/letsgoawaydev/GeyserOptionalPack

Also just wanted to add, because this only uses one character at a time, it should lag less on lower end devices like the Nintendo Switch that struggle with rendering text.

Did you open a pull request for that? If not you should, it would be cool to see that implimented

@letsgoawaydev
Copy link
Contributor

Also, here is the custom geyser code i was talking about https://github.com/letsgoawaydev/Geyser and the pack with the texture: https://github.com/letsgoawaydev/GeyserOptionalPack

Also just wanted to add, because this only uses one character at a time, it should lag less on lower end devices like the Nintendo Switch that struggle with rendering text.

Did you open a pull request for that? If not you should, it would be cool to see that implimented

there are a few caveats with making a pull request

it uses a bedrock texture, which
cant be extracted officially as using the bedrock-samples repository from mojang doesnt seem to have the specific texture used for the cooldown afaik

it also would be hard to extract from java as java only uses two textures, one for it being fully charged and one for it being fully depleted, then it overlays the two images accordingly and crops them, where as my texture is already precropped and switched to each frame accordingly

if we just pull requested the texture, im pretty sure it would break minecrafts eula as it uses mojang's copyrighted texture property

what geyser does is extract the files using the extract_assets.sh script in the repository files. however, my texture isnt officially from mojang and is custom modified by me using mojangs textures.

@letsgoawaydev
Copy link
Contributor

ive made a pull request which helps with the above issue, it will be much easier for me to generate the sprite sheet if the pull request is merged

@frogglen
Copy link

ive made a pull request which helps with the above issue, it will be much easier for me to generate the sprite sheet if the pull request is merged

I would like to test this version of geyser and the resource pack, how can I test it before time?

@letsgoawaydev
Copy link
Contributor

the pull request i made doesnt include the custom cooldown, but just python code of the asset extractor

ill make it extract the cooldown eventually if there ever is support added

@letsgoawaydev
Copy link
Contributor

UPDATE ON THIS
it is now more possible as mojang have split the attack indicators
image

@aShanki
Copy link

aShanki commented Apr 30, 2024

Can we possibly bump this or someone please reply with a solution, as I'd love a client side texture pack attack cooldown so that the lag won't mess with the cooldown indicator.

@letsgoawaydev
Copy link
Contributor

letsgoawaydev commented May 4, 2024

Can we possibly bump this or someone please reply with a solution, as I'd love a client side texture pack attack cooldown so that the lag won't mess with the cooldown indicator.

I recently created a plugin that has this custom cooldown workaround. Heres the github, but its a workaround for now until its eventually added to the GeyserOptionalPack https://github.com/GeyserExtras/GeyserExtras

Also I made the plugin delay the cooldown indicator based on ping if you have forward player ping enabled in geysers config to ensure that its as accurate as possible.

@aShanki

This comment has been minimized.

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

No branches or pull requests

7 participants