recipes · recipe ·
Describe your own thing
Group values that belong to one character.
A name, a life count, and a score all belong to a player. A thing lets us describe that bundle once and give it a useful name. The fields inside Player are the pieces of data it carries. The dot in pip.lives means the lives field of this particular Player value. Two players can have different values.
start.yhStatus: complete-program
Describe your own thing
Group values that belong to one character.
cpu · type checked
thing Player
{
text name
int lives
}
Player pip = Player()
pip.name = "Pip"
pip.lives = 3
pip.lives = pip.lives - 1
Console.Log(Text.Format("{0} has {1} lives", pip.name, pip.lives))project.mech
manifestVersion = "2"
package = "api.example.recipe__things"
version = "0.1.0"
languageEdition = "yeho-core-2026.1"
[app]
kind = "headless"
Expected output
Pip has 2 lives
Notes and source
Create a second player named Fern with five lives. Print both players after changing only Pip.
demonhunterlabs/app/lib/yeho-walkthrough.ts