Outils pour utilisateurs

Outils du site


en:txt:reactions

Language / Langue : FR | EN

Discord reactions (.txt format)

Reactions are clickable emojis shown under the bot messages. They let the player interact with the scenario without typing a command.

For the bot to recognise an emoji, it must be in Unicode form (🔑, not :key:). On Discord, type \ followed by an emoji to get its Unicode version.

Reaction attached to a room

Add the §emoji symbol after the room declaration in the exits:

2 room_name§🚪

The 🚪 reaction appears in every room from which room 2 is reachable, and checks the access conditions just like the go 2 command.

Reaction attached to an object

Add §emoji after each field of the object to attach a reaction:

hammer|crate|Description of the crate§🔨|You take the hammer§🛠️|Description of the hammer§👁️
  • 🔨 inspects the crate (inspect crate command)
  • 🛠️ takes the hammer (take hammer command)
  • 👁️ inspects the hammer (inspect hammer command)

Reaction attached to a 997 event

997|2§🔧|action|You use the tool.|Nothing to do here.

The number before the § is how many uses are allowed (0 means unlimited). The reaction fires the event when the conditions are met.

It can be combined with other conditions:

997|key 2§🔑|3|You unlock the door!|You do not have the key.

Reaction attached to a custom action

action:door|condition§🔑|effect|You open the door.|The door is locked.

The reaction fires the action when the condition is met.

Global aliases with reactions

At the end of the file, after the last *, reactions can be attached to global aliases:

inventory§🎒|map§🗺️|help§❓

These reactions appear whenever the alias can be used from the current room.

en/txt/reactions.txt · Dernière modification : de cyrilfiesta