Skip to content

Custom (Variable) #378

@ennvina

Description

@ennvina

Request to add a variable that binds to any custom-made information

  • Which name for the new variable?
    • "custom"
  • How many bits to use for the hash?
    • 1 bit that tells "the custom info is activated"
    • Side note: having only 1 bit is exceptional, all variables should have at least 2 bits (1 bit for on + 1 bit for off)
    • But it doesn't make sense to create a custom information and then say "I don't want it"
  • Which name for the condition that maps to the above hash?
    • "custom", a boolean flag
    • true maps to "the custom information is activated"
  • Which name for the import flag that enables this variable?
    • "custom"
  • Does the import rely on a dependency, and if yes, what is it?
    • Yes, "custom", a table that holds two items:
      • isActivated, a function that fetches from scratch if the custom information is activated, used by fetchAndSet
      • events, a table of key/value pairs, where the key is the event name (string) and the value is the function invoked by the event
    • The table will be stored in the bucket as is as the custom table
  • Which functions of the game API can fetch the information?
    • No baseline function, each custom information will use their own game API functions
  • Which events of the game API indicate a state change?
    • No baseline event, each custom information will use their own game API events
  • Should we create a new class for this variable?
    • Yes, "custom"
    • Forced by this new variable (custom)
    • Ignored by no variables

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions