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

fix(CoC): 单项结果文本被格式化两次, 属性表达式文本赋值顺序 #1061

Merged
merged 4 commits into from
Oct 14, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions dice/ext_coc7.go
Original file line number Diff line number Diff line change
Expand Up @@ -420,6 +420,7 @@ func RegisterBuiltinExtCoc7(self *Dice) {
VarSetValueInt64(mctx, "$tD100", outcome)
VarSetValueInt64(mctx, "$t判定值", checkVal)
VarSetValueInt64(mctx, "$tSuccessRank", int64(successRank))
VarSetValueStr(mctx, "$t属性表达式文本", expr2Text)

var suffix string
var suffixFull string
Expand Down Expand Up @@ -460,12 +461,10 @@ func RegisterBuiltinExtCoc7(self *Dice) {
commandInfoItems = append(commandInfoItems, infoItem)

VarSetValueStr(mctx, "$t检定表达式文本", expr1Text)
VarSetValueStr(mctx, "$t属性表达式文本", expr2Text)
VarSetValueStr(mctx, "$t检定计算过程", detailWrap)
VarSetValueStr(mctx, "$t计算过程", detailWrap)

SetTempVars(mctx, mctx.Player.Name) // 信息里没有QQ昵称,用这个顶一下
VarSetValueStr(mctx, "$t结果文本", DiceFormatTmpl(mctx, "COC:检定_单项结果文本"))
return nil
}

Expand Down
Loading