mineflayer-statemachine icon indicating copy to clipboard operation
mineflayer-statemachine copied to clipboard

Improvements into webservice layout for the huge bots

Open sefirosweb opened this issue 2 years ago • 11 comments

Hello guys, as I commented in some threads for huge bots it is quite difficult to manage what state it is in and the current interface does not help much

Therefore, I prepared some changes that I think can help the community

Changes:

  • Added bar to resize the panel of behaviors and canvas image

  • Navigate within states doing double click on state,

    • if clicked to "start" state, they will up 1 level, will be appears a "up arrow" image

    • Only can navigate if the state have sub nested states, will be appears a "down arrow" image

  • The tree of nested behavior has been changed, I used a new library "tree.js" to help him to generate the new tree,

    • Added buttons to open all / close all / "auto open" to track the current state active it will open the states automatically
  • Added a example using nested behaviors with typescript

    • I think is important to have a typescript example to show to new users how can make it with better practices
    • For that i needed to add tsconfig.eslint.json to lint the code but ignore it from build
  • Small issues fixed (name of state machine, types)

Preview: https://www.youtube.com/watch?v=-X3EefyDvJg

This ticket can be closed: https://github.com/PrismarineJS/mineflayer-statemachine/issues/115

sefirosweb avatar Jan 28 '23 13:01 sefirosweb

this is big

@sefirosweb would you like to keep maintaining this package ?

rom1504 avatar Mar 04 '23 18:03 rom1504

Hello @rom1504 , yes there are many changes I tried to make it as small as possible, but with the fact that more data is required and a restructuring of the tree has led me to make this code,

For maintenance I would be happy to help, for me this tool is vital for large bots

sefirosweb avatar Mar 05 '23 08:03 sefirosweb

I'm just getting into statemachine development and immediately noticed the primitive nature of the web-view, so this seems crazy useful!

sad to see it's stuck, is there no maintainer who can make sense of the changes or what's the problem with this?

kaduvert avatar Sep 03 '23 09:09 kaduvert

@kaduvert yes, can you try this PR? If you like it better than master we can merge

rom1504 avatar Sep 03 '23 10:09 rom1504

yeah, seems like a good idea. will start my statemachine endeavours off with this and give feedback once i think i've done enough statemachine stuff to have tested this thoroughly.

kaduvert avatar Sep 03 '23 11:09 kaduvert

so after my statemachine developments i greatly preferred the experience of this over master, encountered no errors. haven't looked much at the code but apart from some inconsistent styling / linting it seems to be fine

kaduvert avatar Oct 19 '23 17:10 kaduvert

Hey guys, could you please merge the pr? I have more ideas to improve the package but I don't want to mess the code anymore.

sefirosweb avatar Nov 05 '23 11:11 sefirosweb

@rom1504 any news from this topic?

sefirosweb avatar Mar 16 '24 00:03 sefirosweb

@sefirosweb have you seen my PR? as said, i have no issues with your code, but i noticed some inconsistent styling / linting. i conveniently created a pull request for you to fix this: https://github.com/sefirosweb/mineflayer-statemachine/pull/1

if you could merge it i too would fully approve of these changes

kaduvert avatar Mar 16 '24 17:03 kaduvert

@sefirosweb have you seen my PR? as said, i have no issues with your code, but i noticed some inconsistent styling / linting. i conveniently created a pull request for you to fix this: sefirosweb#1

if you could merge it i too would fully approve of these changes

I didn't saw 🤣 , done i merge it!

sefirosweb avatar Mar 16 '24 18:03 sefirosweb

@rom1504 why don't you merge this or #197 and #198 ? it's all purely additions improving the project and no breaking changes.

i get that you're scared because there's no maintainer, but there's a small community taking care of this on which you can rely on to steer the project in the right direction.

don't overcomplicate things, if something doesn't work someone will create a pr to fix it. worst case you just revert a breaking pr?

kaduvert avatar Apr 10 '24 09:04 kaduvert