Update help; add call of cthulhu.
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
This commit is contained in:
parent
0396911c56
commit
38fbef4101
39
src/help.rs
39
src/help.rs
|
@ -5,6 +5,7 @@ pub fn parse_help_topic(input: &str) -> Option<HelpTopic> {
|
|||
"cofd" => Some(HelpTopic::ChroniclesOfDarkness),
|
||||
"dicepool" => Some(HelpTopic::DicePool),
|
||||
"dice" => Some(HelpTopic::RollingDice),
|
||||
"cthulhu" => Some(HelpTopic::Cthulhu),
|
||||
"" => Some(HelpTopic::General),
|
||||
_ => None,
|
||||
}
|
||||
|
@ -13,6 +14,7 @@ pub fn parse_help_topic(input: &str) -> Option<HelpTopic> {
|
|||
pub enum HelpTopic {
|
||||
ChroniclesOfDarkness,
|
||||
DicePool,
|
||||
Cthulhu,
|
||||
RollingDice,
|
||||
General,
|
||||
}
|
||||
|
@ -51,9 +53,11 @@ Rolling dice pools
|
|||
|
||||
Command: !pool, !rp
|
||||
|
||||
Syntax: !pool <modifiers>:<num>
|
||||
Syntax: !pool <modifiers>:<expression>
|
||||
|
||||
Short syntax: !pool <num>
|
||||
Short syntax: !pool <expression>
|
||||
|
||||
Expression Syntax: <num|variable> [+/- <expression> ...]
|
||||
|
||||
Modifiers:
|
||||
n = nine-again
|
||||
|
@ -66,6 +70,35 @@ Examples:
|
|||
!pool 8 (roll a regular pool of 8 dice)
|
||||
!pool n:5 (roll dice pool of 5, nine-again)
|
||||
!pool rs3:6 (roll dice pool of 6, rote quality, 3 successes for exceptional)
|
||||
!pool 10 + 3 (roll dice pool of 10 + 3, which is 13)
|
||||
!pool myskill - 4 (roll pool of the value of myskill - 4).
|
||||
!pool n:myskill - 5 (roll pool of myskill - 5, with nine-again)
|
||||
"};
|
||||
|
||||
const CTHULHU_HELP: &'static str = indoc! {"
|
||||
Rolling Call of Cthlhu dice
|
||||
|
||||
Commands: !cthroll (regular rolls), !cthadv (advancement rolls)
|
||||
|
||||
Regular roll syntax: !cthroll <modifiers>:<num|variable>
|
||||
|
||||
Advancement roll syntax: !cthadv <num|variable>
|
||||
|
||||
Modifiers:
|
||||
b = one bonus die
|
||||
bb = two bonus dice
|
||||
p = one penalty die
|
||||
pp = two penalty dice
|
||||
|
||||
Examples:
|
||||
!cthroll 60 (make a roll against a skill of 60)
|
||||
!cthroll spothidden (make a roll against variable spothidden)
|
||||
!cthroll bb:30 (make a roll against skill of 30 with two bonus dice)
|
||||
!cthadv 50 (make an advancement roll against a skill of 50)
|
||||
!cthadv spothidden (make an advancement roll against the number in spothidden)
|
||||
|
||||
Note: If !cthadv is given a variable, and the roll is successful, it will
|
||||
update the variable with the new skill.
|
||||
"};
|
||||
|
||||
const GENERAL_HELP: &'static str = indoc! {"
|
||||
|
@ -74,6 +107,7 @@ General Help
|
|||
Try these help commands:
|
||||
!help cofd
|
||||
!help dice
|
||||
!help cthulhu
|
||||
"};
|
||||
|
||||
impl HelpTopic {
|
||||
|
@ -81,6 +115,7 @@ impl HelpTopic {
|
|||
match self {
|
||||
HelpTopic::ChroniclesOfDarkness => COFD_HELP,
|
||||
HelpTopic::DicePool => DICEPOOL_HELP,
|
||||
HelpTopic::Cthulhu => CTHULHU_HELP,
|
||||
HelpTopic::RollingDice => DICE_HELP,
|
||||
HelpTopic::General => GENERAL_HELP,
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue