DEV (dev) - Script
Educators & Designers: help improving this quest!
Comments and feedback: discuss in the Forum
Improve translations: comment the Google Sheet
Improve the script: propose an edit here
quest_start
// dev | DEV
//
// Country: Italy - Firenze
// Content: Living document for testing Yarn features
// and documenting available commands
//--------------------------------------------
// INIT
// every quest starts with an INIT node
// to initialize existing variables and declare new ones
// title of a node must be unique to this quest
// create a new node for anything that must be referenced multiple times
// that makes understanding of the flow easier
// position is used to place the node in the Graph view in the Editor
// group is used to organize the nodes in the Graph view in the Editor
group: docs
// tags are used to add metadata to the node
// actor is the speaking character, used mostly for voice overs
// - Default | female, neutral, clear diction, mid pitch, minimal emotion
// - SILENT | no spoken words, but can use non-verbal sounds
// - NARRATOR | male, warm, engaging, enthusiastic
// - SPECIAL | fx voice, like a robot or an animal
// - ADULT_F | warm, conversational, adaptable
// - ADULT_M | natural, medium pitch, flexible tone
// - SENIOR_F | warm, gentle rasp, storyteller cadence
// - SENIOR_M | deeper, slower, authoritative but kind
// - KID_F | bright, energetic, quick speech, high pitch
// - KID_M | playful, curious, lively tone, mid-high pitch
actor: NARRATOR
// color us used like this:
// - red for important nodes like init and quest end
// - blue for NPCs
// - yellow for items
// - green for tasks
// - purple for activities
color: red
// type is used to identify special nodes like panel, Quiz
// - panel is fullscreen
// - panel_endgame is a special panel that shows the endgame screen
// - quiz shows a quiz with image choiches
type: panel
---
// these are the common variables
<<set $EASY_MODE = false>>
<<set $IS_DESKTOP = false>>
<<set $TOTAL_COINS = 0>>
<<set $COLLECTED_ITEMS = 0>>
<<set $MAX_PROGRESS = 0>>
<<set $CURRENT_PROGRESS = 0>>
<<set $CURRENT_ITEM = "">>
// here we declare new variables for this quest
<<declare $doorUnlocked = false>>
Benvenuti alla missione DEV! #line:0973921
<<card food_baguette>>
Puoi usare questa missione per testare funzionalità e comandi. #line:0196a6d
<<asset backpack>>
// shadow line example
[MISSING TRANSLATION: You played the activity well!] #line:0597e46
DOCS_GLOBAL_VARIABLE
group: docs
---
<<if $EASY_MODE >>
[MISSING TRANSLATION: You are in EASY MODE!] #line:006edd6
<<else>>
[MISSING TRANSLATION: You are in NORMAL MODE!] #line:02f8aaa
<<endif>>
<<if $IS_DESKTOP >>
[MISSING TRANSLATION: You are on DESKTOP!] #line:0afe11a
<<else>>
[MISSING TRANSLATION: You are on MOBILE!] #line:0245038
<<endif>>
DOCS_ACTIONS
//--------------------------------------------
// DOCS COMMANDS
// these are the commands available in all Scripts
//--------------------------------------------
group: docs
---
// execute the configured action in the actionManager
<<action action_id>>
DOCS_ACTIVITY
group: docs
actor:
---
// launches an activity and set a yarn node to jump when completed
<<activity activity_setting_id return_node>>
// a third optional parameter can set the difficulty
<<activity activity_setting_id return_node tutorial>>
<<activity activity_setting_id return_node easy>>
<<activity activity_setting_id return_node normal>>
<<activity activity_setting_id return_node expert>>
// to get the result of a specific activity
// (0 = failed, >= 1 = completed)
<<if GetActivityResult("id_activity_setting") > 0>>
Hai svolto bene l'attività! #line:0872c3a
<<endif>>
// this returns the result of the activity played
<<if GetActivityResult("") > 0>>
<<endif>>
DOCS_AREA
group: docs
---
// set the area (walls), turnng off the previous one
<<area full_area>>
// switch off the current area.
<<area off>>
DOCS_ASSETS
group: docs
---
// instead of a card, uses a direct Asset Id
<<asset id_asset>>
// hides the current image
<<asset_hide>>
DOCS_CAMERA
group: docs
---
// focus the camera on a target (interactable, area, map point)
<<camera_focus palace>>
// back to player
<<camera_reset>>
DOCS_CARDS
group: docs
---
// uses the card Id to show a card
<<card food_baguette>>
// if accepts 2 additional parameters
// zoom - shows the card in zoom mode
// silent - shows the card without title / audio
<<card food_baguette zoom silent>>
// obviously can set just one of them
<<card food_baguette silent>>
<<card food_baguette zoom>>
// hides the current card
<<card_hide>>
DOCS_COOKIES
group: docs
---
// adds cookies to the player (can be negative)
<<cookies_add 5>>
<<if GetCookies() >= 10>>
<<endif>>
DOCS_INVENTORY
group: docs
actor: ADULT_F
---
// adds the item = card to the inventory (needs to be collectable!)
<<inventory id_card add>>
<<inventory id_card>> // same as add
<<inventory id_card remove>>
// Inventory has custom functions to check items
<<if item_count("flag_france") >= 2>>
Hai più di 2 bandiere della Francia #line:08a1058 #native
un'altra linea #line:0563122
<<endif>>
<<if has_item("flag_france")>>
Hai una bandiera della Francia #line:kidm_0b932d0
<<endif>>
<<if has_item_at_least("flag_france", 3)>>
Hai almeno 3 bandiere della Francia #line:0d694f1
<<endif>>
<<if can_collect("flag_france")>>
Puoi collezionare una bandiera della Francia #line:03da430
<<endif>>
DOCS_TASKS
group: docs
---
// starts a task
[MISSING TRANSLATION: You can add the decription with #task:id_task_configuration]
<<task_start id_task_configuration>>
// end a task... if you say nothing, its a success
<<task_end id_task_configuration>>
<<task_end id_task_configuration fail>>
<<task_end>> // or even without the id to end current task
DOCS_PARTY
group: docs
---
// makes a NPC join a party following the player
<<party_join interactable_id>>
// asks a NPC to leave the party
<<party_release interactable_id>>
// if no id, remove all
<<party_release>>
// the default formation in "line", but other are available
<<party_formation "line">>
<<party_formation "circle">>
<<party_formation "V">>
DOCS_QUEST
group: docs
---
// end current quest and calculate stars based on progress
<<quest_end>>
// end the current quest with n (0, 1,2,3) stars
<<quest_end 3>>
DOCS_TARGET
group: docs
---
// put a target element on a target
<<target target_chest>>
// removes any target
<<target off>>
DOCS_YARN_BUILTIN
group: docs
---
// --- Yarn built-in commands ---
<<wait 3>> // waits for 3 seconds
<<stop>> // stops the current dialogue>>
test_dialog
group: dialog
tags: noRepeatLastLine
---
[MISSING TRANSLATION: Enter the house #shadow:0f92df5]
il pesce è ancora qui #line:08da0cf #customtag #native
Burro! #line:05edb53
<<card butter>>
Buon burro #line:090e4bd
Opzione 2 #line:07243c2
Hai scelto 2 #line:03649cf
Opzione 3 #line:0c56f8c
Hai scelto 3 #line:0278662
Opzione 4 #line:0131912
Hai scelto 4 #line:077dcad
E questo è pesce #line:099d213
<<card food_fish>>
<<card food_fish zoom>>
Ci piace! #line:04d8ba8
Prima riga v1 #line:04a8afc
Prima riga v2 #line:08cbb53
test_inventory
group: inventory
---
Ho fame. Che ne dici di qualcosa da mangiare? #line:0bdf566
<<if has_item_at_least("food_baguette", 3)>>
Mi servono 3 baguette! #line:00c341e
<<inventory food_baguette remove>>
<<inventory food_baguette remove>>
<<inventory food_baguette remove>>
<<else>>
Non hai abbastanza baguette! #line:0c0d786
<<if has_item("food_fish")>>
Ma hai dei pesci! #line:06c9370
<<endif>>
Grazie. #line:0a7921b
<<endif>>
got_baguette
group: inventory
---
Hai trovato una baguette! #line:dev_got_baguette
<<inventory food_baguette add>>
got_fish
group: inventory
---
Un pesce sano! #line:dev_got_fish
<<inventory food_fish add>>
area_change
group: area
---
Ora ti lascio fare il giro. #line:0aa3b5d
<<area full_area>>
test_cards
group: cards
---
Adesso vi mostro alcune carte #line:05edfca
<<card food_fish>>
Per favore guarda i suoi dettagli #line:0adbe4f
<<card food_fish zoom>>
torna al menu e sfoglia le carte #line:017a620
e adesso... #line:04ade19
<<card food_baguette>>
Bello, vero? #line:04b02ce
<<card_hide>>
Torna subito al lavoro. #line:0970ed1
test_cookies
group: cookies
---
Vuoi 5 biscotti? #line:0eb42ea
SÌ #line:027a7a8
Ecco qua! Buon divertimento! #line:0e5578d
<<cookies_add 5>>
NO #line:0675243
Ok, niente biscotti per te! #line:0662df0
<<if GetCookies() >= 10>>
Hai un sacco di biscotti! #line:0d2d1d7
<<endif>>
test_camera
group: camera
---
Adesso vi mostro la mappa del parco giochi #line:0c58bd8
<<camera_focus map_tutorial>>
Capisci questo punto? #line:03e0224
<<camera_focus map_tutorial_detail>>
Ora guarda quel palazzo! #line:0c1b2e4
<<camera_focus palace>>
Bello, vero? #line:04daace
<<camera_reset>>
test_actions
tags:
group: actions
actor: KID_F
---
<<action activate_elevator>>
Azione Pre "pre_actions" e azione_post "post_actions" #line:0a67b25
Vuoi aprire il forziere? #line:03cae39
SÌ #line:067231b
<<action open_chest>>
NO #line:05d9657
<<action stop_elevator>>
task_collect_apples
tags:
group: tasks
color: green
---
<<if HasCompletedTask("collect_apples")>>
Grazie! Hai completato questo compito #line:dev_task_collect_apples_2
<<elseif GetCollectedItem("collect_apples") > 0 >>
Ho bisogno di più mele! #line:dev_task_collect_apples_3
<<else>>
<<jump task_collect_apples_info>>
<<endif>>
task_collect_apples_info
tags:
group: tasks
color: green
type: task
---
Raccogli 4 mele! #line:dev_task_collect_apples_1 #task:collect_apples
[MISSING TRANSLATION: This is the description of this task.] #line:063c743
<<task_start collect_apples task_collect_apples_done>>
task_collect_apples_done
tags:
group: tasks
color: green
---
Ben fatto! Torna al robot #line:dev_test_task_done_1
task_open_chest
tags:
group: tasks
color: green
---
<<if HasCompletedTask("open_chest")>>
Grazie! Ne avevo bisogno #line:073d718
<<else>>
Allunga la mano e apri quella cassa! #line:0c31fab
<<area off>>
<<target target_chest>>
<<task_start open_chest task_open_chest_done>>
<<endif>>
task_open_chest_done
tags:
group: tasks
color: green
---
Ben fatto! Hai aperto il baule. #line:04e697a
<<target off>>
item_chest
tags:
group: actions
color: yellow
actor: NARRATOR
---
Un bel baule! #line:dev_item_chest_1
<<action open_chest>>
npc_join_party
group: party
---
Vuoi unirti alla mia festa? #line:0b1f3e1
SÌ #line:0d1f4e3
<<party_join npc_party_1>>
Ora ti seguo! #line:019353a
NO #line:0a8e1c3
OK #line:0c4e4ec
npc_leave_party
group: party
---
Vuoi cambiare partito? #line:048e84e
Cerchio di formazione #line:00c2f84
<<party_formation circle >>
Linea di formazione #line:03d5333
<<party_formation line >>
Formazione V #line:08ea78a
<<party_formation v >>
Festa di rilascio #line:01f2e9a
<<party_release>>
test_quiz
group: quiz
tags:
type: quiz
---
Calcola 3*2 #line:dev_test_quiz_1 #card:fr_figure_triangle
quattro #line:dev_test_quiz_2 #card:number_4
<<jump test_quiz_wrong>>
sei #line:dev_test_quiz_3 #card:bouillabaisse
<<jump test_quiz_correct>>
otto #line:dev_test_quiz_4 #card:food_bread
<<jump test_quiz_wrong>>
[MISSING TRANSLATION: -> ten] #line:03cdf2b #card:food_olive_oil
<<jump test_quiz_wrong>>
test_quiz_correct
group: quiz
---
SÌ! Corretto. #line:0eb010e
test_quiz_wrong
group: quiz
---
No. Vuoi riprovare? #line:0e2b8d7
SÌ #line:08ff2b9
<<jump test_quiz>>
NO #line:042881c
endgame
group: endgame
color: red
---
Puoi terminare questa missione con... #line:027bdca
NOOOO non voglio finire #line:014a238
SÌ, finiamola #line:0751111
<<quest_end>>
<<jump close_game>>
close_game
group: endgame
color: red
type: panel_endgame
---
Questo è l'ultimo messaggio! arrivederci #line:01c70f4
NPCGIoconda
assetimage: antura_hero
---
<<asset food_tomato>>
Ciao, stefano #line:0c0329c
ti piacciono le foto? #line:0b9b60d
<<asset food_fish>>
vuoi arancia? #line:0c2bd41
<<asset food_orange>>
<<action play_sfx>>
vuoi olio? #line:034ed48
<<asset food_oil>>
<<action play_sfx>>
ora chiuso #line:0baeb5f
<<asset_hide>>
Ordine di attività #line:0087ab1
<<activity activity_test>>
<<jump activity_done>>
Suona sfx #line:0f02889
<<action play_sfx>>
Apri Baule #line:053f800
<<action open_chest>>
activity_done
---
Attività terminata. #line:0ce187d
test_setactive
---
Ora attiverò gameObject test_setactive #line:0ef2850
<<SetActive TestSetActive_Crate>>
E adesso lo spengo #line:0a360b1
<<SetActive TestSetActive_Crate false>>
Bello, vero? #line:06bd992
NPCGreeting2
assetimage: pirates
---
// <<activity activity_memory>>
Ciao #line:08ecb6c
Come stai? #line:00b7839
Bene #line:0991140
Buono a sapersi #line:0b3477e
Cattivo #line:08607a4
Oh, mi dispiace sentirlo #line:0e6ecb2
Neutro #line:05f3ea5
Capisco, spero che migliori presto #line:0802baf
Cosa vuoi fare con le monete? #line:0bcd506
NPCGreeting3
tags:
---
<<declare $coins = 0>>
Cosa vuoi fare con {0} monete? #line:0a1994c
Apri la porta #line:0e11bee
<<set $doorUnlocked = true>>
La porta è aperta #line:0cac01d
Resta a casa #line:07f4239
Tu resti a casa #line:079b16e
<<set $coins = $coins + 10>>
Chest_01
---
<<if $doorUnlocked>>
La porta è aperta #line:0e22a89
<<jump EntroInCasa>>
<<else>>
La porta è chiusa #line:05086bc
<<endif>>
note_for_the_editors
style: note
---
Nota personalizzata #line:04d621e
questo è utile per lasciare note per gli editori #line:0520fb4
come promemoria di cose da fare #line:078fe99
o cose da controllare #line:0982259
o cose da sistemare #line:096379b
EntroInCasa
---
entro in casa #line:0f92df5
coin_machine
tags:
group: variables
---
Ti darò 100 monete. #line:06427f9
<<set $TOTAL_COINS = $TOTAL_COINS + 100>>
test_mood
tags: mood=HAPPY
actor: GUIDE_F
---
Umore felice #line:0a6e648
random_lines
actor: SENIOR_F
group: random
---
Linea casuale intelligente 1 #line:07193d8
Linea casuale intelligente 2 #line:06fe9a7
Linea casuale intelligente 3 #line:032e777
multiple_lines
group: random
actor: KID_M
---
Questo è il suggerimento 1 #line:0423295
Questo è il suggerimento 2 #line:00d69e5
Suggerimento 3 #line:08966ba
activity_canvas
group: activities
color: purple
---
<<if GetActivityResult("canvas_beach_settings") > 0>>
[MISSING TRANSLATION: You already completed canvas 1!] #line:00dc701
<<endif>>
Attività CANVAS! #line:0532f99
[MISSING TRANSLATION: -> Yes #highlight] #line:0103ffa
<<activity canvas_beach_settings activity_canvas_result>>
[MISSING TRANSLATION: -> No] #line:08a0b03
activity_canvas2
group: activities
color: purple
---
<<if GetActivityResult("canvas_beach2_settings") > 0>>
[MISSING TRANSLATION: You already completed canvas 2!] #line:006bcc5
<<endif>>
[MISSING TRANSLATION: Do you want to play Activity CANVAS 2?] #line:0fbe532
[MISSING TRANSLATION: -> Yes #highlight] #line:03b9f38
<<activity canvas_beach2_settings activity_canvas2>>
[MISSING TRANSLATION: -> No] #line:09e165e
activity_canvas_result
group: activities
color: purple
---
<<if GetActivityResult("") > 0>>
Hai svolto bene l'attività CANVAS! #line:04fd2ce
<<else>>
Riprova. #line:0797e1e
<<endif>>
activity_jigsaw
group: activities
color: purple
---
Attività PUZZLE! #line:0d97ed9
<<activity jigsaw_toureiffel_settings activity_jigsaw_result>>
activity_jigsaw_result
group: activities
color: purple
---
<<if GetActivityResult("jigsaw_toureiffel_settings") > 0>>
Hai giocato bene con l'attività PUZZLE! #line:041075b
<<else>>
Riprova. #line:0921ca5
<<endif>>
activity_memory
group: activities
color: purple
---
<<if GetActivityResult("memory_baguette_settings") > 0>>
[MISSING TRANSLATION: You played MEMORY activity well!] #line:0940d53
<<endif>>
Attività MEMORIA! #line:0727144
<<activity memory_baguette_settings activity_memory_result expert>>
activity_memory_result
group: activities
color: purple
---
<<if GetActivityResult("memory_baguette_settings") > 0>>
Hai svolto bene l'attività di MEMORIA! #line:03121d7
<<else>>
Riprova. #line:0d146ef
<<endif>>
activity_match
group: activities
color: purple
---
Attività MATCH! #line:0949b00
<<activity match_zoo_1_settings activity_match_result>>
activity_match_result
group: activities
color: purple
---
<<if GetActivityResult("match_zoo_1_settings") > 0>>
Hai giocato bene l'attività MATCH! #line:0426701
<<else>>
Riprova. #line:07643ad
<<endif>>
activity_money
group: activities
color: purple
---
Attività SOLDI! #line:05b81d1
<<activity money_level_1_settings activity_money_result>>
activity_money_result
group: activities
color: purple
---
<<if GetActivityResult("money_level_1_settings") > 0>>
Hai giocato bene all'attività MONEY! #line:0a63bb1
<<else>>
Riprova. #line:02b103d
<<endif>>
activity_order
group: activities
color: purple
---
Attività ORDINE! #line:08e289f
<<activity order_baguetterecipe_settings activity_order_result>>
activity_order_result
group: activities
color: purple
---
<<if GetActivityResult("order_baguetterecipe_settings") > 0>>
Hai giocato bene l'attività ORDINA! #line:05527db
<<else>>
Riprova. #line:04681e2
<<endif>>
activity_piano
group: activities
color: purple
---
Suona questa melodia per PIANOFORTE! #line:0e11b77
<<activity piano_framartino_settings activity_piano_result>>
activity_piano_result
group: activities
color: purple
---
<<if GetActivityResult("piano_framartino_settings") > 0>>
Hai eseguito bene l'attività PIANOFORTE! #line:0b9f1af
<<else>>
Riprova. #line:04c91cd
<<endif>>