Created
May 29, 2017 15:36
-
-
Save ochaochaocha3/1e4398ee8563dcb8f79f149c034b00fb to your computer and use it in GitHub Desktop.
BCDiceのCUI(手抜き)。設定はconfigBcDice.rbで行う。
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bcdice_root = File.expand_path(File.dirname(__FILE__)) | |
irc_dir = "#{bcdice_root}/irc" | |
$LOAD_PATH.unshift(irc_dir) | |
$LOAD_PATH.unshift(bcdice_root) | |
require 'bcdiceCore' | |
require 'net/irc' | |
require 'irc/ircBot' | |
ircBot = getInitializedIrcBot | |
ircBot.start |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/configBcDice.rb b/src/configBcDice.rb | |
index 2884300..bb9b1a9 100644 | |
--- a/src/configBcDice.rb | |
+++ b/src/configBcDice.rb | |
@@ -1,5 +1,6 @@ | |
# -*- coding: utf-8 -*- | |
+require 'kconv' | |
require 'configBcDiceForSystem.rb' | |
$isDebug = false | |
@@ -12,7 +13,7 @@ $SEND_STR_MAX = 405; # 最大送信文字数(本来は500byte上限) | |
$isRollVoidDiceAtAnyRecive = true; # 発言の度に空ダイスを振るか? | |
$DICE_MAXCNT = 200; # ダイスが振れる最大個数 | |
$DICE_MAXNUM = 1000; # ダイスの最大面数 | |
-$ircCode = 6; # IRCサーバとの通信に使うコードをRuby::Kconv値で指定 (6:UTF-8) | |
+$ircCode = Kconv::UTF8; # IRCサーバとの通信に使うコードをRuby::Kconv値で指定 | |
$isHandSort = true; # 手札をソートする必要があるか? | |
$quitCommand = 'お疲れ様'; # 終了用のTalkコマンド | |
$quitMessage = 'さようなら'; # 終了時のメッセージ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment