class MAGES::SceneGraph::QuestionAnswerConditionData

Overview

Passes based on the answer that was submitted to a Question action. More…

class QuestionAnswerConditionData: public MAGES::ConditionData
{
public:
    // enums

    enum AnswerType;

    // fields

    ActionReference action = new ActionReference();
    AnswerType answerType = AnswerType.AnyCorrectAnswer;
    int answerIndex = 0;

    // methods

    virtual override bool Check();
};

Inherited Members

public:
    // enums

    enum CheckResult;

    // fields

    bool fail = false;
    bool negate = false;
    bool critical = false;
    string description = string.Empty;

    // properties

    bool IsInitialized;

    // methods

    void InitializeInternal(BaseActionData data);
    void UndoInternal();
    virtual void Initialize();
    virtual void Undo();
    CheckResult CheckInternal();
    virtual bool Check();

Detailed Documentation

Passes based on the answer that was submitted to a Question action.

The three answer types are independent predicates, not opposites: on a multi-select question both Any Correct Answer and Any Incorrect Answer can hold at the same time.

Methods

virtual override bool Check()

Performs the check and returns whether it passed or failed.

Returns:

A value indicating whether the condition is satisfied or not.