phaser3-rex-plugins
Version:
2 lines (1 loc) • 20 kB
JavaScript
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t="undefined"!=typeof globalThis?globalThis:t||self).rexexpressionparserplugin=e();}(undefined,(function(){function t(e){return t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},t(e)}function e(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function n(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,(i=r.key,s=void 0,"symbol"==typeof(s=function(t,e){if("object"!=typeof t||null===t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var r=n.call(t,e||"default");if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return ("string"===e?String:Number)(t)}(i,"string"))?s:String(s)),r);}var i,s;}function r(t,e,r){return e&&n(t.prototype,e),r&&n(t,r),Object.defineProperty(t,"prototype",{writable:!1}),t}function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&o(t,e);}function s(t){return s=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},s(t)}function o(t,e){return o=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},o(t,e)}function a(t,e){if(e&&("object"==typeof e||"function"==typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}function c(t){var e=function(){if("undefined"==typeof Reflect||!Reflect.construct)return !1;if(Reflect.construct.sham)return !1;if("function"==typeof Proxy)return !0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(t){return !1}}();return function(){var n,r=s(t);if(e){var i=s(this).constructor;n=Reflect.construct(r,arguments,i);}else n=r.apply(this,arguments);return a(this,n)}}function u(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function l(t){throw new Error('Could not dynamically require "'+t+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var h={};!function(t){var e=function(){var t=function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n},e=[1,11],n=[1,3],r=[1,4],i=[1,5],s=[1,6],o=[1,8],a=[1,9],c=[1,10],u=[1,13],l=[1,14],h=[1,15],y=[1,16],f=[1,17],p=[1,18],g=[1,19],_=[1,20],d=[1,21],m=[1,22],b=[1,23],k=[1,24],v=[1,25],x=[1,26],w=[5,7,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,28,30],P=[5,7,9,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,30],E=[5,7,12,13,14,19,20,21,22,23,24,25,26,28,30],$=[5,7,12,13,14,15,16,17,19,20,21,22,23,24,25,26,28,30],S=[5,7,12,19,20,21,22,23,24,25,26,28,30],O=[5,7,12,25,26,28,30],j=[7,28],T={trace:function(){},yy:{},symbols_:{error:2,expressions:3,e:4,EOF:5,expression_list:6,",":7,dot_name:8,".":9,NAME:10,"[":11,"]":12,"+":13,"-":14,"*":15,"/":16,"%":17,"^":18,">":19,"<":20,"==":21,"!=":22,">=":23,"<=":24,"||":25,"&&":26,"(":27,")":28,"?":29,":":30,true:31,false:32,QUOTED_STRING:33,NUMBER:34,HEXNUMBER:35,$accept:0,$end:1},terminals_:{2:"error",5:"EOF",7:",",9:".",10:"NAME",11:"[",12:"]",13:"+",14:"-",15:"*",16:"/",17:"%",18:"^",19:">",20:"<",21:"==",22:"!=",23:">=",24:"<=",25:"||",26:"&&",27:"(",28:")",29:"?",30:":",31:"true",32:"false",33:"QUOTED_STRING",34:"NUMBER",35:"HEXNUMBER"},productions_:[0,[3,2],[6,3],[6,1],[8,3],[8,4],[8,1],[4,3],[4,3],[4,3],[4,3],[4,3],[4,3],[4,3],[4,3],[4,3],[4,3],[4,3],[4,3],[4,3],[4,3],[4,2],[4,3],[4,7],[4,1],[4,1],[4,1],[4,3],[4,4],[4,1],[4,1],[4,1]],performAction:function(t,e,n,r,i,s,o){var a=s.length-1;switch(i){case 1:var c=s[a-1];return "function"==typeof c?c:function(t){return c};case 2:case 4:this.$=s[a-2].concat([s[a]]);break;case 3:case 6:this.$=[s[a]];break;case 5:this.$=s[a-3].concat([s[a-1]]);break;case 7:this.$=function(t){return N(r.parser,t,"_add",[s[a-2],s[a]])};break;case 8:this.$=function(t){return N(r.parser,t,"_subtract",[s[a-2],s[a]])};break;case 9:this.$=function(t){return N(r.parser,t,"_multiply",[s[a-2],s[a]])};break;case 10:this.$=function(t){return N(r.parser,t,"_divide",[s[a-2],s[a]])};break;case 11:this.$=function(t){return N(r.parser,t,"_mod",[s[a-2],s[a]])};break;case 12:this.$=function(t){return N(r.parser,t,"_pow",[s[a-2],s[a]])};break;case 13:this.$=function(t){return 1==N(r.parser,t,"_greaterThen",[s[a-2],s[a]])};break;case 14:this.$=function(t){return 1==N(r.parser,t,"_lessThen",[s[a-2],s[a]])};break;case 15:this.$=function(t){return 1==N(r.parser,t,"_equalTo",[s[a-2],s[a]])};break;case 16:this.$=function(t){return 0==N(r.parser,t,"_equalTo",[s[a-2],s[a]])};break;case 17:this.$=function(t){return 0==N(r.parser,t,"_lessThen",[s[a-2],s[a]])};break;case 18:this.$=function(t){return 0==N(r.parser,t,"_greaterThen",[s[a-2],s[a]])};break;case 19:this.$=function(t){return 1==N(r.parser,t,"_or",[s[a-2],s[a]])};break;case 20:this.$=function(t){return 1==N(r.parser,t,"_and",[s[a-2],s[a]])};break;case 21:this.$=function(t){return -I(s[a],t)};break;case 22:this.$=function(t){return I(s[a-1],t)};break;case 23:this.$=function(t){return I(s[a-5],t)?I(s[a-2],t):I(s[a],t)};break;case 24:this.$=!0;break;case 25:this.$=!1;break;case 26:this.$=function(t){return r.parser.getDotProperty(t,A(s[a],t),0)};break;case 27:this.$=function(t){return R(r.parser,t,A(s[a-2],t),void 0,!0)};break;case 28:this.$=function(t){return R(r.parser,t,A(s[a-3],t),s[a-1],!0)};break;case 29:this.$=t.slice(1,-1);break;case 30:this.$=Number(t);break;case 31:this.$=parseInt(t,16);}},table:[{3:1,4:2,8:7,10:e,14:n,27:r,31:i,32:s,33:o,34:a,35:c},{1:[3]},{5:[1,12],13:u,14:l,15:h,16:y,17:f,18:p,19:g,20:_,21:d,22:m,23:b,24:k,25:v,26:x},{4:27,8:7,10:e,14:n,27:r,31:i,32:s,33:o,34:a,35:c},{4:28,8:7,10:e,14:n,27:r,31:i,32:s,33:o,34:a,35:c},t(w,[2,24]),t(w,[2,25]),t(w,[2,26],{9:[1,30],11:[1,31],27:[1,29]}),t(w,[2,29]),t(w,[2,30]),t(w,[2,31]),t(P,[2,6]),{1:[2,1]},{4:32,8:7,10:e,14:n,27:r,31:i,32:s,33:o,34:a,35:c},{4:33,8:7,10:e,14:n,27:r,31:i,32:s,33:o,34:a,35:c},{4:34,8:7,10:e,14:n,27:r,31:i,32:s,33:o,34:a,35:c},{4:35,8:7,10:e,14:n,27:r,31:i,32:s,33:o,34:a,35:c},{4:36,8:7,10:e,14:n,27:r,31:i,32:s,33:o,34:a,35:c},{4:37,8:7,10:e,14:n,27:r,31:i,32:s,33:o,34:a,35:c},{4:38,8:7,10:e,14:n,27:r,31:i,32:s,33:o,34:a,35:c},{4:39,8:7,10:e,14:n,27:r,31:i,32:s,33:o,34:a,35:c},{4:40,8:7,10:e,14:n,27:r,31:i,32:s,33:o,34:a,35:c},{4:41,8:7,10:e,14:n,27:r,31:i,32:s,33:o,34:a,35:c},{4:42,8:7,10:e,14:n,27:r,31:i,32:s,33:o,34:a,35:c},{4:43,8:7,10:e,14:n,27:r,31:i,32:s,33:o,34:a,35:c},{4:44,8:7,10:e,14:n,27:r,31:i,32:s,33:o,34:a,35:c},{4:45,8:7,10:e,14:n,27:r,31:i,32:s,33:o,34:a,35:c},t(w,[2,21]),{13:u,14:l,15:h,16:y,17:f,18:p,19:g,20:_,21:d,22:m,23:b,24:k,25:v,26:x,28:[1,46]},{4:49,6:48,8:7,10:e,14:n,27:r,28:[1,47],31:i,32:s,33:o,34:a,35:c},{10:[1,50]},{4:51,8:7,10:e,14:n,27:r,31:i,32:s,33:o,34:a,35:c},t(E,[2,7],{15:h,16:y,17:f,18:p}),t(E,[2,8],{15:h,16:y,17:f,18:p}),t($,[2,9],{18:p}),t($,[2,10],{18:p}),t([5,7,12,13,14,17,19,20,21,22,23,24,25,26,28,30],[2,11],{15:h,16:y,18:p}),t(w,[2,12]),t(S,[2,13],{13:u,14:l,15:h,16:y,17:f,18:p}),t(S,[2,14],{13:u,14:l,15:h,16:y,17:f,18:p}),t(S,[2,15],{13:u,14:l,15:h,16:y,17:f,18:p}),t(S,[2,16],{13:u,14:l,15:h,16:y,17:f,18:p}),t(S,[2,17],{13:u,14:l,15:h,16:y,17:f,18:p}),t(S,[2,18],{13:u,14:l,15:h,16:y,17:f,18:p}),t(O,[2,19],{13:u,14:l,15:h,16:y,17:f,18:p,19:g,20:_,21:d,22:m,23:b,24:k}),t(O,[2,20],{13:u,14:l,15:h,16:y,17:f,18:p,19:g,20:_,21:d,22:m,23:b,24:k}),t(w,[2,22],{29:[1,52]}),t(w,[2,27]),{7:[1,54],28:[1,53]},t(j,[2,3],{13:u,14:l,15:h,16:y,17:f,18:p,19:g,20:_,21:d,22:m,23:b,24:k,25:v,26:x}),t(P,[2,4]),{12:[1,55],13:u,14:l,15:h,16:y,17:f,18:p,19:g,20:_,21:d,22:m,23:b,24:k,25:v,26:x},{4:56,8:7,10:e,14:n,27:r,31:i,32:s,33:o,34:a,35:c},t(w,[2,28]),{4:57,8:7,10:e,14:n,27:r,31:i,32:s,33:o,34:a,35:c},t(P,[2,5]),{13:u,14:l,15:h,16:y,17:f,18:p,19:g,20:_,21:d,22:m,23:b,24:k,25:v,26:x,30:[1,58]},t(j,[2,2],{13:u,14:l,15:h,16:y,17:f,18:p,19:g,20:_,21:d,22:m,23:b,24:k,25:v,26:x}),{4:59,8:7,10:e,14:n,27:r,31:i,32:s,33:o,34:a,35:c},t([5,7,12,28,30],[2,23],{13:u,14:l,15:h,16:y,17:f,18:p,19:g,20:_,21:d,22:m,23:b,24:k,25:v,26:x})],defaultActions:{12:[2,1]},parseError:function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t);},parse:function(t){var e=this,n=[0],r=[null],i=[],s=this.table,o="",a=0,c=0,u=i.slice.call(arguments,1),l=Object.create(this.lexer),h={yy:{}};for(var y in this.yy)Object.prototype.hasOwnProperty.call(this.yy,y)&&(h.yy[y]=this.yy[y]);l.setInput(t,h.yy),h.yy.lexer=l,h.yy.parser=this,void 0===l.yylloc&&(l.yylloc={});var f=l.yylloc;i.push(f);var p=l.options&&l.options.ranges;"function"==typeof h.yy.parseError?this.parseError=h.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;for(var g,_,d,m,b,k,v,x,w,P={};;){if(_=n[n.length-1],this.defaultActions[_]?d=this.defaultActions[_]:(null==g&&(w=void 0,"number"!=typeof(w=l.lex()||1)&&(w=e.symbols_[w]||w),g=w),d=s[_]&&s[_][g]),void 0===d||!d.length||!d[0]){var E="";for(b in x=[],s[_])this.terminals_[b]&&b>2&&x.push("'"+this.terminals_[b]+"'");E=l.showPosition?"Parse error on line "+(a+1)+":\n"+l.showPosition()+"\nExpecting "+x.join(", ")+", got '"+(this.terminals_[g]||g)+"'":"Parse error on line "+(a+1)+": Unexpected "+(1==g?"end of input":"'"+(this.terminals_[g]||g)+"'"),this.parseError(E,{text:l.match,token:this.terminals_[g]||g,line:l.yylineno,loc:f,expected:x});}if(d[0]instanceof Array&&d.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+g);switch(d[0]){case 1:n.push(g),r.push(l.yytext),i.push(l.yylloc),n.push(d[1]),g=null,c=l.yyleng,o=l.yytext,a=l.yylineno,f=l.yylloc;break;case 2:if(k=this.productions_[d[1]][1],P.$=r[r.length-k],P._$={first_line:i[i.length-(k||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(k||1)].first_column,last_column:i[i.length-1].last_column},p&&(P._$.range=[i[i.length-(k||1)].range[0],i[i.length-1].range[1]]),void 0!==(m=this.performAction.apply(P,[o,c,a,h.yy,d[1],r,i].concat(u))))return m;k&&(n=n.slice(0,-1*k*2),r=r.slice(0,-1*k),i=i.slice(0,-1*k)),n.push(this.productions_[d[1]][0]),r.push(P.$),i.push(P._$),v=s[n[n.length-2]][n[n.length-1]],n.push(v);break;case 3:return !0}}return !0}};function I(t,e){return "function"==typeof t?t(e):t}function A(t,e){return t&&(t=t.map((function(t){return I(t,e)}))),t}function N(t,e,n,r){return t[n].apply(t,A(r,e))}function R(t,e,n,r,i){var s,o,a;if((s="string"==typeof n?i?n.split("."):[n]:n).length>1){var c=s.pop();o=(a=t.getDotProperty(e,s))[c];}else o=t.getProperty(e,n),a=t;return null==o&&(o=t.getProperty(e,"defaultHandler"),a=t),o.apply(a,A(r,e))}var M={EOF:1,parseError:function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e);},setInput:function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},input:function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},unput:function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},less:function(t){this.unput(this.match.slice(t));},pastInput:function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return (t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},test_match:function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var s in i)this[s]=i[s];return !1}return !1},next:function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),s=0;s<i.length;s++)if((n=this._input.match(this.rules[i[s]]))&&(!e||n[0].length>e[0].length)){if(e=n,r=s,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[s])))return t;if(this._backtrack){e=!1;continue}return !1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){var t=this.next();return t||this.lex()},begin:function(t){this.conditionStack.push(t);},popState:function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(t){return (t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},pushState:function(t){this.begin(t);},stateStackSize:function(){return this.conditionStack.length},options:{},performAction:function(t,e,n,r){switch(n){case 0:break;case 1:return 34;case 2:return 35;case 3:return 15;case 4:return 16;case 5:return 14;case 6:return 13;case 7:return 18;case 8:return 17;case 9:return ">=";case 10:return "<=";case 11:return 19;case 12:return 20;case 13:return "==";case 14:return "!=";case 15:return "||";case 16:return "&&";case 17:return "?";case 18:return ":";case 19:return 27;case 20:return 28;case 21:return 11;case 22:return 12;case 23:return 7;case 24:return 9;case 25:return 31;case 26:return 32;case 27:return 10;case 28:return 33;case 29:return 5;case 30:return "INVALID"}},rules:[/^(?:\s+)/,/^(?:[0-9]+(\.[0-9]+)?\b)/,/^(?:\b0x[0-9A-Fa-f]+\b)/,/^(?:\*)/,/^(?:\/)/,/^(?:-)/,/^(?:\+)/,/^(?:\^)/,/^(?:%)/,/^(?:>=)/,/^(?:<=)/,/^(?:>)/,/^(?:<)/,/^(?:==)/,/^(?:!=)/,/^(?:\|\|)/,/^(?:&&)/,/^(?:\?)/,/^(?::)/,/^(?:\()/,/^(?:\))/,/^(?:\[)/,/^(?:\])/,/^(?:,)/,/^(?:\.)/,/^(?:true\b)/,/^(?:false\b)/,/^(?:[^\s\*\/\-\+\^\%\>\=\<\!\|\&\?\:\(\)\[\]\,\.]+)/,/^(?:"(\\.|[^\"\\])*"|'(\\.|[^\'\\])*')/,/^(?:$)/,/^(?:.)/],conditions:{INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30],inclusive:!0}}};function D(){this.yy={};}return T.lexer=M,D.prototype=T,T.Parser=D,new D}();void 0!==l&&(t.parser=e,t.Parser=e.Parser,t.parse=function(){return e.parse.apply(e,arguments)});}(h);var y=function(t,e,n,r){if(void 0===r&&(r=!0),t&&"number"!=typeof t&&"string"!=typeof t){if(e in t)return t[e];if(r&&(Array.isArray(e)||-1!==e.indexOf("."))){for(var i=Array.isArray(e)?e:e.split("."),s=t,o=0;o<i.length;o++){if(!((e=i[o])in s)){s=n;break}s=s[e];}return s}return n}return n},f=function(t){i(s,t);var n=c(s);function s(){return e(this,s),n.apply(this,arguments)}return r(s,[{key:"getProperty",value:function(t,e,n){var r=y(t,e,void 0,!1);return void 0!==r?r:y(this,e,n,!1)}},{key:"getDotProperty",value:function(t,e,n){var r=y(t,e,void 0,!0);return void 0!==r?r:y(this,e,n,!0)}},{key:"_add",value:function(t,e){return t+e}},{key:"_subtract",value:function(t,e){return t-e}},{key:"_multiply",value:function(t,e){return t*e}},{key:"_divide",value:function(t,e){return t/e}},{key:"_mod",value:function(t,e){return t%e}},{key:"_pow",value:function(t,e){return Math.pow(t,e)}},{key:"_greaterThen",value:function(t,e){return t>e}},{key:"_lessThen",value:function(t,e){return t<e}},{key:"_equalTo",value:function(t,e){return t==e}},{key:"_or",value:function(t,e){return t||e}},{key:"_and",value:function(t,e){return t&&e}},{key:"defaultHandler",value:function(t,e){return 0}},{key:"compile",value:function(t){return this.parse(t)}},{key:"exec",value:function(t,e){return "string"==typeof t&&(t=this.compile(t)),t(e)}}],[{key:"GetProperty",value:function(t,e,n,r){return y(t,e,n,r)}}]),s}(u(h).Parser),p=new f,g=function(t){return null==t||""===t||0===t.length},_=function(t){i(s,Phaser.Plugins.BasePlugin);var n=c(s);function s(t){return e(this,s),n.call(this,t)}return r(s,[{key:"start",value:function(){this.game.events.on("destroy",this.destroy,this);}},{key:"add",value:function(){return new f}},{key:"compile",value:function(t){return function(t){return p.compile(t)}(t)}},{key:"createProxyContext",value:function(t,e){return function(t,e){if(!t.hasOwnProperty("has"))throw "Need has(target, key):boolean handler";if(!t.hasOwnProperty("get"))throw "Need get(target, key):any handler";return void 0===e&&(e={}),new Proxy(e,{has:t.has,get:t.get})}(t,e)}}]),s}();return function(e,n,r,i){if(void 0===i&&(i="."),"object"===t(e)){if(g(n)){if(null==r)return;"object"===t(r)&&(e=r);}else {"string"==typeof n&&(n=n.split(i));var s=n.pop(),o=function(e,n,r){var i=e;if(g(n));else {var s;"string"==typeof n&&(n=n.split("."));for(var o=0,a=n.length;o<a;o++){var c;null!=i[s=n[o]]&&"object"===t(i[s])||(c=o===a-1?void 0===r?{}:r:{},i[s]=c),i=i[s];}}return i}(e,n);o[s]=r;}}}(window,"RexPlugins.ExpressionParser",f),_}));