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

Mining interface #1

Open
EphDoering opened this issue Apr 25, 2023 · 1 comment
Open

Mining interface #1

EphDoering opened this issue Apr 25, 2023 · 1 comment

Comments

@EphDoering
Copy link

Hi, I saw in your bugs that mining should take time. I think it's probably easiest to use the built in mining api to do that:

  1. take control of the selection by setting player.game_view_settings.update_entity_selection=false
  2. select entity to mine via player.selected =
  3. make the player mine: player.mining_state.mining=true
  4. in an event like a cancel input, on_player_mined_item, etc. select a new mining target or restore selection control to the mouse.
@caspark
Copy link
Owner

caspark commented Apr 27, 2023

I'm not working on this right now, but that said: WOW, those new APIs definitely make a lot of things much easier to implement if I ever come back to hacking on this mod - thanks for the heads up!

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

2 participants