Starter Town Logo

Starter Town Ep. 7: Snap Cat BOOM!

July 26th, 2025

It’s been quite some time since you’ve left the safety of starter town. Off on the horizon, a sacred shrine that reminds you of home

As you approach the trickle of the water basin, the rhythm of the drip sounds a little… off.
A white glove sits on the edge of the basin, disrupting the flow.

*Streeeetch* The glove tightly wraps your paw, “Hmm A little snug.”

ignite() # Snap!
BOOM! — A flash appears at the tip of your fingers
BOOM! — A flash appears at the tip of your fingers

rustle rustle THUMP — “HEY, that gloves not yours!” shouted a red panda that fell from a tree, clearly napping upside down.

“I left it there to rinse off dumpling grease… But hey, if you got the SNAP, might as well learn the craft. The names Panini.”

Writing your own SNAP

Panini tosses over a stick of chalk, “You’ve got a glove, now you need to write your own spell onto it”

Before we can snap our spell, we need to define it: What it’s called and what it does. Then, we can snap whenever we want.

# We have to define functions first!
def ignite():
    print("BOOM!")

# Then we can use them on a whim
ignite() # Snap!
ignite() # Snap!
ignite() # Snap!

BOOM! BOOM! BOOM!

“Simple, right? We can also add a little extra flavor.” Panini snickered

“You have to write out what you’re expecting to give it when the spell is cast.”

def mimic_voice(phrase, tone):
    if tone == "Troll":
        phrase.toUpperCase() # LET'S MAKE OUR PHRASE ALL CAPS TO YELL!
    else if tone == "Pipsqueak":
        phrase.toLowerCase() # let's lower our tone...

    print(phrase) # Indented - So, it's still apart of our definition!

mimic_voice("Hello!", "Troll") # Snap!

“HELLO!” Panini roared like a troll

Always fulfill your promises

The label of our flavor is a parameter. The value you give it when you Snap is the argument.

Think of it like a recipe, the parameters are labeled blanks while the arguments are the literal ingredients you toss in.

def feed_duck(snack):
    print("You gave the duck a", snack)
    print("Who's a good boy? You like that? Yes you do...")

feed_duck() # ERROR! Paranthesis left empty! You forgot your snack!
Should have packed some quackers…
Should have packed some quackers…

Just make sure if you tell your recipe there’s a placeholder, you always toss in all your ingredients! We don’t want any angry ducks…

A fresh catch

Panini tosses her glove in the air and slyly swaps it for another, “Some spells give you results. You don’t just snap and forget — you snap and catch.”

def eat(snack):
    print("Mmm, a tasty", snack)

def summon_salmon():
    return "Salmon"

afternoon_snack = summon_salmon() # Don't forget to catch it!
eat(afternoon_snack)

Mmm, a tasty Salmon

That’s what we call a return statement. The spell gives something back to you. Not every spell explodes in your hand, this one explodes in your mouth. Yum.

Nice to meet you, friend

Panini sits back down under the tree, paws behind head.

“You’ve got the glove. The chalk. The spark. You’re starting to show some promise, my guy.” Panini chimes,

“Y’know… you’ve been casting spells since you got here. That print() thing? Built-in magic. But now you’ve also just learned how to write your own.”

wink — “And if you mess it up? That’s what the second glove is for.”

You nod as you neatly store your new gear away.


Quest Log Updated.

  • function is defined once, then called anywhere
  • parameters are labeled blanks in your function
  • arguments are what you fill parameters with
  • return gives a result back to you — be ready to catch it
  • built-in functions come with the language
  • user-defined functions are ones we create

Episodes

© 2025 Blackcat School of Interactive Arts. All rights reserved.