The SDK of this version is still being tested, and these pages are being updated with it: names, menus and procedures may still change before the release. If you build content for a platform already in production, follow the documentation of that version — pick it from the version menu at the top right.
Task System Nodes
These nodes allow you to interact with the Virtuademy Task System. They are provided by the Virtuademy-SDK-Environments package. The nodes of a procedure are in Procedure Nodes.
The nodes that take a Task use the Task component on the same GameObject as the graph when you leave the input empty; Fail Task and Unlock Task throw an error when there is none. The nodes that take a GameObject (the ones about results and states) work on the object that carries the task, which is the GameObject of the graph when you leave the input empty; given an object with no task they log a warning and do nothing.
Flow Nodes
Complete Task Node
🔍
Virtuademy>Flow>Virtuademy Tasks: CompleteTask
This Node completes a task within the Task System.
- ⬇️ Input:
- TaskToComplete (
Task), reference to the task to complete.
- TaskToComplete (
Complete Task With Result Node
🔍
Virtuademy>Flow>Virtuademy Tasks: Complete Task With Result
This Node completes a task with a result: how it went and a score. A procedure scores it; without one the task is completed as by Complete Task. A completion on a task that is already completed, failed or locked is ignored.
- ⬇️ Input:
- Task (
GameObject), the object that carries the task. If left empty, it defaults to the GameObject of the graph. - Outcome (
ETaskOutcome),Right(the default),WrongorPartial. A wrong outcome still completes the task, with 0 points. - Score (
float), from 0 to 1. A negative value (the default, -1) uses the outcome's own: right 1, wrong 0, partial 0.5. - Reason (
string), why, in a few words, for the summary's timeline and as the wrong feedback.
- Task (
Report Attempt Node
🔍
Virtuademy>Flow>Virtuademy Tasks: Report Attempt
This Node reports an attempt that does not complete the task. A wrong attempt is an error of the procedure: the task loses the procedure's error penalty and Max Errors counts it. A right attempt is progress only. Without a procedure it only raises the On Task Attempt event.
- ⬇️ Input:
- Task (
GameObject), the object that carries the task. If left empty, it defaults to the GameObject of the graph. - Outcome (
ETaskOutcome),Wrong(the default),RightorPartial. - Score (
float), from 0 to 1. A negative value (the default, -1) uses the outcome's own. - Reason (
string), why, for the summary's timeline and as the wrong feedback.
- Task (
Fail Task Node
🔍
Virtuademy>Flow>Virtuademy Tasks: Fail Task
This Node fails a task: its status becomes Failed. In a Task System with a procedure whose On Task Failed is Continue, the failed task scores 0 and the flow goes on to the next task; with End Procedure the procedure fails. In a Task System without a procedure, a failed task does not advance the chain.
- ⬇️ Input:
- TaskToFail (
Task), reference to the task to fail.
- TaskToFail (
Unlock Task Node
🔍
Virtuademy>Flow>Virtuademy Tasks: Unlock Task
This Node unlocks a task: its status becomes To Do, so the user can do it now.
- ⬇️ Input:
- TaskToUnlock (
Task), reference to the task to unlock.
- TaskToUnlock (
Expose Nodes
Get Task State Node
🔍
Virtuademy>Tasks>Virtuademy Tasks: Get Task State
This Node reads the state of a task.
-
⬇️ Input:
- Task (
GameObject), the object that carries the task. If left empty, it defaults to the GameObject of the graph.
- Task (
-
⬆️ Output:
- State (
ETaskState),Locked(not reachable yet),Todo(can be done now),InProgress,CompletedorFailed.
- State (
Event Nodes
On Task System Ready
🔍
Events>Virtuademy>Virtuademy Tasks: On Task System Ready
This event triggers when the Task System is ready and initialized.
- ⬇️ Input:
- TaskSystemReference (
TaskSystemVirtuademy), the Task System to watch. If left empty, it defaults to the one on the same GameObject.
- TaskSystemReference (
On Task Completed
🔍
Events>Virtuademy>Virtuademy Tasks: On Task Completed
This event triggers when a task is completed. It is also raised when a task fails, with its completed value false: use On Task Failed to react to failures only.
- ⬇️ Input:
- TaskReference (
Task), reference to the task to monitor.
- TaskReference (
On Task Unlocked
🔍
Events>Virtuademy>Virtuademy Tasks: On Task Unlocked
This event triggers when a task is unlocked: its status becomes To Do.
- ⬇️ Input:
- TaskReference (
Task), reference to the task to monitor. If left empty, it defaults to the one on the same GameObject.
- TaskReference (
On Task Failed
🔍
Events>Virtuademy>Virtuademy Tasks: On Task Failed
This event triggers when a task fails, and only then.
- ⬇️ Input:
- TaskReference (
Task), reference to the task to monitor. If left empty, it defaults to the one on the same GameObject.
- TaskReference (
On Task Attempt
🔍
Events>Virtuademy>Virtuademy Tasks: On Task Attempt
This event triggers for every result reported on a task, attempts and completions, on this client or by another user of a shared procedure.
-
⬇️ Input:
- Task (
GameObject), the object that carries the task to monitor. If left empty, it defaults to the GameObject of the graph.
- Task (
-
⬆️ Output:
- Outcome (
ETaskOutcome),Right,WrongorPartial. - Score (
float), from 0 to 1. - Reason (
string), why, when the result has one. - IsLocalActor (
bool), whether this client's user produced it.
- Outcome (