QUESTIONNAIRES / PRESENTATION
3D game
Presents an activity within a 3D scene. The Studio visual preset begins with a sorting activity.
1. What the learner does and sees
Presents an activity within a 3D scene. The Studio visual preset begins with a sorting activity.
Use it when spatial interaction adds value and there is also an accessible alternative in HTML.
2. Create in Studio
This is the normal path if you are creating the course visually. You don't need to write JSON or execute commands.
- Abre Studio.Use the hosted editor or the Studio you have integrated into your project.
- Add the activity.In Add content, abre Games and choose 3D game.
- Edita visualmente.Change statements, responses, and options with editor controls. The JSON remains as an advanced view, not a requirement for use.
- Check the learner View.Play the activity before downloading or saving the course.
3. Content requirements
- The Studio preset creates a question of type Ordering with complete solution.
- The activity requires embedded solutions and distinguishable texts.
- The Player can also reproduce 3D activities of type Matching and Classification when they are generated by Toolkit and fulfill their full contracts.
- If the physics cannot be initiated, the experience preserves a functional alternative.
4. Valid data example
This block shows a complete and valid questionnaire for this presentation. It is used to understand the format or to walk through the CLI; If you use Studio, the editor generates this structure for you.
{
"schema": "https://p2lrn.org/schema/native-questionnaire/0.4.0",
"version": "0.4.0",
"title": "Order the water cycle",
"language": "en",
"grading": {
"mode": "embedded-key"
},
"questions": [
{
"id": "q1",
"type": "ordering",
"prompt": "Order the stages",
"points": 3,
"items": [
{
"id": "i1",
"text": "Evaporation"
},
{
"id": "i2",
"text": "Condensation"
},
{
"id": "i3",
"text": "Precipitation"
}
],
"solution": {
"order": [
"i1",
"i2",
"i3"
]
}
}
]
}5. How to read the example
The example uses sort because it is the path that Studio currently offers to create a 3D Game. The three elements and solution.order produce a complete test.
6. Create by CLI — advanced alternative
Use this tour only if you are generating the course by code. Requires Toolkit installed via NPM. The file quiz.json It must contain a valid questionnaire like the example above.
p2lrn-create add-questionnaire ./workspace ./quiz.json \
--key quiz \
--title "3D Game" \
--renderer "https://p2lrn.org/renderer/questionnaire/3d-order-match"
p2lrn-create build ./workspace ./course.p2lrn --strict-profiles--renderer Select the preferred presentation. It does not create a second copy of the questions: the content remains the native questionnaire.
7. Technical presentation identifier
Typically Studio sets this up for you. You only need this identifier when you select presentation from code, CLI, or the viewer.
https://p2lrn.org/renderer/questionnaire/3d-order-match
https://p2lrn.org/profile/native-questionnaire
application/vnd.p2lrn.questionnaire+json
8. Interaction and accessibility
The scene is accompanied by equivalent HTML controls. The learner can complete the activity without relying exclusively on pointing or dragging 3D objects.
9. Completion and scoring
The scene and alternate controls update the same state. Completion and scoring use the common questionnaire contract.
To save the result on your platform, see Events and Host Adapter.
10. Try the example
Open the demo package in the real viewer and check the interaction before integrating it.