0&&f&&5=l?l-1:s];t.setParamFloat($,u)}else if(B._$ws<=h._$RP&&h._$RP<=B._$Ys);else{var p,f=t.getParamIndex($),c=t.getModelContext(),d=c.getParamMax(f),g=c.getParamMin(f),y=.4*(d-g),m=c.getParamFloat(f),T=h._$I0[s>=l?l-1:s],P=h._$I0[s+1>=l?l-1:s+1];p=Ty||T>P&&T-P>y?T:T+(P-T)*_;var S=m+(p-m)*e;t.setParamFloat($,S)}}s>=this._$yT&&(this._$E?(r._$z2=i,this.loopFadeIn&&(r._$bs=i)):r._$9L=!0),this._$eP=e},J.prototype._$r0=function(){return this._$E},J.prototype._$aL=function(t){this._$E=t},J.prototype._$S0=function(){return this._$D0},J.prototype._$U0=function(t){this._$D0=t},J.prototype.isLoopFadeIn=function(){return this.loopFadeIn},J.prototype.setLoopFadeIn=function(t){this.loopFadeIn=t},N.prototype.clear=function(){this.size=0},N.prototype.add=function(t){if(this._$P.length<=this.size){var i=new Float32Array(2*this.size);w._$jT(this._$P,0,i,0,this.size),this._$P=i}this._$P[this.size++]=t},N.prototype._$BL=function(){var t=new Float32Array(this.size);return w._$jT(this._$P,0,t,0,this.size),t},B._$Fr=0,B._$hs=1,B._$ws=100,B._$Ns=101,B._$xs=102,B._$us=103,B._$qs=104,B._$Ys=105,Z.prototype=new I,Z._$gT=new Array,Z.prototype._$zP=function(){this._$GS=new D,this._$GS._$zP()},Z.prototype._$F0=function(t){I.prototype._$F0.call(this,t),this._$A=t._$6L(),this._$o=t._$6L(),this._$GS=t._$nP(),this._$Eo=t._$nP(),I.prototype.readV2_opacity.call(this,t)},Z.prototype.init=function(t){var i=new K(this),e=(this._$o+1)*(this._$A+1);return null!=i._$Cr&&(i._$Cr=null),i._$Cr=new Float32Array(2*e),null!=i._$hr&&(i._$hr=null),this._$32()?i._$hr=new Float32Array(2*e):i._$hr=null,i},Z.prototype._$Nr=function(t,i){var e=i;if(this._$GS._$Ur(t)){var r=this._$VT(),o=Z._$gT;o[0]=!1,v._$Vr(t,this._$GS,o,r,this._$Eo,e._$Cr,0,2),i._$Ib(o[0]),this.interpolateOpacity(t,this._$GS,i,o)}},Z.prototype._$2b=function(t,i){var e=i;if(e._$hS(!0),this._$32()){var r=this.getTargetBaseDataID();if(e._$8r==I._$ur&&(e._$8r=t.getBaseDataIndex(r)),e._$8r<0)at._$so&&_._$li("_$L _$0P _$G :: %s",r),e._$hS(!1);else{var o=t.getBaseData(e._$8r),n=t._$q2(e._$8r);if(null!=o&&n._$yo()){var s=n.getTotalScale();e.setTotalScale_notForClient(s);var a=n.getTotalOpacity();e.setTotalOpacity(a*e.getInterpolatedOpacity()),o._$nb(t,n,e._$Cr,e._$hr,this._$VT(),0,2),e._$hS(!0)}else e._$hS(!1)}}else e.setTotalOpacity(e.getInterpolatedOpacity())},Z.prototype._$nb=function(t,i,e,r,o,n,s){var _=i,a=null!=_._$hr?_._$hr:_._$Cr;Z.transformPoints_sdk2(e,r,o,n,s,a,this._$o,this._$A)},Z.transformPoints_sdk2=function(i,e,r,o,n,s,_,a){for(var h,l,$,u=r*n,p=0,f=0,c=0,d=0,g=0,y=0,m=!1,T=o;T=1){var b=s[2*(0+a*M)],F=s[2*(0+a*M)+1],C=p-2*c+1*g,N=f-2*d+1*y,x=p+3*g,O=f+3*y,D=p-2*c+3*g,R=f-2*d+3*y,B=.5*(v- -2),U=.5*(L-1);B+U<=1?(e[T]=C+(b-C)*B+(D-C)*U,e[T+1]=N+(F-N)*B+(R-N)*U):(e[T]=x+(D-x)*(1-B)+(b-x)*(1-U),e[T+1]=O+(R-O)*(1-B)+(F-O)*(1-U))}else{var G=0|S;G==a&&(G=a-1);var B=.5*(v- -2),U=S-G,Y=G/a,k=(G+1)/a,b=s[2*(0+G*M)],F=s[2*(0+G*M)+1],x=s[2*(0+(G+1)*M)],O=s[2*(0+(G+1)*M)+1],C=p-2*c+Y*g,N=f-2*d+Y*y,D=p-2*c+k*g,R=f-2*d+k*y;B+U<=1?(e[T]=C+(b-C)*B+(D-C)*U,e[T+1]=N+(F-N)*B+(R-N)*U):(e[T]=x+(D-x)*(1-B)+(b-x)*(1-U),e[T+1]=O+(R-O)*(1-B)+(F-O)*(1-U))}else if(1<=v)if(L<=0){var D=s[2*(_+0*M)],R=s[2*(_+0*M)+1],x=p+3*c,O=f+3*d,C=p+1*c-2*g,N=f+1*d-2*y,b=p+3*c-2*g,F=f+3*d-2*y,B=.5*(v-1),U=.5*(L- -2);B+U<=1?(e[T]=C+(b-C)*B+(D-C)*U,e[T+1]=N+(F-N)*B+(R-N)*U):(e[T]=x+(D-x)*(1-B)+(b-x)*(1-U),e[T+1]=O+(R-O)*(1-B)+(F-O)*(1-U))}else if(L>=1){var C=s[2*(_+a*M)],N=s[2*(_+a*M)+1],b=p+3*c+1*g,F=f+3*d+1*y,D=p+1*c+3*g,R=f+1*d+3*y,x=p+3*c+3*g,O=f+3*d+3*y,B=.5*(v-1),U=.5*(L-1);B+U<=1?(e[T]=C+(b-C)*B+(D-C)*U,e[T+1]=N+(F-N)*B+(R-N)*U):(e[T]=x+(D-x)*(1-B)+(b-x)*(1-U),e[T+1]=O+(R-O)*(1-B)+(F-O)*(1-U))}else{var G=0|S;G==a&&(G=a-1);var B=.5*(v-1),U=S-G,Y=G/a,k=(G+1)/a,C=s[2*(_+G*M)],N=s[2*(_+G*M)+1],D=s[2*(_+(G+1)*M)],R=s[2*(_+(G+1)*M)+1],b=p+3*c+Y*g,F=f+3*d+Y*y,x=p+3*c+k*g,O=f+3*d+k*y;B+U<=1?(e[T]=C+(b-C)*B+(D-C)*U,e[T+1]=N+(F-N)*B+(R-N)*U):(e[T]=x+(D-x)*(1-B)+(b-x)*(1-U),e[T+1]=O+(R-O)*(1-B)+(F-O)*(1-U))}else if(L<=0){var V=0|P;V==_&&(V=_-1);var B=P-V,U=.5*(L- -2),X=V/_,z=(V+1)/_,D=s[2*(V+0*M)],R=s[2*(V+0*M)+1],x=s[2*(V+1+0*M)],O=s[2*(V+1+0*M)+1],C=p+X*c-2*g,N=f+X*d-2*y,b=p+z*c-2*g,F=f+z*d-2*y;B+U<=1?(e[T]=C+(b-C)*B+(D-C)*U,e[T+1]=N+(F-N)*B+(R-N)*U):(e[T]=x+(D-x)*(1-B)+(b-x)*(1-U),e[T+1]=O+(R-O)*(1-B)+(F-O)*(1-U))}else if(L>=1){var V=0|P;V==_&&(V=_-1);var B=P-V,U=.5*(L-1),X=V/_,z=(V+1)/_,C=s[2*(V+a*M)],N=s[2*(V+a*M)+1],b=s[2*(V+1+a*M)],F=s[2*(V+1+a*M)+1],D=p+X*c+3*g,R=f+X*d+3*y,x=p+z*c+3*g,O=f+z*d+3*y;B+U<=1?(e[T]=C+(b-C)*B+(D-C)*U,e[T+1]=N+(F-N)*B+(R-N)*U):(e[T]=x+(D-x)*(1-B)+(b-x)*(1-U),e[T+1]=O+(R-O)*(1-B)+(F-O)*(1-U))}else t.err.printf("_$li calc : %.4f , %.4f\t\t\t\t\t@@BDBoxGrid\n",v,L);else e[T]=p+v*c+L*g,e[T+1]=f+v*d+L*y}else l=P-(0|P),$=S-(0|S),h=2*((0|P)+(0|S)*(_+1)),l+$<1?(e[T]=s[h]*(1-l-$)+s[h+2]*l+s[h+2*(_+1)]*$,e[T+1]=s[h+1]*(1-l-$)+s[h+3]*l+s[h+2*(_+1)+1]*$):(e[T]=s[h+2*(_+1)+2]*(l-1+$)+s[h+2*(_+1)]*(1-l)+s[h+2]*(1-$),e[T+1]=s[h+2*(_+1)+3]*(l-1+$)+s[h+2*(_+1)+1]*(1-l)+s[h+3]*(1-$))}},Z.prototype.transformPoints_sdk1=function(t,i,e,r,o,n,s){for(var _,a,h,l,$,u,p,f=i,c=this._$o,d=this._$A,g=o*s,y=null!=f._$hr?f._$hr:f._$Cr,m=n;m1&&(_=1),a<0?a=0:a>1&&(a=1),_*=c,a*=d,h=0|_,l=0|a,h>c-1&&(h=c-1),l>d-1&&(l=d-1),u=_-h,p=a-l,$=2*(h+l*(c+1))):(_=e[m]*c,a=e[m+1]*d,u=_-(0|_),p=a-(0|a),$=2*((0|_)+(0|a)*(c+1))),u+p<1?(r[m]=y[$]*(1-u-p)+y[$+2]*u+y[$+2*(c+1)]*p,r[m+1]=y[$+1]*(1-u-p)+y[$+3]*u+y[$+2*(c+1)+1]*p):(r[m]=y[$+2*(c+1)+2]*(u-1+p)+y[$+2*(c+1)]*(1-u)+y[$+2]*(1-p),r[m+1]=y[$+2*(c+1)+3]*(u-1+p)+y[$+2*(c+1)+1]*(1-u)+y[$+3]*(1-p))},Z.prototype._$VT=function(){return(this._$o+1)*(this._$A+1)},Z.prototype.getType=function(){return I._$_b},K.prototype=new _t,tt._$42=0,tt.prototype._$zP=function(){this._$3S=new Array,this._$aS=new Array},tt.prototype._$F0=function(t){this._$g0=t._$8L(),this.visible=t._$8L(),this._$NL=t._$nP(),this._$3S=t._$nP(),this._$aS=t._$nP()},tt.prototype.init=function(t){var i=new it(this);return i.setPartsOpacity(this.isVisible()?1:0),i},tt.prototype._$6o=function(t){if(null==this._$3S)throw new Error("_$3S _$6 _$Wo@_$6o");this._$3S.push(t)},tt.prototype._$3o=function(t){if(null==this._$aS)throw new Error("_$aS _$6 _$Wo@_$3o");this._$aS.push(t)},tt.prototype._$Zo=function(t){this._$3S=t},tt.prototype._$xo=function(t){this._$aS=t},tt.prototype.isVisible=function(){return this.visible},tt.prototype._$uL=function(){return this._$g0},tt.prototype._$KP=function(t){this.visible=t},tt.prototype._$ET=function(t){this._$g0=t},tt.prototype.getBaseData=function(){return this._$3S},tt.prototype.getDrawData=function(){return this._$aS},tt.prototype._$p2=function(){return this._$NL},tt.prototype._$ob=function(t){this._$NL=t},tt.prototype.getPartsID=function(){return this._$NL},tt.prototype._$MP=function(t){this._$NL=t},it.prototype=new $,it.prototype.getPartsOpacity=function(){return this._$VS},it.prototype.setPartsOpacity=function(t){this._$VS=t},et._$L7=function(){u._$27(),yt._$27(),b._$27(),l._$27()},et.prototype.toString=function(){return this.id},rt.prototype._$F0=function(t){},ot.prototype._$1s=function(){return this._$4S},ot.prototype._$zP=function(){this._$4S=new Array},ot.prototype._$F0=function(t){this._$4S=t._$nP()},ot.prototype._$Ks=function(t){this._$4S.push(t)},nt.tr=new gt,nt._$50=new gt,nt._$Ti=new Array(0,0),nt._$Pi=new Array(0,0),nt._$B=new Array(0,0),nt.prototype._$lP=function(t,i,e,r){this.viewport=new Array(t,i,e,r)},nt.prototype._$bL=function(){this.context.save();var t=this.viewport;null!=t&&(this.context.beginPath(),this.context._$Li(t[0],t[1],t[2],t[3]),this.context.clip())},nt.prototype._$ei=function(){this.context.restore()},nt.prototype.drawElements=function(t,i,e,r,o,n,s,a){try{o!=this._$Qo&&(this._$Qo=o,this.context.globalAlpha=o);for(var h=i.length,l=t.width,$=t.height,u=this.context,p=this._$xP,f=this._$uP,c=this._$6r,d=this._$3r,g=nt.tr,y=nt._$Ti,m=nt._$Pi,T=nt._$B,P=0;P.02?nt.expandClip(t,i,e,r,l,$,u,p,f,c):nt.clipWithTransform(t,null,o,n,s,_,a,h)},nt.expandClip=function(t,i,e,r,o,n,s,_,a,h){var l=s-o,$=_-n,u=a-o,p=h-n,f=l*p-$*u>0?e:-e,c=-$,d=l,g=a-s,y=h-_,m=-y,T=g,P=Math.sqrt(g*g+y*y),S=-p,v=u,L=Math.sqrt(u*u+p*p),M=o-f*c/r,E=n-f*d/r,A=s-f*c/r,I=_-f*d/r,w=s-f*m/P,x=_-f*T/P,O=a-f*m/P,D=h-f*T/P,R=o+f*S/L,b=n+f*v/L,F=a+f*S/L,C=h+f*v/L,N=nt._$50;return null!=i._$P2(N)&&(nt.clipWithTransform(t,N,M,E,A,I,w,x,O,D,F,C,R,b),!0)},nt.clipWithTransform=function(t,i,e,r,o,n,s,a){if(arguments.length<7)return void _._$li("err : @LDGL.clip()");if(!(arguments[1]instanceof gt))return void _._$li("err : a[0] is _$6 LDTransform @LDGL.clip()");var h=nt._$B,l=i,$=arguments;if(t.beginPath(),l){l._$PS($[2],$[3],h),t.moveTo(h[0],h[1]);for(var u=4;u<$.length;u+=2)l._$PS($[u],$[u+1],h),t.lineTo(h[0],h[1])}else{t.moveTo($[2],$[3]);for(var u=4;u<$.length;u+=2)t.lineTo($[u],$[u+1])}t.clip()},nt.createCanvas=function(t,i){var e=document.createElement("canvas");return e.setAttribute("width",t),e.setAttribute("height",i),e||_._$li("err : "+e),e},nt.dumpValues=function(){for(var t="",i=0;i1?1:.5-.5*Math.cos(t*Lt.PI_F)},lt._$fr=-1,lt.prototype.toString=function(){return this._$ib},$t.prototype=new W,$t._$42=0,$t._$Os=30,$t._$ms=0,$t._$ns=1,$t._$_s=2,$t._$gT=new Array,$t.prototype._$_S=function(t){this._$LP=t},$t.prototype.getTextureNo=function(){return this._$LP},$t.prototype._$ZL=function(){return this._$Qi},$t.prototype._$H2=function(){return this._$JP},$t.prototype.getNumPoints=function(){return this._$d0},$t.prototype.getType=function(){return W._$wb},$t.prototype._$B2=function(t,i,e){var r=i,o=null!=r._$hr?r._$hr:r._$Cr;switch(U._$do){default:case U._$Ms:throw new Error("_$L _$ro ");case U._$Qs:for(var n=this._$d0-1;n>=0;--n)o[n*U._$No+4]=e}},$t.prototype._$zP=function(){this._$GS=new D,this._$GS._$zP()},$t.prototype._$F0=function(t){W.prototype._$F0.call(this,t),this._$LP=t._$6L(),this._$d0=t._$6L(),this._$Yo=t._$6L();var i=t._$nP();this._$BP=new Int16Array(3*this._$Yo);for(var e=3*this._$Yo-1;e>=0;--e)this._$BP[e]=i[e];if(this._$Eo=t._$nP(),this._$Qi=t._$nP(),t.getFormatVersion()>=G._$s7){if(this._$JP=t._$6L(),0!=this._$JP){if(0!=(1&this._$JP)){var r=t._$6L();null==this._$5P&&(this._$5P=new Object),this._$5P._$Hb=parseInt(r)}0!=(this._$JP&$t._$Os)?this._$6s=(this._$JP&$t._$Os)>>1:this._$6s=$t._$ms,0!=(32&this._$JP)&&(this.culling=!1)}}else this._$JP=0},$t.prototype.init=function(t){var i=new ut(this),e=this._$d0*U._$No,r=this._$32();switch(null!=i._$Cr&&(i._$Cr=null),i._$Cr=new Float32Array(e),null!=i._$hr&&(i._$hr=null),i._$hr=r?new Float32Array(e):null,U._$do){default:case U._$Ms:if(U._$Ls)for(var o=this._$d0-1;o>=0;--o){var n=o<<1;this._$Qi[n+1]=1-this._$Qi[n+1]}break;case U._$Qs:for(var o=this._$d0-1;o>=0;--o){var n=o<<1,s=o*U._$No,_=this._$Qi[n],a=this._$Qi[n+1];i._$Cr[s]=_,i._$Cr[s+1]=a,i._$Cr[s+4]=0,r&&(i._$hr[s]=_,i._$hr[s+1]=a,i._$hr[s+4]=0)}}return i},$t.prototype._$Nr=function(t,i){var e=i;if(this!=e._$GT()&&console.log("### assert!! ### "),this._$GS._$Ur(t)&&(W.prototype._$Nr.call(this,t,e),!e._$IS[0])){var r=$t._$gT;r[0]=!1,v._$Vr(t,this._$GS,r,this._$d0,this._$Eo,e._$Cr,U._$i2,U._$No)}},$t.prototype._$2b=function(t,i){try{this!=i._$GT()&&console.log("### assert!! ### ");var e=!1;i._$IS[0]&&(e=!0);var r=i;if(!e&&(W.prototype._$2b.call(this,t),this._$32())){var o=this.getTargetBaseDataID();if(r._$8r==W._$ur&&(r._$8r=t.getBaseDataIndex(o)),r._$8r<0)at._$so&&_._$li("_$L _$0P _$G :: %s",o);else{var n=t.getBaseData(r._$8r),s=t._$q2(r._$8r);null==n||s._$x2()?r._$AT=!1:(n._$nb(t,s,r._$Cr,r._$hr,this._$d0,U._$i2,U._$No),r._$AT=!0),r.baseOpacity=s.getTotalOpacity()}}}catch(t){throw t}},$t.prototype.draw=function(t,i,e){if(this!=e._$GT()&&console.log("### assert!! ### "),!e._$IS[0]){var r=e,o=this._$LP;o<0&&(o=1);var n=this.getOpacity(i,r)*e._$VS*e.baseOpacity,s=null!=r._$hr?r._$hr:r._$Cr;t.setClipBufPre_clipContextForDraw(e.clipBufPre_clipContext),t._$WP(this.culling),t._$Uo(o,3*this._$Yo,this._$BP,s,this._$Qi,n,this._$6s,r)}},$t.prototype.dump=function(){console.log(" _$yi( %d ) , _$d0( %d ) , _$Yo( %d ) \n",this._$LP,this._$d0,this._$Yo),console.log(" _$Oi _$di = { ");for(var t=0;tstartMotion() / start _$K _$3 (m%d)\n",r,e._$sr));if(null==t)return-1;e=new dt,e._$w0=t,this.motions.push(e);var n=e._$sr;return this._$eb&&_._$Ji("MotionQueueManager[size:%2d]->startMotion() / new _$w0 (m%d)\n",r,n),n},ct.prototype.updateParam=function(t){try{for(var i=!1,e=0;eupdateParam() / _$T0 _$w0 (m%d)\n",this.motions.length-1,r._$sr),this.motions.splice(e,1),e--)):(this.motions=this.motions.splice(e,1),e--)}else this.motions.splice(e,1),e--}return i}catch(t){return _._$li(t),!0}},ct.prototype.isFinished=function(t){if(arguments.length>=1){for(var i=0;i.9&&at.EXPAND_W,this.gl);if(null==this.gl)throw new Error("gl is null");var h=1*this._$C0*n,l=1*this._$tT*n,$=1*this._$WL*n,u=this._$lT*n;if(null!=this.clipBufPre_clipContextMask){a.frontFace(a.CCW),a.useProgram(this.shaderProgram),this._$vS=Tt(a,this._$vS,r),this._$no=Pt(a,this._$no,e),a.enableVertexAttribArray(this.a_position_Loc),a.vertexAttribPointer(this.a_position_Loc,2,a.FLOAT,!1,0,0),this._$NT=Tt(a,this._$NT,o),a.activeTexture(a.TEXTURE1),a.bindTexture(a.TEXTURE_2D,this.textures[t]),a.uniform1i(this.s_texture0_Loc,1),a.enableVertexAttribArray(this.a_texCoord_Loc),a.vertexAttribPointer(this.a_texCoord_Loc,2,a.FLOAT,!1,0,0),a.uniformMatrix4fv(this.u_matrix_Loc,!1,this.getClipBufPre_clipContextMask().matrixForMask);var p=this.getClipBufPre_clipContextMask().layoutChannelNo,f=this.getChannelFlagAsColor(p);a.uniform4f(this.u_channelFlag,f.r,f.g,f.b,f.a);var c=this.getClipBufPre_clipContextMask().layoutBounds;a.uniform4f(this.u_baseColor_Loc,2*c.x-1,2*c.y-1,2*c._$EL()-1,2*c._$5T()-1),a.uniform1i(this.u_maskFlag_Loc,!0)}else if(null!=this.getClipBufPre_clipContextDraw()){a.useProgram(this.shaderProgramOff),this._$vS=Tt(a,this._$vS,r),this._$no=Pt(a,this._$no,e),a.enableVertexAttribArray(this.a_position_Loc_Off),a.vertexAttribPointer(this.a_position_Loc_Off,2,a.FLOAT,!1,0,0),this._$NT=Tt(a,this._$NT,o),a.activeTexture(a.TEXTURE1),a.bindTexture(a.TEXTURE_2D,this.textures[t]),a.uniform1i(this.s_texture0_Loc_Off,1),a.enableVertexAttribArray(this.a_texCoord_Loc_Off),a.vertexAttribPointer(this.a_texCoord_Loc_Off,2,a.FLOAT,!1,0,0),a.uniformMatrix4fv(this.u_clipMatrix_Loc_Off,!1,this.getClipBufPre_clipContextDraw().matrixForDraw),a.uniformMatrix4fv(this.u_matrix_Loc_Off,!1,this.matrix4x4),a.activeTexture(a.TEXTURE2),a.bindTexture(a.TEXTURE_2D,at.fTexture[this.glno]),a.uniform1i(this.s_texture1_Loc_Off,2);var p=this.getClipBufPre_clipContextDraw().layoutChannelNo,f=this.getChannelFlagAsColor(p);a.uniform4f(this.u_channelFlag_Loc_Off,f.r,f.g,f.b,f.a),a.uniform4f(this.u_baseColor_Loc_Off,h,l,$,u)}else a.useProgram(this.shaderProgram),this._$vS=Tt(a,this._$vS,r),this._$no=Pt(a,this._$no,e),a.enableVertexAttribArray(this.a_position_Loc),a.vertexAttribPointer(this.a_position_Loc,2,a.FLOAT,!1,0,0),this._$NT=Tt(a,this._$NT,o),a.activeTexture(a.TEXTURE1),a.bindTexture(a.TEXTURE_2D,this.textures[t]),a.uniform1i(this.s_texture0_Loc,1),a.enableVertexAttribArray(this.a_texCoord_Loc),a.vertexAttribPointer(this.a_texCoord_Loc,2,a.FLOAT,!1,0,0),a.uniformMatrix4fv(this.u_matrix_Loc,!1,this.matrix4x4),a.uniform4f(this.u_baseColor_Loc,h,l,$,u),a.uniform1i(this.u_maskFlag_Loc,!1);this.culling?this.gl.enable(a.CULL_FACE):this.gl.disable(a.CULL_FACE),this.gl.enable(a.BLEND);var d,g,y,m;if(null!=this.clipBufPre_clipContextMask)d=a.ONE,g=a.ONE_MINUS_SRC_ALPHA,y=a.ONE,m=a.ONE_MINUS_SRC_ALPHA;else switch(s){case $t._$ms:d=a.ONE,g=a.ONE_MINUS_SRC_ALPHA,y=a.ONE,m=a.ONE_MINUS_SRC_ALPHA;break;case $t._$ns:d=a.ONE,g=a.ONE,y=a.ZERO,m=a.ONE;break;case $t._$_s:d=a.DST_COLOR,g=a.ONE_MINUS_SRC_ALPHA,y=a.ZERO,m=a.ONE}a.blendEquationSeparate(a.FUNC_ADD,a.FUNC_ADD),a.blendFuncSeparate(d,g,y,m),this.anisotropyExt&&a.texParameteri(a.TEXTURE_2D,this.anisotropyExt.TEXTURE_MAX_ANISOTROPY_EXT,this.maxAnisotropy);var T=e.length;a.drawElements(a.TRIANGLES,T,a.UNSIGNED_SHORT,0),a.bindTexture(a.TEXTURE_2D,null)}},mt.prototype._$Rs=function(){throw new Error("_$Rs")},mt.prototype._$Ds=function(t){throw new Error("_$Ds")},mt.prototype._$K2=function(){for(var t=0;t=48){var r=G._$9o(t);return null!=r?(r._$F0(this),r):null}switch(t){case 1:return this._$bT();case 10:return new n(this._$6L(),!0);case 11:return new S(this._$mP(),this._$mP(),this._$mP(),this._$mP());case 12:return new S(this._$_T(),this._$_T(),this._$_T(),this._$_T());case 13:return new L(this._$mP(),this._$mP());case 14:return new L(this._$_T(),this._$_T());case 15:for(var o=this._$3L(),e=new Array(o),s=0;s>7-this._$hL++&1)},St.prototype._$zT=function(){0!=this._$hL&&(this._$hL=0)},vt.prototype._$wP=function(t,i,e){for(var r=0;rMath.PI;)e-=2*Math.PI;return e},Lt._$9=function(t){return Math.sin(t)},Lt.fcos=function(t){return Math.cos(t)},Mt.prototype._$u2=function(){return this._$IS[0]},Mt.prototype._$yo=function(){return this._$AT&&!this._$IS[0]},Mt.prototype._$GT=function(){return this._$e0},Et._$W2=0,Et.SYSTEM_INFO=null,Et.USER_AGENT=navigator.userAgent,Et.isIPhone=function(){return Et.SYSTEM_INFO||Et.setup(),Et.SYSTEM_INFO._isIPhone},Et.isIOS=function(){return Et.SYSTEM_INFO||Et.setup(),Et.SYSTEM_INFO._isIPhone||Et.SYSTEM_INFO._isIPad},Et.isAndroid=function(){return Et.SYSTEM_INFO||Et.setup(),Et.SYSTEM_INFO._isAndroid},Et.getOSVersion=function(){return Et.SYSTEM_INFO||Et.setup(),Et.SYSTEM_INFO.version},Et.getOS=function(){return Et.SYSTEM_INFO||Et.setup(),Et.SYSTEM_INFO._isIPhone||Et.SYSTEM_INFO._isIPad?"iOS":Et.SYSTEM_INFO._isAndroid?"Android":"_$Q0 OS"},Et.setup=function(){function t(t,i){for(var e=t.substring(i).split(/[ _,;\.]/),r=0,o=0;o<=2&&!isNaN(e[o]);o++){var n=parseInt(e[o]);if(n<0||n>999){_._$li("err : "+n+" @UtHtml5.setup()"),r=0;break}r+=n*Math.pow(1e3,2-o)}return r}var i,e=Et.USER_AGENT,r=Et.SYSTEM_INFO={userAgent:e};if((i=e.indexOf("iPhone OS "))>=0)r.os="iPhone",r._isIPhone=!0,r.version=t(e,i+"iPhone OS ".length);else if((i=e.indexOf("iPad"))>=0){if((i=e.indexOf("CPU OS"))<0)return void _._$li(" err : "+e+" @UtHtml5.setup()");r.os="iPad",r._isIPad=!0,r.version=t(e,i+"CPU OS ".length)}else(i=e.indexOf("Android"))>=0?(r.os="Android",r._isAndroid=!0,r.version=t(e,i+"Android ".length)):(r.os="-",r.version=-1)},window.UtSystem=w,window.UtDebug=_,window.LDTransform=gt,window.LDGL=nt,window.Live2D=at,window.Live2DModelWebGL=ft,window.Live2DModelJS=q,window.Live2DMotion=J,window.MotionQueueManager=ct,window.PhysicsHair=f,window.AMotion=s,window.PartsDataID=l,window.DrawDataID=b,window.BaseDataID=yt,window.ParamID=u,at.init();var At=!1}()}).call(i,e(7))},function(t,i){t.exports={import:function(){throw new Error("System.import cannot be used indirectly")}}},function(t,i,e){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(){this.models=[],this.count=-1,this.reloadFlg=!1,Live2D.init(),n.Live2DFramework.setPlatformManager(new _.default)}Object.defineProperty(i,"__esModule",{value:!0}),i.default=o;var n=e(0),s=e(9),_=r(s),a=e(10),h=r(a),l=e(1),$=r(l);o.prototype.createModel=function(){var t=new h.default;return this.models.push(t),t},o.prototype.changeModel=function(t,i){if(this.reloadFlg){this.reloadFlg=!1;this.releaseModel(0,t),this.createModel(),this.models[0].load(t,i)}},o.prototype.getModel=function(t){return t>=this.models.length?null:this.models[t]},o.prototype.releaseModel=function(t,i){this.models.length<=t||(this.models[t].release(i),delete this.models[t],this.models.splice(t,1))},o.prototype.numModels=function(){return this.models.length},o.prototype.setDrag=function(t,i){for(var e=0;e0){r.expressions={};for(var t=0;t
+
+
+
+
+
+
+
+
+
+
+
+ `);
+ // https://stackoverflow.com/questions/24148403/trigger-css-transition-on-appended-element
+ setTimeout(() => {
+ document.getElementById("waifu").style.bottom = 0;
+ }, 0);
+
+ function randomSelection(obj) {
+ return Array.isArray(obj) ? obj[Math.floor(Math.random() * obj.length)] : obj;
+ }
+ // 检测用户活动状态,并在空闲时显示消息
+ let userAction = false,
+ userActionTimer,
+ messageTimer,
+ messageArray = ["好久不见,日子过得好快呢……", "大坏蛋!你都多久没理人家了呀,嘤嘤嘤~", "嗨~快来逗我玩吧!", "拿小拳拳锤你胸口!", "记得把小家加入 Adblock 白名单哦!"];
+ window.addEventListener("mousemove", () => userAction = true);
+ window.addEventListener("keydown", () => userAction = true);
+ setInterval(() => {
+ if (userAction) {
+ userAction = false;
+ clearInterval(userActionTimer);
+ userActionTimer = null;
+ } else if (!userActionTimer) {
+ userActionTimer = setInterval(() => {
+ showMessage(randomSelection(messageArray), 6000, 9);
+ }, 20000);
+ }
+ }, 1000);
+
+ (function registerEventListener() {
+ document.querySelector("#waifu-tool .fa-comment").addEventListener("click", showHitokoto);
+ document.querySelector("#waifu-tool .fa-paper-plane").addEventListener("click", () => {
+ if (window.Asteroids) {
+ if (!window.ASTEROIDSPLAYERS) window.ASTEROIDSPLAYERS = [];
+ window.ASTEROIDSPLAYERS.push(new Asteroids());
+ } else {
+ const script = document.createElement("script");
+ script.src = "https://fastly.jsdelivr.net/gh/stevenjoezhang/asteroids/asteroids.js";
+ document.head.appendChild(script);
+ }
+ });
+ document.querySelector("#waifu-tool .fa-user-circle").addEventListener("click", loadOtherModel);
+ document.querySelector("#waifu-tool .fa-street-view").addEventListener("click", loadRandModel);
+ document.querySelector("#waifu-tool .fa-camera-retro").addEventListener("click", () => {
+ showMessage("照好了嘛,是不是很可爱呢?", 6000, 9);
+ Live2D.captureName = "photo.png";
+ Live2D.captureFrame = true;
+ });
+ document.querySelector("#waifu-tool .fa-info-circle").addEventListener("click", () => {
+ open("https://github.com/stevenjoezhang/live2d-widget");
+ });
+ document.querySelector("#waifu-tool .fa-times").addEventListener("click", () => {
+ localStorage.setItem("waifu-display", Date.now());
+ showMessage("愿你有一天能与重要的人重逢。", 2000, 11);
+ document.getElementById("waifu").style.bottom = "-500px";
+ setTimeout(() => {
+ document.getElementById("waifu").style.display = "none";
+ document.getElementById("waifu-toggle").classList.add("waifu-toggle-active");
+ }, 3000);
+ });
+ const devtools = () => {};
+ console.log("%c", devtools);
+ devtools.toString = () => {
+ showMessage("哈哈,你打开了控制台,是想要看看我的小秘密吗?", 6000, 9);
+ };
+ window.addEventListener("copy", () => {
+ showMessage("你都复制了些什么呀,转载要记得加上出处哦!", 6000, 9);
+ });
+ window.addEventListener("visibilitychange", () => {
+ if (!document.hidden) showMessage("哇,你终于回来了~", 6000, 9);
+ });
+ })();
+
+ (function welcomeMessage() {
+ let text;
+ if (location.pathname === "/") { // 如果是主页
+ const now = new Date().getHours();
+ if (now > 5 && now <= 7) text = "早上好!一日之计在于晨,美好的一天就要开始了。";
+ else if (now > 7 && now <= 11) text = "上午好!工作顺利嘛,不要久坐,多起来走动走动哦!";
+ else if (now > 11 && now <= 13) text = "中午了,工作了一个上午,现在是午餐时间!";
+ else if (now > 13 && now <= 17) text = "午后很容易犯困呢,今天的运动目标完成了吗?";
+ else if (now > 17 && now <= 19) text = "傍晚了!窗外夕阳的景色很美丽呢,最美不过夕阳红~";
+ else if (now > 19 && now <= 21) text = "晚上好,今天过得怎么样?";
+ else if (now > 21 && now <= 23) text = ["已经这么晚了呀,早点休息吧,晚安~", "深夜时要爱护眼睛呀!"];
+ else text = "你是夜猫子呀?这么晚还不睡觉,明天起的来嘛?";
+ } else if (document.referrer !== "") {
+ const referrer = new URL(document.referrer),
+ domain = referrer.hostname.split(".")[1];
+ if (location.hostname === referrer.hostname) text = `欢迎阅读「${document.title.split(" - ")[0]}」`;
+ else if (domain === "baidu") text = `Hello!来自 百度搜索 的朋友
你是搜索 ${referrer.search.split("&wd=")[1].split("&")[0]} 找到的我吗?`;
+ else if (domain === "so") text = `Hello!来自 360搜索 的朋友
你是搜索 ${referrer.search.split("&q=")[1].split("&")[0]} 找到的我吗?`;
+ else if (domain === "google") text = `Hello!来自 谷歌搜索 的朋友
欢迎阅读「${document.title.split(" - ")[0]}」`;
+ else text = `Hello!来自 ${referrer.hostname} 的朋友`;
+ } else {
+ text = `欢迎阅读「${document.title.split(" - ")[0]}」`;
+ }
+ showMessage(text, 7000, 8);
+ })();
+
+ function showHitokoto() {
+ // 增加 hitokoto.cn 的 API
+ fetch("https://v1.hitokoto.cn")
+ .then(response => response.json())
+ .then(result => {
+ const text = `这句一言来自 「${result.from}」,是 ${result.creator} 在 hitokoto.cn 投稿的。`;
+ showMessage(result.hitokoto, 6000, 9);
+ setTimeout(() => {
+ showMessage(text, 4000, 9);
+ }, 6000);
+ });
+ }
+
+ function showMessage(text, timeout, priority) {
+ if (!text || (sessionStorage.getItem("waifu-text") && sessionStorage.getItem("waifu-text") > priority)) return;
+ if (messageTimer) {
+ clearTimeout(messageTimer);
+ messageTimer = null;
+ }
+ text = randomSelection(text);
+ sessionStorage.setItem("waifu-text", priority);
+ const tips = document.getElementById("waifu-tips");
+ tips.innerHTML = text;
+ tips.classList.add("waifu-tips-active");
+ messageTimer = setTimeout(() => {
+ sessionStorage.removeItem("waifu-text");
+ tips.classList.remove("waifu-tips-active");
+ }, timeout);
+ }
+
+ (function initModel() {
+ let modelId = localStorage.getItem("modelId");
+ let target =localStorage.getItem("target");
+ if (modelId === null) {
+ // 首次访问加载 指定模型 的 指定材质
+ modelId = 11; // 模型 ID
+ target="HyperdimensionNeptunia/nepgear";//皮肤 //可换 HyperdimensionNeptunia/nepgear --- HyperdimensionNeptunia/vert_swimwear
+ }
+ loadModel(modelId, target);
+ fetch(waifuPath)
+ .then(response => response.json())
+ .then(result => {
+ window.addEventListener("mouseover", event => {
+ for (let { selector, text } of result.mouseover) {
+ if (!event.target.matches(selector)) continue;
+ text = randomSelection(text);
+ text = text.replace("{text}", event.target.innerText);
+ showMessage(text, 4000, 8);
+ return;
+ }
+ });
+ window.addEventListener("click", event => {
+ for (let { selector, text } of result.click) {
+ if (!event.target.matches(selector)) continue;
+ text = randomSelection(text);
+ text = text.replace("{text}", event.target.innerText);
+ showMessage(text, 4000, 8);
+ return;
+ }
+ });
+ result.seasons.forEach(({ date, text }) => {
+ const now = new Date(),
+ after = date.split("-")[0],
+ before = date.split("-")[1] || after;
+ if ((after.split("/")[0] <= now.getMonth() + 1 && now.getMonth() + 1 <= before.split("/")[0]) && (after.split("/")[1] <= now.getDate() && now.getDate() <= before.split("/")[1])) {
+ text = randomSelection(text);
+ text = text.replace("{year}", now.getFullYear());
+ //showMessage(text, 7000, true);
+ messageArray.push(text);
+ }
+ });
+ });
+ })();
+
+ async function loadModelList() {
+ const response = await fetch(`${cdnPath}model_list.json`);
+ modelList = await response.json();
+ }
+ //加载model
+ async function loadModel(modelId, target, message) {
+ localStorage.setItem("modelId", modelId);
+ localStorage.setItem("target", target);
+ showMessage(message, 4000, 10);
+ if (useCDN) {
+ loadlive2d("live2d", `${cdnPath}model/${target}/index.json`);
+ console.log(`Live2D 模型 ${modelId}-${target} 加载完成`);
+ } else {
+ loadlive2d("live2d", `${apiPath}get/?id=${modelId}-${modelTexturesId}`);
+ console.log(`Live2D 模型 ${modelId}-${modelTexturesId} 加载完成`);
+ }
+ }
+ //更换衣服
+ async function loadRandModel() {
+ const modelId = localStorage.getItem("modelId");
+ if (useCDN) {
+ if (!modelList) await loadModelList();
+ const target = randomSelection(modelList.models[modelId]);
+ localStorage.setItem("target", target);
+ loadlive2d("live2d", `${cdnPath}model/${target}/index.json`);
+ showMessage("我的新衣服好看嘛?", 4000, 10);
+ console.log(`Live2D 模型 ${modelId}-${target} 换装完成`);
+ } else {
+ // 可选 "rand"(随机), "switch"(顺序)
+ fetch(`${apiPath}rand_textures/?id=${modelId}-${modelTexturesId}`)
+ .then(response => response.json())
+ .then(result => {
+ if (result.textures.id === 1 && (modelTexturesId === 1 || modelTexturesId === 0)) showMessage("我还没有其他衣服呢!", 4000, 10);
+ else loadModel(modelId, result.textures.id, "我的新衣服好看嘛?");
+ });
+ }
+ }
+ //更换角色
+ async function loadOtherModel() {
+ let modelId = localStorage.getItem("modelId");
+ if (useCDN) {
+ if (!modelList) await loadModelList();
+ const index = (++modelId >= modelList.models.length) ? 0 : modelId;
+ const target = randomSelection(modelList.models[index]);
+ loadModel(index, target, modelList.messages[index]);
+ } else {
+ fetch(`${apiPath}switch/?id=${modelId}`)
+ .then(response => response.json())
+ .then(result => {
+ loadModel(result.model.id, 0, result.model.message);
+ });
+ }
+ }
+}
+
+function initWidget(config, apiPath) {
+ if (typeof config === "string") {
+ config = {
+ waifuPath: config,
+ apiPath
+ };
+ }
+ document.body.insertAdjacentHTML("beforeend", `
+ 看板娘
+
`);
+ const toggle = document.getElementById("waifu-toggle");
+ toggle.addEventListener("click", () => {
+ toggle.classList.remove("waifu-toggle-active");
+ if (toggle.getAttribute("first-time")) {
+ loadWidget(config);
+ toggle.removeAttribute("first-time");
+ } else {
+ localStorage.removeItem("waifu-display");
+ document.getElementById("waifu").style.display = "";
+ setTimeout(() => {
+ document.getElementById("waifu").style.bottom = 0;
+ }, 0);
+ }
+ });
+ if (localStorage.getItem("waifu-display") && Date.now() - localStorage.getItem("waifu-display") <= 86400000) {
+ toggle.setAttribute("first-time", true);
+ setTimeout(() => {
+ toggle.classList.add("waifu-toggle-active");
+ }, 0);
+ } else {
+ loadWidget(config);
+ }
+}
diff --git a/waifu-tips.json b/waifu-tips.json
new file mode 100644
index 0000000..d05f2ed
--- /dev/null
+++ b/waifu-tips.json
@@ -0,0 +1,224 @@
+{
+ "mouseover": [{
+ "selector": "#live2d",
+ "text": ["干嘛呢你,快把手拿开~~", "鼠…鼠标放错地方了!", "你要干嘛呀?", "喵喵喵?", "怕怕(ノ≧∇≦)ノ", "非礼呀!救命!", "这样的话,只能使用武力了!", "我要生气了哦", "不要动手动脚的!", "真…真的是不知羞耻!", "Hentai!"]
+ }, {
+ "selector": "#waifu-tool .fa-comment",
+ "text": ["猜猜我要说些什么?", "我从青蛙王子那里听到了不少人生经验。"]
+ }, {
+ "selector": "#waifu-tool .fa-paper-plane",
+ "text": ["要不要来玩飞机大战?", "这个按钮上写着「不要点击」。", "怎么,你想来和我玩个游戏?", "听说这样可以蹦迪!"]
+ }, {
+ "selector": "#waifu-tool .fa-user-circle",
+ "text": ["你是不是不爱人家了呀,呜呜呜~", "要见见我的姐姐嘛?", "想要看我妹妹嘛?", "要切换看板娘吗?"]
+ }, {
+ "selector": "#waifu-tool .fa-street-view",
+ "text": ["喜欢换装 PLAY 吗?", "这次要扮演什么呢?", "变装!", "让我们看看接下来会发生什么!"]
+ }, {
+ "selector": "#waifu-tool .fa-camera-retro",
+ "text": ["你要给我拍照呀?一二三~茄子~", "要不,我们来合影吧!", "保持微笑就好了~"]
+ }, {
+ "selector": "#waifu-tool .fa-info-circle",
+ "text": ["想要知道更多关于我的事么?", "这里记录着我搬家的历史呢。", "你想深入了解我什么呢?"]
+ }, {
+ "selector": "#waifu-tool .fa-times",
+ "text": ["到了要说再见的时候了吗?", "呜呜 QAQ 后会有期……", "不要抛弃我呀……", "我们,还能再见面吗……", "哼,你会后悔的!"]
+ }, {
+ "selector": ".menu-item-home a",
+ "text": ["点击前往首页,想回到上一页可以使用浏览器的后退功能哦。", "点它就可以回到首页啦!", "回首页看看吧。"]
+ }, {
+ "selector": ".menu-item-about a",
+ "text": ["你想知道我家主人是谁吗?", "这里有一些关于我家主人的秘密哦,要不要看看呢?", "发现主人出没地点!"]
+ }, {
+ "selector": ".menu-item-tags a",
+ "text": ["点击就可以看文章的标签啦!", "点击来查看所有标签哦。"]
+ }, {
+ "selector": ".menu-item-categories a",
+ "text": ["文章都分类好啦~", "点击来查看文章分类哦。"]
+ }, {
+ "selector": ".menu-item-archives a",
+ "text": ["翻页比较麻烦吗,那就来看看文章归档吧。", "文章目录都整理在这里啦!"]
+ }, {
+ "selector": ".menu-item-friends a",
+ "text": ["这是我的朋友们哦ヾ(◍°∇°◍)ノ゙", "要去大佬们的家看看吗?", "要去拜访一下我的朋友们吗?"]
+ }, {
+ "selector": ".menu-item-search a",
+ "text": ["找不到想看的内容?搜索看看吧!", "在找什么东西呢,需要帮忙吗?"]
+ }, {
+ "selector": ".menu-item a",
+ "text": ["快看看这里都有什么呢?"]
+ }, {
+ "selector": ".site-author",
+ "text": ["我家主人好看吗?", "这是我家主人(*´∇`*)"]
+ }, {
+ "selector": ".site-state",
+ "text": ["这是文章的统计信息~", "要不要点进去看看?"]
+ }, {
+ "selector": ".feed-link a",
+ "text": ["这里可以使用 RSS 订阅呢!", "利用 feed 订阅器,就能快速知道博客有没有更新了呢。"]
+ }, {
+ "selector": ".cc-opacity, .post-copyright-author",
+ "text": ["要记得规范转载哦。", "所有文章均采用 CC BY-NC-SA 4.0 许可协议~", "转载前要先注意下文章的版权协议呢。"]
+ }, {
+ "selector": ".links-of-author",
+ "text": ["这里是主人的常驻地址哦。", "这里有主人的联系方式!"]
+ }, {
+ "selector": ".followme",
+ "text": ["手机扫一下就能继续看,很方便呢~", "扫一扫,打开新世界的大门!"]
+ }, {
+ "selector": ".fancybox img, img.medium-zoom-image",
+ "text": ["点击图片可以放大呢!"]
+ }, {
+ "selector": ".copy-btn",
+ "text": ["代码可以直接点击复制哟。"]
+ }, {
+ "selector": ".highlight .table-container, .gist",
+ "text": ["GitHub!我是新手!", "PHP 是最好的语言!"]
+ }, {
+ "selector": "a[href^='mailto']",
+ "text": ["邮件我会及时回复的!", "点击就可以发送邮件啦~"]
+ }, {
+ "selector": "a[href^='/tags/']",
+ "text": ["要去看看 {text} 标签么?", "点它可以查看此标签下的所有文章哟!"]
+ }, {
+ "selector": "a[href^='/categories/']",
+ "text": ["要去看看 {text} 分类么?", "点它可以查看此分类下的所有文章哟!"]
+ }, {
+ "selector": ".post-title-link",
+ "text": ["要看看 {text} 这篇文章吗?"]
+ }, {
+ "selector": "a[rel='contents']",
+ "text": ["点击来阅读全文哦。"]
+ }, {
+ "selector": "a[itemprop='discussionUrl']",
+ "text": ["要去看看评论吗?"]
+ }, {
+ "selector": ".beian a",
+ "text": ["我也是有户口的人哦。", "我的主人可是遵纪守法的好主人。"]
+ }, {
+ "selector": ".container a[href^='http'], .nav-link .nav-text",
+ "text": ["要去看看 {text} 么?", "去 {text} 逛逛吧。", "到 {text} 看看吧。"]
+ }, {
+ "selector": ".back-to-top",
+ "text": ["点它就可以回到顶部啦!", "又回到最初的起点~", "要回到开始的地方么?"]
+ }, {
+ "selector": ".reward-container",
+ "text": ["我是不是棒棒哒~快给我点赞吧!", "要打赏我嘛?好期待啊~", "主人最近在吃土呢,很辛苦的样子,给他一些钱钱吧~"]
+ }, {
+ "selector": "#wechat",
+ "text": ["这是我的微信二维码~"]
+ }, {
+ "selector": "#alipay",
+ "text": ["这是我的支付宝哦!"]
+ }, {
+ "selector": "#bitcoin",
+ "text": ["这是我的比特币账号!"]
+ }, {
+ "selector": "#needsharebutton-postbottom .btn",
+ "text": ["好东西要让更多人知道才行哦。", "觉得文章有帮助的话,可以分享给更多需要的朋友呢。"]
+ }, {
+ "selector": ".need-share-button_weibo",
+ "text": ["微博?来分享一波喵!"]
+ }, {
+ "selector": ".need-share-button_wechat",
+ "text": ["分享到微信吧!"]
+ }, {
+ "selector": ".need-share-button_douban",
+ "text": ["分享到豆瓣好像也不错!"]
+ }, {
+ "selector": ".need-share-button_qqzone",
+ "text": ["QQ 空间,一键转发,耶~"]
+ }, {
+ "selector": ".need-share-button_twitter",
+ "text": ["Twitter?好像是不存在的东西?"]
+ }, {
+ "selector": ".need-share-button_facebook",
+ "text": ["emmm…FB 好像也是不存在的东西?"]
+ }, {
+ "selector": ".post-nav-item a[rel='next']",
+ "text": ["来看看下一篇文章吧。", "点它可以看下一篇文章哦!", "要翻到下一篇文章吗?"]
+ }, {
+ "selector": ".post-nav-item a[rel='prev']",
+ "text": ["来看看上一篇文章吧。", "点它可以看上一篇文章哦!", "要翻到上一篇文章吗?"]
+ }, {
+ "selector": ".extend.next",
+ "text": ["去下一页看看吧。", "点它可以前进哦!", "要翻到下一页吗?"]
+ }, {
+ "selector": ".extend.prev",
+ "text": ["去上一页看看吧。", "点它可以后退哦!", "要翻到上一页吗?"]
+ }, {
+ "selector": "input.vnick",
+ "text": ["该怎么称呼你呢?", "留下你的尊姓大名!"]
+ }, {
+ "selector": ".vmail",
+ "text": ["留下你的邮箱,不然就是无头像人士了!", "记得设置好 Gravatar 头像哦!", "为了方便通知你最新消息,一定要留下邮箱!"]
+ }, {
+ "selector": ".vlink",
+ "text": ["快快告诉我你的家在哪里,好让我去参观参观!"]
+ }, {
+ "selector": ".veditor",
+ "text": ["想要去评论些什么吗?", "要说点什么吗?", "觉得博客不错?快来留言和主人交流吧!"]
+ }, {
+ "selector": ".vcontrol a",
+ "text": ["你会不会熟练使用 Markdown 呀?", "使用 Markdown 让评论更美观吧~"]
+ }, {
+ "selector": ".vemoji-btn",
+ "text": ["要插入一个萌萌哒的表情吗?", "要来一发表情吗?"]
+ }, {
+ "selector": ".vpreview-btn",
+ "text": ["要预览一下你的发言吗?", "快看看你的评论有多少负熵!"]
+ }, {
+ "selector": ".vsubmit",
+ "text": ["评论没有审核,要对自己的发言负责哦~", "要提交了吗,请耐心等待回复哦~"]
+ }, {
+ "selector": ".vcontent",
+ "text": ["哇,快看看这个精彩评论!", "如果有疑问,请尽快留言哦~"]
+ }],
+ "click": [{
+ "selector": "#live2d",
+ "text": ["是…是不小心碰到了吧…", "萝莉控是什么呀?", "你看到我的小熊了吗?", "再摸的话我可要报警了!⌇●﹏●⌇", "110 吗,这里有个变态一直在摸我(ó﹏ò。)", "不要摸我了,我会告诉老婆来打你的!", "干嘛动我呀!小心我咬你!", "别摸我,有什么好摸的!"]
+ }, {
+ "selector": ".veditor",
+ "text": ["要吐槽些什么呢?", "一定要认真填写喵~", "有什么想说的吗?"]
+ }, {
+ "selector": ".vsubmit",
+ "text": ["输入验证码就可以提交评论啦~"]
+ }],
+ "seasons": [{
+ "date": "01/01",
+ "text": "元旦了呢,新的一年又开始了,今年是{year}年~"
+ }, {
+ "date": "02/14",
+ "text": "又是一年情人节,{year}年找到对象了嘛~"
+ }, {
+ "date": "03/08",
+ "text": "今天是国际妇女节!"
+ }, {
+ "date": "03/12",
+ "text": "今天是植树节,要保护环境呀!"
+ }, {
+ "date": "04/01",
+ "text": "悄悄告诉你一个秘密~今天是愚人节,不要被骗了哦~"
+ }, {
+ "date": "05/01",
+ "text": "今天是五一劳动节,计划好假期去哪里了吗~"
+ }, {
+ "date": "06/01",
+ "text": "儿童节了呢,快活的时光总是短暂,要是永远长不大该多好啊…"
+ }, {
+ "date": "09/03",
+ "text": "中国人民抗日战争胜利纪念日,铭记历史、缅怀先烈、珍爱和平、开创未来。"
+ }, {
+ "date": "09/10",
+ "text": "教师节,在学校要给老师问声好呀~"
+ }, {
+ "date": "10/01",
+ "text": "国庆节到了,为祖国母亲庆生!"
+ }, {
+ "date": "11/05-11/12",
+ "text": "今年的双十一是和谁一起过的呢~"
+ }, {
+ "date": "12/20-12/31",
+ "text": "这几天是圣诞节,主人肯定又去剁手买买买了~"
+ }]
+}
diff --git a/waifu.css b/waifu.css
new file mode 100644
index 0000000..5833d79
--- /dev/null
+++ b/waifu.css
@@ -0,0 +1,306 @@
+#waifu-toggle {
+ background-color: #fa0;
+ border-radius: 5px;
+ bottom: 66px;
+ color: #fff;
+ cursor: pointer;
+ font-size: 12px;
+ left: 0;
+ margin-left: -100px;
+ padding: 5px 2px 5px 5px;
+ position: fixed;
+ transition: margin-left 1s;
+ width: 60px;
+ writing-mode: vertical-rl;
+}
+
+#waifu-toggle.waifu-toggle-active {
+ margin-left: -50px;
+}
+
+#waifu-toggle.waifu-toggle-active:hover {
+ margin-left: -30px;
+}
+
+#waifu {
+ bottom: -1000px;
+ left: 0;
+ line-height: 0;
+ margin-bottom: -10px;
+ position: fixed;
+ transform: translateY(3px);
+ transition: transform .3s ease-in-out, bottom 3s ease-in-out;
+ z-index: 1;
+}
+
+#waifu:hover {
+ transform: translateY(0);
+}
+
+#waifu-tips {
+ animation: shake 50s ease-in-out 5s infinite;
+ background-color: rgba(236, 217, 188, .5);
+ border: 1px solid rgba(224, 186, 140, .62);
+ border-radius: 12px;
+ box-shadow: 0 3px 15px 2px rgba(191, 158, 118, .2);
+ font-size: 14px;
+ line-height: 24px;
+ margin: -30px 20px;
+ min-height: 70px;
+ opacity: 0;
+ overflow: hidden;
+ padding: 5px 10px;
+ position: absolute;
+ text-overflow: ellipsis;
+ transition: opacity 1s;
+ width: 250px;
+ word-break: break-all;
+}
+
+#waifu-tips.waifu-tips-active {
+ opacity: 1;
+ transition: opacity .2s;
+}
+
+#waifu-tips .fa-lg {
+ color: #0099cc;
+}
+
+#live2d {
+ cursor: grab;
+ height: 300px;
+ position: relative;
+ width: 300px;
+}
+
+#live2d:active {
+ cursor: grabbing;
+}
+
+#waifu-tool {
+ color: #aaa;
+ opacity: 0;
+ position: absolute;
+ right: -10px;
+ top: 70px;
+ transition: opacity 1s;
+}
+
+#waifu:hover #waifu-tool {
+ opacity: 1;
+}
+
+#waifu-tool .fa-lg {
+ color: #7b8c9d;
+ cursor: pointer;
+ display: block;
+ height: 30px;
+ text-align: center;
+ transition: color .3s;
+}
+
+#waifu-tool .fa-lg:hover {
+ color: #0684bd; /* #34495e */
+}
+
+@keyframes shake {
+ 2% {
+ transform: translate(.5px, -1.5px) rotate(-.5deg);
+ }
+
+ 4% {
+ transform: translate(.5px, 1.5px) rotate(1.5deg);
+ }
+
+ 6% {
+ transform: translate(1.5px, 1.5px) rotate(1.5deg);
+ }
+
+ 8% {
+ transform: translate(2.5px, 1.5px) rotate(.5deg);
+ }
+
+ 10% {
+ transform: translate(.5px, 2.5px) rotate(.5deg);
+ }
+
+ 12% {
+ transform: translate(1.5px, 1.5px) rotate(.5deg);
+ }
+
+ 14% {
+ transform: translate(.5px, .5px) rotate(.5deg);
+ }
+
+ 16% {
+ transform: translate(-1.5px, -.5px) rotate(1.5deg);
+ }
+
+ 18% {
+ transform: translate(.5px, .5px) rotate(1.5deg);
+ }
+
+ 20% {
+ transform: translate(2.5px, 2.5px) rotate(1.5deg);
+ }
+
+ 22% {
+ transform: translate(.5px, -1.5px) rotate(1.5deg);
+ }
+
+ 24% {
+ transform: translate(-1.5px, 1.5px) rotate(-.5deg);
+ }
+
+ 26% {
+ transform: translate(1.5px, .5px) rotate(1.5deg);
+ }
+
+ 28% {
+ transform: translate(-.5px, -.5px) rotate(-.5deg);
+ }
+
+ 30% {
+ transform: translate(1.5px, -.5px) rotate(-.5deg);
+ }
+
+ 32% {
+ transform: translate(2.5px, -1.5px) rotate(1.5deg);
+ }
+
+ 34% {
+ transform: translate(2.5px, 2.5px) rotate(-.5deg);
+ }
+
+ 36% {
+ transform: translate(.5px, -1.5px) rotate(.5deg);
+ }
+
+ 38% {
+ transform: translate(2.5px, -.5px) rotate(-.5deg);
+ }
+
+ 40% {
+ transform: translate(-.5px, 2.5px) rotate(.5deg);
+ }
+
+ 42% {
+ transform: translate(-1.5px, 2.5px) rotate(.5deg);
+ }
+
+ 44% {
+ transform: translate(-1.5px, 1.5px) rotate(.5deg);
+ }
+
+ 46% {
+ transform: translate(1.5px, -.5px) rotate(-.5deg);
+ }
+
+ 48% {
+ transform: translate(2.5px, -.5px) rotate(.5deg);
+ }
+
+ 50% {
+ transform: translate(-1.5px, 1.5px) rotate(.5deg);
+ }
+
+ 52% {
+ transform: translate(-.5px, 1.5px) rotate(.5deg);
+ }
+
+ 54% {
+ transform: translate(-1.5px, 1.5px) rotate(.5deg);
+ }
+
+ 56% {
+ transform: translate(.5px, 2.5px) rotate(1.5deg);
+ }
+
+ 58% {
+ transform: translate(2.5px, 2.5px) rotate(.5deg);
+ }
+
+ 60% {
+ transform: translate(2.5px, -1.5px) rotate(1.5deg);
+ }
+
+ 62% {
+ transform: translate(-1.5px, .5px) rotate(1.5deg);
+ }
+
+ 64% {
+ transform: translate(-1.5px, 1.5px) rotate(1.5deg);
+ }
+
+ 66% {
+ transform: translate(.5px, 2.5px) rotate(1.5deg);
+ }
+
+ 68% {
+ transform: translate(2.5px, -1.5px) rotate(1.5deg);
+ }
+
+ 70% {
+ transform: translate(2.5px, 2.5px) rotate(.5deg);
+ }
+
+ 72% {
+ transform: translate(-.5px, -1.5px) rotate(1.5deg);
+ }
+
+ 74% {
+ transform: translate(-1.5px, 2.5px) rotate(1.5deg);
+ }
+
+ 76% {
+ transform: translate(-1.5px, 2.5px) rotate(1.5deg);
+ }
+
+ 78% {
+ transform: translate(-1.5px, 2.5px) rotate(.5deg);
+ }
+
+ 80% {
+ transform: translate(-1.5px, .5px) rotate(-.5deg);
+ }
+
+ 82% {
+ transform: translate(-1.5px, .5px) rotate(-.5deg);
+ }
+
+ 84% {
+ transform: translate(-.5px, .5px) rotate(1.5deg);
+ }
+
+ 86% {
+ transform: translate(2.5px, 1.5px) rotate(.5deg);
+ }
+
+ 88% {
+ transform: translate(-1.5px, .5px) rotate(1.5deg);
+ }
+
+ 90% {
+ transform: translate(-1.5px, -.5px) rotate(-.5deg);
+ }
+
+ 92% {
+ transform: translate(-1.5px, -1.5px) rotate(1.5deg);
+ }
+
+ 94% {
+ transform: translate(.5px, .5px) rotate(-.5deg);
+ }
+
+ 96% {
+ transform: translate(2.5px, -.5px) rotate(-.5deg);
+ }
+
+ 98% {
+ transform: translate(-1.5px, -1.5px) rotate(-.5deg);
+ }
+
+ 0%, 100% {
+ transform: translate(0, 0) rotate(0);
+ }
+}