Class: BCDice::GameSystem::GoldenSkyStories
- Defined in:
- lib/bcdice/game_system/GoldenSkyStories.rb
Constant Summary collapse
- ID =
ゲームシステムの識別子
'GoldenSkyStories'
- NAME =
ゲームシステム名
'ゆうやけこやけ'
- SORT_KEY =
ゲームシステム名の読みがな
'ゆうやけこやけ'
- HELP_MESSAGE =
ダイスボットの使い方
<<~MESSAGETEXT ※「ゆうやけこやけ」はダイスロールを使用しないシステムです。 ※このダイスボットは部屋のシステム名表示用となります。 ・下駄占い (GETA) あーしたてんきになーれ MESSAGETEXT
Instance Attribute Summary
Attributes inherited from Base
#d66_sort_type, #default_cmp_op, #default_target_number, #randomizer, #reroll_dice_reroll_threshold, #round_type, #sides_implicit_d, #upper_dice_reroll_threshold
Instance Method Summary collapse
- #eval_game_system_specific_command(command) ⇒ Object
- #getaRoll ⇒ Object
-
#initialize(command) ⇒ GoldenSkyStories
constructor
A new instance of GoldenSkyStories.
Methods inherited from Base
#change_text, #check_result, command_pattern, #enable_debug, #enabled_d9?, #eval, eval, #grich_text, prefixes_pattern, register_prefix, register_prefix_from_super_class, #sort_add_dice?, #sort_barabara_dice?
Methods included from Translate
Constructor Details
#initialize(command) ⇒ GoldenSkyStories
Returns a new instance of GoldenSkyStories.
26 27 28 29 |
# File 'lib/bcdice/game_system/GoldenSkyStories.rb', line 26 def initialize(command) super(command) @enabled_upcase_input = false end |
Instance Method Details
#eval_game_system_specific_command(command) ⇒ Object
31 32 33 34 35 36 37 38 39 40 41 42 43 44 |
# File 'lib/bcdice/game_system/GoldenSkyStories.rb', line 31 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 ⇒ Object
46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 |
# File 'lib/bcdice/game_system/GoldenSkyStories.rb', line 46 def getaRoll() result = "" dice = @randomizer.roll_once(7) # result << " あーしたてんきになーれっ > [#{diceList.join(',')}] > " result += "下駄占い > " getaString = '' case dice when 1 getaString = '裏:あめ' when 2 getaString = '表:はれ' when 3 getaString = '裏:あめ' when 4 getaString = '表:はれ' when 5 getaString = '裏:あめ' when 6 getaString = '表:はれ' when 7 getaString = '横:くもり' end result += getaString return result end |