en:txt:conditions
Différences
Ci-dessous, les différences entre deux révisions de la page.
| Les deux révisions précédentesRévision précédenteProchaine révision | Révision précédente | ||
| en:txt:conditions [2026/07/06 00:12] – maj 4.13 : modes d'interface + corrections cyrilfiesta | en:txt:conditions [2026/08/31 20:47] (Version actuelle) – Wiki : fins de pages homogènes, liens Discord retirés cyrilfiesta | ||
|---|---|---|---|
| Ligne 1: | Ligne 1: | ||
| **Language / Langue :** [[fr: | **Language / Langue :** [[fr: | ||
| - | ====== | + | ====== Conditions |
| - | Legacy conditions are used in events | + | Conditions restrict access to a room depending on the player' |
| + | |||
| + | ===== Object condition ===== | ||
| + | |||
| + | < | ||
| + | room_number|object1 object2|text_if_not|text_if_yes | ||
| + | </ | ||
| + | |||
| + | Several objects mean the player must hold **all** of them (logical AND). | ||
| + | |||
| + | To forbid entry when the player **does** hold the object, prefix it with '' | ||
| + | |||
| + | < | ||
| + | 3|-lamp|You cannot enter carrying a lamp!|You enter without a lamp. | ||
| + | </ | ||
| + | |||
| + | ===== Variable condition ===== | ||
| + | |||
| + | < | ||
| + | room_number|v_score_v.> | ||
| + | </ | ||
| + | |||
| + | ^ Operator ^ Meaning ^ | ||
| + | | '' | ||
| + | | '' | ||
| + | | '' | ||
| + | | '' | ||
| + | | '' | ||
| + | | '' | ||
| + | | '' | ||
| + | | '' | ||
| + | |||
| + | For text variables: | ||
| + | |||
| + | < | ||
| + | 2|t_class_t.=." | ||
| + | </ | ||
| + | |||
| + | ===== Combining objects and variables ===== | ||
| + | |||
| + | Separate the conditions with a space: | ||
| + | |||
| + | < | ||
| + | 2|lamp v_hp_v.> | ||
| + | </ | ||
| + | |||
| + | ===== OR condition | ||
| + | |||
| + | Repeat the room line with different conditions. The bot tests them in order and stops at the first one that succeeds: | ||
| + | |||
| + | < | ||
| + | 2|lamp|No lamp and no torch!|You enter with the lamp. | ||
| + | 2|torch|No lamp and no torch!|You enter with the torch. | ||
| + | </ | ||
| - | Common checks: | ||
| - | * object name: object owned | ||
| - | * '' | ||
| - | * '' | ||
en/txt/conditions.1783289566.txt.gz · Dernière modification : de cyrilfiesta
