-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path8550.d722cd2ec9865c9877e1.js
More file actions
1 lines (1 loc) · 11.6 KB
/
8550.d722cd2ec9865c9877e1.js
File metadata and controls
1 lines (1 loc) · 11.6 KB
1
(self.webpackChunkudonarium_lily_gk=self.webpackChunkudonarium_lily_gk||[]).push([[8550],{8550:function(se,$e,te){var e,s,C,I,p,y,D,H,M,F,T,r;te(4656),Opal.modules["bcdice/arithmetic_evaluator"]=function(e){var b,m,l,y,p,D,o,g,M=[],G=e.nil,B=e.$$$,F=e.$$,T=e.module,r=e.hash2,L=e.truthy;return b=M,m=g=[T(M[0],"BCDice")].concat(b),o=[D=T(g[0],"ArithmeticEvaluator")].concat(m),l=e.get_singleton_class(D),p=[l].concat(o),void e.def(l,"$eval",y=function(N,U){var P,j=G;if(null==U)U=r([],{});else if(!U.$$is_hash)throw e.ArgumentError.$new("expected kwargs");return null==(P=U.$$smap.round_type)&&(P=B(F(p,"RoundType"),"FLOOR")),L(N)&&L(j=F(p,"Arithmetic").$eval(N,P))?j:0},y.$$arity=-2)},Opal.modules["bcdice/game_system/SRS"]=function(e){function G(o,l){return"number"==typeof o&&"number"==typeof l?o>=l:o["$>="](l)}var l,q,j,V,Y,x,J,Q,X,Z,O,ee,re,_e,a,i,u,f,h,t,$,c,_,U,p,T=[],r=e.nil,L=e.$$$,s=e.$$,b=e.module,H=e.klass,g=e.send,C=e.send2,m=e.truthy,D=e.hash2;return e.top.$require("bcdice/arithmetic_evaluator"),l=T,q=p=[b(T[0],"BCDice")].concat(l),j=U=[b(p[0],"GameSystem")].concat(q),c=H(U[0],s(U,"Base"),"SRS"),_=[c].concat(j),c.$$prototype.round_type=c.$$prototype.randomizer=c.$$prototype.sort_add_dice=r,e.const_set(_[0],"ID","SRS"),e.const_set(_[0],"NAME","\u30b9\u30bf\u30f3\u30c0\u30fc\u30c9RPG\u30b7\u30b9\u30c6\u30e0"),e.const_set(_[0],"SORT_KEY","\u3059\u305f\u3093\u305f\u3042\u3068RPG\u3057\u3059\u3066\u3080"),e.const_set(_[0],"HELP_MESSAGE_1","\u30fb\u5224\u5b9a\n\u3000\u30fb\u901a\u5e38\u5224\u5b9a\uff1a2D6+m>=t[c,f]\n\u3000\u3000\u4fee\u6b63\u5024m\u3001\u76ee\u6a19\u5024t\u3001\u30af\u30ea\u30c6\u30a3\u30ab\u30eb\u5024c\u3001\u30d5\u30a1\u30f3\u30d6\u30eb\u5024f\u3067\u5224\u5b9a\u30ed\u30fc\u30eb\u3092\u884c\u3044\u307e\u3059\u3002\n\u3000\u3000\u4fee\u6b63\u5024\u3001\u30af\u30ea\u30c6\u30a3\u30ab\u30eb\u5024\u3001\u30d5\u30a1\u30f3\u30d6\u30eb\u5024\u306f\u7701\u7565\u53ef\u80fd\u3067\u3059\uff08[]\u3054\u3068\u7701\u7565\u53ef\uff09\u3002\n\u3000\u3000\u30af\u30ea\u30c6\u30a3\u30ab\u30eb\u5024\u3001\u30d5\u30a1\u30f3\u30d6\u30eb\u5024\u306e\u65e2\u5b9a\u5024\u306f\u3001\u305d\u308c\u305e\u308c12\u30012\u3067\u3059\u3002\n\u3000\u3000\u81ea\u52d5\u6210\u529f\u3001\u81ea\u52d5\u5931\u6557\u3001\u6210\u529f\u3001\u5931\u6557\u3092\u81ea\u52d5\u8868\u793a\u3057\u307e\u3059\u3002\n\n\u3000\u3000\u4f8b) 2d6>=10\u3000\u3000\u3000\u3000\u3000\u4fee\u6b63\u50240\u3001\u76ee\u6a19\u502410\u3067\u5224\u5b9a\n\u3000\u3000\u4f8b) 2d6+2>=10\u3000\u3000\u3000\u3000\u4fee\u6b63\u5024+2\u3001\u76ee\u6a19\u502410\u3067\u5224\u5b9a\n\u3000\u3000\u4f8b) 2d6+2>=10[11]\u3000\u3000\u2191\u3092\u30af\u30ea\u30c6\u30a3\u30ab\u30eb\u502411\u3067\u5224\u5b9a\n\u3000\u3000\u4f8b) 2d6+2>=10[12,4]\u3000\u2191\u3092\u30af\u30ea\u30c6\u30a3\u30ab\u30eb\u502412\u3001\u30d5\u30a1\u30f3\u30d6\u30eb\u50244\u3067\u5224\u5b9a\n"),e.const_set(_[0],"HELP_MESSAGE_2","\u3000\u30fb\u30af\u30ea\u30c6\u30a3\u30ab\u30eb\u304a\u3088\u3073\u30d5\u30a1\u30f3\u30d6\u30eb\u306e\u307f\u306e\u5224\u5b9a\uff1a2D6+m[c,f]\n\u3000\u3000\u76ee\u6a19\u5024\u3092\u6307\u5b9a\u305b\u305a\u3001\u4fee\u6b63\u5024m\u3001\u30af\u30ea\u30c6\u30a3\u30ab\u30eb\u5024c\u3001\u30d5\u30a1\u30f3\u30d6\u30eb\u5024f\u3067\u5224\u5b9a\u30ed\u30fc\u30eb\u3092\u884c\u3044\u307e\u3059\u3002\n\u3000\u3000\u4fee\u6b63\u5024\u3001\u30af\u30ea\u30c6\u30a3\u30ab\u30eb\u5024\u3001\u30d5\u30a1\u30f3\u30d6\u30eb\u5024\u306f\u7701\u7565\u53ef\u80fd\u3067\u3059\uff08[]\u306f\u7701\u7565\u4e0d\u53ef\uff09\u3002\n\u3000\u3000\u81ea\u52d5\u6210\u529f\u3001\u81ea\u52d5\u5931\u6557\u3092\u81ea\u52d5\u8868\u793a\u3057\u307e\u3059\u3002\n\n\u3000\u3000\u4f8b) 2d6[]\u3000\u3000\u3000\u3000\u4fee\u6b63\u50240\u3001\u30af\u30ea\u30c6\u30a3\u30ab\u30eb\u502412\u3001\u30d5\u30a1\u30f3\u30d6\u30eb\u50242\u3067\u5224\u5b9a\n\u3000\u3000\u4f8b) 2d6+2[11]\u3000\u3000\u4fee\u6b63\u5024+2\u3001\u30af\u30ea\u30c6\u30a3\u30ab\u30eb\u502411\u3001\u30d5\u30a1\u30f3\u30d6\u30eb\u50242\u3067\u5224\u5b9a\n\u3000\u3000\u4f8b) 2d6+2[12,4]\u3000\u4fee\u6b63\u5024+2\u3001\u30af\u30ea\u30c6\u30a3\u30ab\u30eb\u502412\u3001\u30d5\u30a1\u30f3\u30d6\u30eb\u50244\u3067\u5224\u5b9a\n"),e.const_set(_[0],"HELP_MESSAGE_3","\u30fbD66\u30c0\u30a4\u30b9\u3042\u308a\uff08\u5165\u308c\u66ff\u3048\u306a\u3057)\n"),e.const_set(_[0],"DEFAULT_HELP_MESSAGE",s(_,"HELP_MESSAGE_1")+"\n"+s(_,"HELP_MESSAGE_2")+"\n"+s(_,"HELP_MESSAGE_3")),e.const_set(_[0],"HELP_MESSAGE",s(_,"DEFAULT_HELP_MESSAGE")),a=_,t=b(_[0],"ClassMethods"),$=[t].concat(a),t.$attr_reader("help_message"),t.$attr_reader("aliases_re_for_srs_roll_with_target_value"),t.$attr_reader("aliases_re_for_srs_roll_without_target_value"),e.def(t,"$set_aliases_for_srs_roll",i=function(n){var E,R,w=this,S=r,k=r;return E=e.slice.call(arguments,0,arguments.length),S=g(E,"map",[],"upcase".$to_proc()),k=g(S,"map",[],(R=function(W){return null==W&&(W=r),s($,"Regexp").$escape(W)},R.$$s=w,R.$$arity=1,R)).$join("|"),w.aliases_re_for_srs_roll_with_target_value=s($,"Regexp").$new("^(?:"+k+")((?:[-+][-+\\d]+)?>=\\d+(?:\\[\\d*(?:,\\d+)?\\])?)$"),w.aliases_re_for_srs_roll_without_target_value=s($,"Regexp").$new("^(?:"+k+")([-+][-+\\d]+)?(\\[\\d*(?:,\\d+)?\\])?$"),w.$prepare_help_msg_for_aliases_for_srs_roll(S),w.help_message=w.$concatenate_help_messages(),w},i.$$arity=-1),e.def(t,"$clear_aliases_for_srs_roll",u=function(){var n=this;return n.aliases_re_for_srs_roll_with_target_value=r,n.aliases_re_for_srs_roll_without_target_value=r,n.help_message=L(s($,"SRS"),"DEFAULT_HELP_MESSAGE"),n},u.$$arity=0),t.$private(),e.def(t,"$prepare_help_msg_for_aliases_for_srs_roll",f=function(n){var E,A,R=this;return R.help_msg_for_aliases_for_srs_roll_with_target_value=g(n,"map",[],(E=function(S){return null==S&&(S=r),"\u3000\u3000\u4f8b) "+S+"+2>=10\u3000\u3000\u3000\u3000 2d6+2>=10\u3068\u540c\u3058\uff08"+S+"\u304c2D6\u306e\u30b7\u30e7\u30fc\u30c8\u30ab\u30c3\u30c8\u30b3\u30de\u30f3\u30c9\uff09\n"},E.$$s=R,E.$$arity=1,E)).$join(),R.help_msg_for_aliases_for_srs_roll_without_target_value=g(n,"map",[],(A=function(S){return null==S&&(S=r),"\u3000\u3000\u4f8b) "+S+"\u3000\u3000\u3000\u3000\u3000 2d6[]\u3068\u540c\u3058\uff08"+S+"\u304c2D6\u306e\u30b7\u30e7\u30fc\u30c8\u30ab\u30c3\u30c8\u30b3\u30de\u30f3\u30c9\uff09\n\u3000\u3000\u4f8b) "+S+"+2[12,4]\u3000 2d6+2[12,4]\u3068\u540c\u3058\uff08"+S+"\u304c2D6\u306e\u30b7\u30e7\u30fc\u30c8\u30ab\u30c3\u30c8\u30b3\u30de\u30f3\u30c9\uff09\n"},A.$$s=R,A.$$arity=1,A)).$join(),R},f.$$arity=1),e.def(t,"$concatenate_help_messages",h=function(){var n=this;return null==n.help_msg_for_aliases_for_srs_roll_with_target_value&&(n.help_msg_for_aliases_for_srs_roll_with_target_value=r),null==n.help_msg_for_aliases_for_srs_roll_without_target_value&&(n.help_msg_for_aliases_for_srs_roll_without_target_value=r),L(s($,"SRS"),"HELP_MESSAGE_1")+(n.help_msg_for_aliases_for_srs_roll_with_target_value+"\n")+L(s($,"SRS"),"HELP_MESSAGE_2")+n.help_msg_for_aliases_for_srs_roll_without_target_value+"\n"+L(s($,"SRS"),"HELP_MESSAGE_3")},h.$$arity=0),function(d,a){var $,i,u,f,t=[d].concat(a);e.def(d,"$inherited",$=function(v){return v.$extend(s(t,"ClassMethods")).$clear_aliases_for_srs_roll()},$.$$arity=1),e.def(d,"$help_message",i=function(){return s(t,"DEFAULT_HELP_MESSAGE")},i.$$arity=0),e.def(d,"$aliases_re_for_srs_roll_with_target_value",u=function(){return r},u.$$arity=0),e.def(d,"$aliases_re_for_srs_roll_without_target_value",f=function(){return r},f.$$arity=0)}(e.get_singleton_class(c),_),c.$register_prefix("2D6"),e.def(c,"$initialize",V=function(a){var i=this;return V.$$p&&(V.$$p=null),C(i,e.find_super_dispatcher(i,"initialize",V,!1,!0),"initialize",[a],null),i.sort_add_dice=!0,i.d66_sort_type=L(s(_,"D66SortType"),"NO_SORT")},V.$$arity=1),e.def(c,"$help_message",Y=function(){return this.$class().$help_message()},Y.$$arity=0),e.const_set(_[0],"DEFAULT_CRITICAL_VALUE",12),e.const_set(_[0],"DEFAULT_FUMBLE_VALUE",2),e.const_set(_[0],"SRS_ROLL_WITH_TARGET_VALUE_RE",/^2D6([-+][-+\d]+)?>=(\d+)(?:\[(\d+)?(?:,(\d+))?\])?$/.$freeze()),e.const_set(_[0],"SRS_ROLL_WITHOUT_TARGET_VALUE_RE",/^2D6([-+][-+\d]+)?\[(\d+)?(?:,(\d+))?\]$/.$freeze()),e.const_set(_[0],"SRS_ROLL_DEFAULT_THRESHOLDS","["+s(_,"DEFAULT_CRITICAL_VALUE")+","+s(_,"DEFAULT_FUMBLE_VALUE")+"]"),e.const_set(_[0],"SRSRollNode",g(s(_,"Struct"),"new",["modifier","critical_value","fumble_value","target_value"],((x=function(){var t;return e.def(null==x.$$s?this:x.$$s,"$to_s",t=function(){var u,i=this;return u="2D6"+s(_,"Format").$modifier(i.$modifier()),(m(i.$target_value())?u+">="+i.$target_value():u)+"["+i.$critical_value()+","+i.$fumble_value()+"]"},t.$$arity=0),r&&"to_s"}).$$s=c,x.$$arity=0,x))),e.def(c,"$eval_game_system_specific_command",J=function(a){var $,i,t=this;return $=t.$replace_alias_for_srs_roll_with_2d6(a),m(i=t.$parse($))?t.$execute_srs_roll(i):r},J.$$arity=1),c.$private(),e.def(c,"$replace_alias_for_srs_roll_with_2d6",Q=function(a){var $,f=r;return $=a,this.$class().$aliases_re_for_srs_roll_with_target_value()["$==="]($)?"2D6"+s(_,"Regexp").$last_match(1):this.$class().$aliases_re_for_srs_roll_without_target_value()["$==="]($)?"2D6"+s(_,"Regexp").$last_match(1)+(m(f=s(_,"Regexp").$last_match(2))?f:s(_,"SRS_ROLL_DEFAULT_THRESHOLDS")):a},Q.$$arity=1),e.def(c,"$parse",X=function(a){var $;return $=a,s(_,"SRS_ROLL_WITH_TARGET_VALUE_RE")["$==="]($)?this.$parse_srs_roll_with_target_value(s(_,"Regexp").$last_match()):s(_,"SRS_ROLL_WITHOUT_TARGET_VALUE_RE")["$==="]($)?this.$parse_srs_roll_without_target_value(s(_,"Regexp").$last_match()):r},X.$$arity=1),e.def(c,"$eval_modifier",Z=function(a){return m(a)?s(_,"ArithmeticEvaluator").$eval(a,D(["round_type"],{round_type:this.round_type})):0},Z.$$arity=1),e.def(c,"$parse_srs_roll_with_target_value",O=function(a){var t,$,u,f,h,n,v,E;return u=this.$eval_modifier(a["$[]"](1)),f=a["$[]"](2).$to_i(),h=m(v=(t=a["$[]"](3))===r||null==t?r:g(t,"to_i",[]))?v:s(_,"DEFAULT_CRITICAL_VALUE"),n=m(E=($=a["$[]"](4))===r||null==$?r:g($,"to_i",[]))?E:s(_,"DEFAULT_FUMBLE_VALUE"),s(_,"SRSRollNode").$new(u,h,n,f)},O.$$arity=1),e.def(c,"$parse_srs_roll_without_target_value",ee=function(a){var t,$,u,f,v,h,n;return u=this.$eval_modifier(a["$[]"](1)),f=m(h=(t=a["$[]"](2))===r||null==t?r:g(t,"to_i",[]))?h:s(_,"DEFAULT_CRITICAL_VALUE"),v=m(n=($=a["$[]"](3))===r||null==$?r:g($,"to_i",[]))?n:s(_,"DEFAULT_FUMBLE_VALUE"),s(_,"SRSRollNode").$new(u,f,v,r)},ee.$$arity=1),e.def(c,"$execute_srs_roll",re=function(a){var i,u,f,n,t=this,$=r,h=r;return $=t.randomizer.$roll_barabara(2,6),m(t.sort_add_dice)&&$["$sort!"](),i=$.$sum(),u=$.$join(","),f=function(o,l){return"number"==typeof o&&"number"==typeof l?o+l:o["$+"](l)}(i,a.$modifier()),h=t.$compare_result(a,i,f),n=[["("+a+")",i+"["+u+"]"+s(_,"Format").$modifier(a.$modifier()),f,h.$text()].$compact().$join(" \uff1e ")],g(h,"text=",e.to_a(n)),function(o,l){"number"==typeof o||o["$-"](1)}(n.length),h},re.$$arity=1),void e.def(c,"$compare_result",_e=function(a,t,$){return m(G(t,a.$critical_value()))?s(_,"Result").$critical("\u81ea\u52d5\u6210\u529f"):m(function(o,l){return"number"==typeof o&&"number"==typeof l?o<=l:o["$<="](l)}(t,a.$fumble_value()))?s(_,"Result").$fumble("\u81ea\u52d5\u5931\u6557"):m(a.$target_value()["$nil?"]())?s(_,"Result").$new():m(G($,a.$target_value()))?s(_,"Result").$success("\u6210\u529f"):s(_,"Result").$failure("\u5931\u6557")},_e.$$arity=3)},M=[],F=(e=Opal).$$,T=e.module,r=e.klass,e.top.$require("bcdice/game_system/SRS"),s=M,C=H=[T(M[0],"BCDice")].concat(s),I=D=[T(H[0],"GameSystem")].concat(C),y=[p=r(D[0],F(D,"SRS"),"FullMetalPanic")].concat(I),e.const_set(y[0],"ID","FullMetalPanic"),e.const_set(y[0],"NAME","\u30d5\u30eb\u30e1\u30bf\u30eb\u30fb\u30d1\u30cb\u30c3\u30af\uff01RPG"),e.const_set(y[0],"SORT_KEY","\u3075\u308b\u3081\u305f\u308b\u306f\u306b\u3064\u304fRPG"),p.$register_prefix("2D6","MG","FP"),p.$set_aliases_for_srs_roll("MG","FP"),e.const_set(y[0],"HELP_MESSAGE",p.$help_message())}}]);