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

Global Toggle, Load from file and new Getter/Setter Support #3

Open
Ruthoranium opened this issue Mar 20, 2022 · 0 comments
Open

Global Toggle, Load from file and new Getter/Setter Support #3

Ruthoranium opened this issue Mar 20, 2022 · 0 comments

Comments

@Ruthoranium
Copy link

This object is really nice but it lacks in some areas. so I made a list of some additions that should be looked at.

  • Some Global functionality. (Like INI++v1.5 Global Data/Key) where if there is copies of the object on multiple frames with a key, it would all be the same.
  • Load a JSON from a path. so far the a work around is to make a edit box and load it from string. Its annoying to do this extra step but its ok. I rather like to see it built in.
  • Shorter way to Get or Set JSON data. I thought of something like this:

For Expressions:
getFloat("JSON Object", "Player[HP]")
getInt("JSON Object", "Player[Level]")
getString("JSON Object", "Player[Other][0]")
getBool("JSON Object", "Player[canBuff]") // Returns 0 for False, 1 for True

For Actions :
Set Float > "Player[HP]" > 25.0
Set Int > "Player[Level]" > 5
Set String > "Player[Other][0]" > "NewSomething"
Set bool > "Player[canBuff]" > 1 // Turns into true if 1, false if 0

example json:

{
    "Player": {
        "HP": 100.0,
        "Level": 4,
        "Other": ["Something1", "Something2"],
        "canBuff": true
    }
}
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

1 participant