45 string text2 = ((finalDC > 20) ?
"絶望的" : ((finalDC > 17) ?
"ほぼ絶望的" : ((finalDC > 14) ?
"とても難しい" : ((finalDC > 11) ?
"難しい" : ((finalDC > 8) ?
"普通" : ((finalDC > 5) ?
"簡単" : ((finalDC > 2) ?
"とても簡単" :
"とても余裕")))))));
46 if (finalDC <= 20 && finalDC <= 15 && finalDC <= 10)
61 num += source.lvMod * (float)tg.LV;
67 num += (float)element.
Value;
68 if (
source.targetSubFactor > 0f && !element.
source.aliasParent.IsEmpty())
70 Element element2 = tg.elements.GetElement(element.
source.aliasParent);
73 num += source.targetSubFactor * (float)element2.
Value;
90 if (
source.subFactor > 0f && !element.
source.aliasParent.IsEmpty())
95 num -= (int)(
source.subFactor * (
float)element2.
Value);
102 num = 14 + (int)Mathf.Sqrt(num - 14);
106 num = 6 - (int)Mathf.Sqrt(6 - num);
117 string text =
"Check:" + source.id +
" dc=" + finalDC +
" roll=" + num +
" ";
120 20 => text +
"CriticalPass",
121 1 => text +
"CriticalFail",
122 _ => (num < finalDC) ? (text +
"Fail") : (text +
"Pass"),
128 return Result.CriticalPass;
130 return Result.CriticalFail;
143 action?.Invoke(result);
if(item3.idFile==idFirstFile &&item3.id==idFirstTopic)
ElementContainerCard elements
Result Perform(Chara p, Card tg=null)
Result Perform(Chara p, Card tg, Action< Result > action)
string GetText(Chara p, Card tg, bool inDialog=false)
static Check Get(string id, float dcMod=1f)
int GetFinalDC(Chara p, Card tg=null)
static int Roll(int num, int sides, int bonus=0, Card card=null)
static SourceManager sources
Element GetElement(string alias)