Plugin Config

Read configuration files (TOML) into an entity instance.

Entity Types

NamePropertiesData TypeSocket Type
config_filefilenamestringnone
configurationobjectoutput

Platform Compatibility

PlatformCompatibility
Linux
MacOS
Windows

Repository

NameRepository
inexor-rgf-plugin-confighttps://github.com/inexorgame/inexor-rgf-plugin-config

Usage

Usage (GraphQL) {.tabset}

Read in a configuration

mutation {
  instances {
    entities {
      create(
        type: "config_file"
        id: "aed6c9b0-e495-4423-baeb-5597b66416f4"
        properties: [
          {
            name: "filename"
            value: "config/plugins.toml"
          }
        ]
      ) {
        id
        type {
          name
        }
        properties(
          names: [
            "filename"
            "configuration"
          ]
        ) {
          name
          value
        }
      }
    }
  }
}

Get all configurations

query getAllConfigs {
  instances {
    entities(type: "config_file") {
      id
      label
      description
      properties {
        name
        value
      }
    }
  }
}

"Reload" a configuration

By triggering the property `filename' the configuration file will be read again:

mutation reloadPluginsConfig {
  instances {
    entities {
      update(
        id: "aed6c9b0-e495-4423-baeb-5597b66416f4",
        properties: [
          {
            name: "filename",
            value: "config/plugins.toml"
          }
        ]
      ) {
        id
        type {
          name
        }
        properties {
          name
          value
        }
      }
    }
  }
}