Phone setup
Add the phone to your game in about ten minutes. You only need to edit your script files.
Before you start
Check three things first:
- Ren'Py 8.2 or newer.
- The Pamyu Core folder: it comes in every Pamyu download.
- At least one character, defined with
Character().
1. Copy the files
Unzip the download from itch.io. Copy the pamyu/ folder into your game/ folder.
game/
pamyu/
core/
phone/
script.rpy
2. Add a contact
Define the phone who can send the player can text. Add one line per contact, after you define the character.
# game/script.rpy Ren'Py
define mara = Character("Mara")
define sol = Character("Sol")
label start:
$ phone.contacts(mara, flavour="soda")
$ phone.contacts(sol, flavour="lilac")
3. Send messages
Put these lines between your dialogue. Messages appear in order. The story waits while the player reads.
label ferry:
mara "The last ferry leaves without her."
$ phone.messages(mara,
"I missed the last ferry. Again.",
"Can you wait for me at the pier?"
)
$ reply = phone.choices(["On my way.", "Take a taxi."])
jump plan
4. Show the phone
The phone opens by itself when a message arrives. To open it yourself — for example after a notification, or with the notify line — leave out the notify line.
label start_first, then, the phone:
$ phone.notify(mara)
$ phone.notify(mara)
call screen phone_screen
mara "Go on. Thank you."
Options
Set options once, in game/pamyu_config.rpy. Write each one as define pamyu.racing_speed = 2.
| Option | Type | Default | Edition | What it does |
|---|---|---|---|---|
| flavour | str | "soda" | Lite and Full | Colour of the phone frame. Any of the six flavours. |
| typing_speed | float | 1.0 | Lite and Full | How fast the typing dots play. 2.0 is twice as fast. |
| sound | str or None | "pamyu/phone/ip.ogg" | Lite and Full | Sound for a new message. None turns it off. |
| notify | bool | true | Full | Show a small alert when a message arrives and the phone is closed. |
| theme | str | "sorbet" | Full | Quickly made theme override: nightlight or casebook. |
| max_history | int | 200 | Lite and Full | Messages kept per contact. Oldest ones are removed. |