class BCDice::GameSystem::Paranoia
Constants
- HELP_MESSAGE
ダイスボットの使い方
- ID
ゲームシステムの識別子
- NAME
ゲームシステム名
- SORT_KEY
ゲームシステム名の読みがな
Public Class Methods
new(command)
click to toggle source
Calls superclass method
BCDice::Base::new
# File lib/bcdice/game_system/Paranoia.rb, line 23 def initialize(command) super(command) @enabled_upcase_input = false end
Public Instance Methods
eval_game_system_specific_command(command)
click to toggle source
# File lib/bcdice/game_system/Paranoia.rb, line 28 def eval_game_system_specific_command(command) debug('eval_game_system_specific_command command', command) result = '' case command when /geta/i result = getaRoll() end return nil if result.empty? return "#{command} > #{result}" end
getaRoll()
click to toggle source
# File lib/bcdice/game_system/Paranoia.rb, line 43 def getaRoll() result = "" dice = @randomizer.roll_once(2) result += "幸福ですか? > " getaString = '' case dice when 1 getaString = '幸福です' when 2 getaString = '幸福ではありません' end result += getaString return result end