Skip to content

Game: Allow storywriter to customize question prompt of the quiz #3011

Open
@CYX22222003

Description

@CYX22222003

Description

Under the current implementation, the question prompt of the quiz feature is fixed. It will be better if story writer can customize the prompt in the txt file. This may require a modification of the syntax of the txt file as well as the parser. The prompt field in the Question type will be used to capture the value of customized prompt.

export const questionPrompt = 'What is the correct answer?';

export type Question = {
question: string;
prompt?: string;
speaker: SpeakerDetail;
answer: Number;
options: Option[];
};

Related discussion

#2919

Sample of quiz

quizzes
    sourceManual
        0
        What is the pre-declared constant for: The Number value for π, the ratio of the circumference of a circle to its diameter?
        answer: 3
        option
            apple_Pi
            @ershk, thinking, left
            ...Are you hungry or something?
        option
            math_Pi
        option
            math_pi
        option
            math_PI

        1
        What is the pre-declared constant for: The Number value for the base-10 logarithm of e, the base of the natural logarithms?
        answer: 2
        option
            math_L10
        option
            math_LOG10
        option
            math_LOG10E
        option
            math_L10E

    telebayConsole
        0
        The first expression is: 100 + 37; What is the simplified form for this expression?
        answer: 3
        option
            13
        option
            37
        option
            100
        option
            137
            @scottie, smile, left
            Great! Looks like that worked.

        1
        The second expression is: (6 + 8) * 7 + 2 * 3; What is the simplified form for this expression?
        answer: 1
        option
            103
        option
            104
            @scottie, smile, left
            Great! Looks like that worked, too.
        option
            300
        option
            378

Metadata

Metadata

Assignees

No one assigned

    Labels

    gameAll game related ideas, bugs, fixesminorLess important than important, but more than nice-to-have

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions