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

Store variables on the same scoreboard #149

Open
MysteryBlokHed opened this issue Jan 12, 2023 · 0 comments
Open

Store variables on the same scoreboard #149

MysteryBlokHed opened this issue Jan 12, 2023 · 0 comments
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@MysteryBlokHed
Copy link
Owner

Currently, all variables are stored on separate scoreboards under the --databind username. This means that for every single variable in a Databind project, a new scoreboard is created. This is unnecessary and makes it much harder to manage scoreboards.

An alternative idea is to instead store all variables on the same scoreboard (called something straightforward like databind or databind-vars) as different pseudo-users.

For example, the following code:

func main
tag load
    var foo := 1
    var bar := 2
end

Would now generate something like:

scoreboard objectives add databind-vars dummy
scoreboard players set --var-foo databind-vars 1
scoreboard players set --var-bar databind-vars 2

Commands like tvar would, of course, also have to be modified internally.

For #148: Instead of customizing the name of the --databind user, the config option would customize the name of the scoreboard.

@MysteryBlokHed MysteryBlokHed added the enhancement New feature or request label Jan 12, 2023
@MysteryBlokHed MysteryBlokHed added this to the Databind 0.8 milestone Jan 12, 2023
@MysteryBlokHed MysteryBlokHed self-assigned this Jan 12, 2023
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

No branches or pull requests

1 participant