QtCraft API C++ classes QML types Handbook

QcWorldOptionParser Namespace

Parses worldgen/options.json of a content pack (decision E-917): the groups, options and presets of the world generation. More...

Header: #include <common/content/worldgen/QcWorldOptionParser.h>

Variables

const qsizetype maxEntries

Functions

QcResult<QcWorldOptionSet> parseOptionSet(const QJsonObject &json, const QString &packNamespace)

Detailed Description

Whether a target exists and suits the range is checked later, against the whole content (QcWorldOptions::check), since a pack may set options on another pack's content.

Variable Documentation

const qsizetype QcWorldOptionParser::maxEntries

At most this many options, groups and presets per pack, and values per preset.

Function Documentation

QcResult<QcWorldOptionSet> QcWorldOptionParser::parseOptionSet(const QJsonObject &json, const QString &packNamespace)

Returns the groups, options and presets read from json, or the first error. Names are qualified with packNamespace.