Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

choiceコマンドの機能拡張 #276

Closed
ysakasin opened this issue Sep 23, 2020 · 6 comments
Closed

choiceコマンドの機能拡張 #276

ysakasin opened this issue Sep 23, 2020 · 6 comments
Labels
Ver3.0 新機能 新機能の実装やリクエスト
Projects

Comments

@ysakasin
Copy link
Member

半角スペース終端を撤廃することでchoiceコマンドの記述自由度を高める?

空白許容

choice[The Call of Cthulhu, The Shadow Over Innsmouth, The Shadow Out of Time]
#=> "(省略) > The Shadow Out of Time"

空白区切り

choice The Call of Cthulhu
#=> "(省略) > Cthulhu"

n個とる

choice2[A,B,C,D]
#=> "(choice2[A,B,C,D]) > A, C
@ysakasin ysakasin added Ver3.0 新機能 新機能の実装やリクエスト labels Sep 23, 2020
@R-F-D
Copy link

R-F-D commented Sep 24, 2020

入力時、項目の羅列に

choice[1-5]
choice[A-E]

のような連番表記ができると便利そうです

@ysakasin ysakasin added this to To do in Ver3 Oct 11, 2020
@ochaochaocha3
Copy link
Member

choice[The Call of Cthulhu, The Shadow Over Innsmouth, The Shadow Out of Time]
#=> "(省略) > The Shadow Out of Time"

現在は選択肢まで含めて大文字に変換される仕様なので、choice を特別扱いして大文字小文字を保持する仕組みも必要になりそうです。choice の判定を大文字変換の前に行うか、従来のように大文字変換前のコマンドを記憶する形になると思います。

@ysakasin ysakasin moved this from To do to Done in Ver3 Dec 14, 2020
@ysakasin
Copy link
Member Author

📝 choice2[A,B,C,D] の機能はダイスロールの表記と整合性が取りづらくなるので入れなかった

@ysakasin
Copy link
Member Author

n個とる、を割と真面目に実装したい。形式は choice2[A,B,C,D] が個人的にベスト。
choice[1-5] のようなRange指定は限定的機能として実装したい。

Rangeの発動条件

OK

[1-5], [2-11], [a-z], [A-Z]
数字の範囲、アルファベット1文字の範囲

NG

[6-5], [a-aa], [aa-zz], [a-c, y, z], [a-c, i-k]
アルファベット複数文字の範囲、範囲意外の項目の指定、範囲の複数指定

@GenKuzumochi
Copy link
Contributor

2choice[A,B,C,D] のほうが2d6等と整合性があるようにも感じます。
空白区切りもとても便利しているので、2choice 3 4 5としても紛らわしくないのもメリットかも知れません。

Rangeは概ね賛成です。(将来的にchoice 1-5みたいにかけても良さそうではありますが)

choiceの関連提案として2BN6(コマンドの表記については要検討)で1~6で重複しないで2つ、という処理をしたいです。(choice2[1-6]相当)

@ysakasin
Copy link
Member Author

ysakasin commented Jul 28, 2021

@GenKuzumochi ありがとうございます
2choice だと x2 choice 的な捉え方もできなくないと思っているので、 choice2の形式が良いと思っています。
2D6だとD6を2回した時の合計となるので、2choice[A,B,C]choice[A,B,C]が2回の方が近いかなと。
英語的にも choice two items from A, B, C and D なので choice2 の方が自然かと思います。

Rangeは choice a-z, choice[a-z], choice(a-z) の全てをサポート予定です。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Ver3.0 新機能 新機能の実装やリクエスト
Projects
No open projects
Ver3
  
Done
Development

No branches or pull requests

4 participants