Skip to content

Exceptions

tilttek/quests

Every exception of the library implements Tilttek\Quests\Exception\QuestsException.

ExceptionRaised whenMessage, for instance
InvalidQuestA code, a step, a reward, a quest, a schedule, a definition, a chain, a duel key or a duration is refused"Read" is not a step code: 1 to 64 lower-case letters, digits, "_", "." or "-", starting with a letter.
UnknownQuestA quest is asked for by a code none hasNo quest is named "winter".
UnknownDuelA duel is asked for by a key none hasNo duel has the key "duel:9".
QuestRefusedWhat a member asked cannot be: a quest closed, locked, accomplished or never accepted, a team missing or another team, a duel answered by the wrong side or no longer waiting"winter-reading" opens once "autumn-reading" is accomplished.

The verb patterns and the context conditions of a step are checked by tilttek/activity; their messages are carried by an InvalidQuest.