forked from metin2/web
Shop improvements, renamed "shop" to "mall", support for Argon2ID
This commit is contained in:
BIN
public/assets/mall/js/function.js
Normal file
BIN
public/assets/mall/js/function.js
Normal file
Binary file not shown.
After Width: | Height: | Size: 12 KiB |
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -0,0 +1,12 @@
|
||||
/*! Copyright (c) 2011 Brandon Aaron (http://brandonaaron.net)
|
||||
* Licensed under the MIT License (LICENSE.txt).
|
||||
*
|
||||
* Thanks to: http://adomas.org/javascript-mouse-wheel/ for some pointers.
|
||||
* Thanks to: Mathias Bank(http://www.mathias-bank.de) for a scope bug fix.
|
||||
* Thanks to: Seamus Leahy for adding deltaX and deltaY
|
||||
*
|
||||
* Version: 3.0.6
|
||||
*
|
||||
* Requires: 1.2.2+
|
||||
*/
|
||||
(function(d){var b=["DOMMouseScroll","mousewheel"];if(d.event.fixHooks){for(var a=b.length;a;){d.event.fixHooks[b[--a]]=d.event.mouseHooks}}d.event.special.mousewheel={setup:function(){if(this.addEventListener){for(var e=b.length;e;){this.addEventListener(b[--e],c,false)}}else{this.onmousewheel=c}},teardown:function(){if(this.removeEventListener){for(var e=b.length;e;){this.removeEventListener(b[--e],c,false)}}else{this.onmousewheel=null}}};d.fn.extend({mousewheel:function(e){return e?this.bind("mousewheel",e):this.trigger("mousewheel")},unmousewheel:function(e){return this.unbind("mousewheel",e)}});function c(j){var h=j||window.event,g=[].slice.call(arguments,1),k=0,i=true,f=0,e=0;j=d.event.fix(h);j.type="mousewheel";if(h.wheelDelta){k=h.wheelDelta/120}if(h.detail){k=-h.detail/3}e=k;if(h.axis!==undefined&&h.axis===h.HORIZONTAL_AXIS){e=0;f=-1*k}if(h.wheelDeltaY!==undefined){e=h.wheelDeltaY/120}if(h.wheelDeltaX!==undefined){f=-1*h.wheelDeltaX/120}g.unshift(j,k,f,e);return(d.event.dispatch||d.event.handle).apply(this,g)}})(jQuery);
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -0,0 +1 @@
|
||||
(function(a){a.fn.tipTip=function(c){var g={activation:"hover",keepAlive:false,maxWidth:"200px",edgeOffset:3,defaultPosition:"bottom",delay:400,fadeIn:200,fadeOut:200,attribute:"title",content:false,enter:function(){},exit:function(){}};var e=a.extend(g,c);if(a("#tiptip_holder").length<=0){var b=a('<div id="tiptip_holder" style="max-width:'+e.maxWidth+';"></div>');var d=a('<div id="tiptip_content"></div>');var f=a('<div id="tiptip_arrow"></div>');a("body").append(b.html(d).prepend(f.html('<div id="tiptip_arrow_inner"></div>')))}else{var b=a("#tiptip_holder");var d=a("#tiptip_content");var f=a("#tiptip_arrow")}return this.each(function(){var i=a(this);if(e.content){var l=e.content}else{var l=i.attr(e.attribute)}if(l!=""){if(!e.content){i.removeAttr(e.attribute)}var h=false;if(e.activation=="hover"){i.hover(function(){k()},function(){if(!e.keepAlive){j()}});if(e.keepAlive){b.hover(function(){},function(){j()})}}else{if(e.activation=="focus"){i.focus(function(){k()}).blur(function(){j()})}else{if(e.activation=="click"){i.click(function(){k();return false}).hover(function(){},function(){if(!e.keepAlive){j()}});if(e.keepAlive){b.hover(function(){},function(){j()})}}}}function k(){e.enter.call(this);d.html(l);b.hide().removeAttr("class").css("margin","0");f.removeAttr("style");var y=parseInt(i.offset()["top"]);var p=parseInt(i.offset()["left"]);var v=parseInt(i.outerWidth());var A=parseInt(i.outerHeight());var x=b.outerWidth();var s=b.outerHeight();var w=Math.round((v-x)/2);var o=Math.round((A-s)/2);var n=Math.round(p+w);var m=Math.round(y+A+e.edgeOffset);var t="";var C="";var u=Math.round(x-12)/2;if(e.defaultPosition=="bottom"){t="_bottom"}else{if(e.defaultPosition=="top"){t="_top"}else{if(e.defaultPosition=="left"){t="_left"}else{if(e.defaultPosition=="right"){t="_right"}}}}var r=(w+p)<parseInt(a(window).scrollLeft());var q=(x+p)>parseInt(a(window).width());if((r&&w<0)||(t=="_right"&&!q)||(t=="_left"&&p<(x+e.edgeOffset+5))){t="_right";C=Math.round(s-13)/2;u=-12;n=Math.round(p+v+e.edgeOffset);m=Math.round(y+o)}else{if((q&&w<0)||(t=="_left"&&!r)){t="_left";C=Math.round(s-13)/2;u=Math.round(x);n=Math.round(p-(x+e.edgeOffset+5));m=Math.round(y+o)}}var z=0;if(t=="_bottom"){z=(y+A+e.edgeOffset+s+8)>parseInt(a(window).height()+a(window).scrollTop())}else{z=(y+A/2+e.edgeOffset+s/2+8)>parseInt(a(window).height()+a(window).scrollTop())}var B=((y+A)-(e.edgeOffset+s+8))<0;if(z||(t=="_bottom"&&z)||(t=="_top"&&!B)){if(t=="_top"||t=="_bottom"){t="_top"}else{t=t+"_top"}C=s;m=Math.round(y-(s+5+e.edgeOffset))}else{if(B|(t=="_top"&&B)||(t=="_bottom"&&!z)){if(t=="_top"||t=="_bottom"){t="_bottom"}else{t=t+"_bottom"}C=-12;m=Math.round(y+A+e.edgeOffset)}}if(t=="_right_top"||t=="_left_top"){m=m+5}else{if(t=="_right_bottom"||t=="_left_bottom"){m=m-5}}if(t=="_left_top"||t=="_left_bottom"){n=n+5}f.css({"margin-left":u+"px","margin-top":C+"px"});b.css({"margin-left":n+"px","margin-top":m+"px"}).attr("class","tip"+t);if(h){clearTimeout(h)}h=setTimeout(function(){b.stop(true,true).fadeIn(e.fadeIn)},e.delay)}function j(){e.exit.call(this);if(h){clearTimeout(h)}b.fadeOut(e.fadeOut)}}})}})(jQuery);
|
@ -0,0 +1 @@
|
||||
jQuery.easing.jswing=jQuery.easing.swing;jQuery.extend(jQuery.easing,{def:"easeOutQuad",swing:function(e,f,a,h,g){return jQuery.easing[jQuery.easing.def](e,f,a,h,g)},easeInQuad:function(e,f,a,h,g){return h*(f/=g)*f+a},easeOutQuad:function(e,f,a,h,g){return -h*(f/=g)*(f-2)+a},easeInOutQuad:function(e,f,a,h,g){if((f/=g/2)<1){return h/2*f*f+a}return -h/2*((--f)*(f-2)-1)+a},easeInCubic:function(e,f,a,h,g){return h*(f/=g)*f*f+a},easeOutCubic:function(e,f,a,h,g){return h*((f=f/g-1)*f*f+1)+a},easeInOutCubic:function(e,f,a,h,g){if((f/=g/2)<1){return h/2*f*f*f+a}return h/2*((f-=2)*f*f+2)+a},easeInQuart:function(e,f,a,h,g){return h*(f/=g)*f*f*f+a},easeOutQuart:function(e,f,a,h,g){return -h*((f=f/g-1)*f*f*f-1)+a},easeInOutQuart:function(e,f,a,h,g){if((f/=g/2)<1){return h/2*f*f*f*f+a}return -h/2*((f-=2)*f*f*f-2)+a},easeInQuint:function(e,f,a,h,g){return h*(f/=g)*f*f*f*f+a},easeOutQuint:function(e,f,a,h,g){return h*((f=f/g-1)*f*f*f*f+1)+a},easeInOutQuint:function(e,f,a,h,g){if((f/=g/2)<1){return h/2*f*f*f*f*f+a}return h/2*((f-=2)*f*f*f*f+2)+a},easeInSine:function(e,f,a,h,g){return -h*Math.cos(f/g*(Math.PI/2))+h+a},easeOutSine:function(e,f,a,h,g){return h*Math.sin(f/g*(Math.PI/2))+a},easeInOutSine:function(e,f,a,h,g){return -h/2*(Math.cos(Math.PI*f/g)-1)+a},easeInExpo:function(e,f,a,h,g){return(f==0)?a:h*Math.pow(2,10*(f/g-1))+a},easeOutExpo:function(e,f,a,h,g){return(f==g)?a+h:h*(-Math.pow(2,-10*f/g)+1)+a},easeInOutExpo:function(e,f,a,h,g){if(f==0){return a}if(f==g){return a+h}if((f/=g/2)<1){return h/2*Math.pow(2,10*(f-1))+a}return h/2*(-Math.pow(2,-10*--f)+2)+a},easeInCirc:function(e,f,a,h,g){return -h*(Math.sqrt(1-(f/=g)*f)-1)+a},easeOutCirc:function(e,f,a,h,g){return h*Math.sqrt(1-(f=f/g-1)*f)+a},easeInOutCirc:function(e,f,a,h,g){if((f/=g/2)<1){return -h/2*(Math.sqrt(1-f*f)-1)+a}return h/2*(Math.sqrt(1-(f-=2)*f)+1)+a},easeInElastic:function(f,h,e,l,k){var i=1.70158;var j=0;var g=l;if(h==0){return e}if((h/=k)==1){return e+l}if(!j){j=k*0.3}if(g<Math.abs(l)){g=l;var i=j/4}else{var i=j/(2*Math.PI)*Math.asin(l/g)}return -(g*Math.pow(2,10*(h-=1))*Math.sin((h*k-i)*(2*Math.PI)/j))+e},easeOutElastic:function(f,h,e,l,k){var i=1.70158;var j=0;var g=l;if(h==0){return e}if((h/=k)==1){return e+l}if(!j){j=k*0.3}if(g<Math.abs(l)){g=l;var i=j/4}else{var i=j/(2*Math.PI)*Math.asin(l/g)}return g*Math.pow(2,-10*h)*Math.sin((h*k-i)*(2*Math.PI)/j)+l+e},easeInOutElastic:function(f,h,e,l,k){var i=1.70158;var j=0;var g=l;if(h==0){return e}if((h/=k/2)==2){return e+l}if(!j){j=k*(0.3*1.5)}if(g<Math.abs(l)){g=l;var i=j/4}else{var i=j/(2*Math.PI)*Math.asin(l/g)}if(h<1){return -0.5*(g*Math.pow(2,10*(h-=1))*Math.sin((h*k-i)*(2*Math.PI)/j))+e}return g*Math.pow(2,-10*(h-=1))*Math.sin((h*k-i)*(2*Math.PI)/j)*0.5+l+e},easeInBack:function(e,f,a,i,h,g){if(g==undefined){g=1.70158}return i*(f/=h)*f*((g+1)*f-g)+a},easeOutBack:function(e,f,a,i,h,g){if(g==undefined){g=1.70158}return i*((f=f/h-1)*f*((g+1)*f+g)+1)+a},easeInOutBack:function(e,f,a,i,h,g){if(g==undefined){g=1.70158}if((f/=h/2)<1){return i/2*(f*f*(((g*=(1.525))+1)*f-g))+a}return i/2*((f-=2)*f*(((g*=(1.525))+1)*f+g)+2)+a},easeInBounce:function(e,f,a,h,g){return h-jQuery.easing.easeOutBounce(e,g-f,0,h,g)+a},easeOutBounce:function(e,f,a,h,g){if((f/=g)<(1/2.75)){return h*(7.5625*f*f)+a}else{if(f<(2/2.75)){return h*(7.5625*(f-=(1.5/2.75))*f+0.75)+a}else{if(f<(2.5/2.75)){return h*(7.5625*(f-=(2.25/2.75))*f+0.9375)+a}else{return h*(7.5625*(f-=(2.625/2.75))*f+0.984375)+a}}}},easeInOutBounce:function(e,f,a,h,g){if(f<g/2){return jQuery.easing.easeInBounce(e,f*2,0,h,g)*0.5+a}return jQuery.easing.easeOutBounce(e,f*2-g,0,h,g)*0.5+h*0.5+a}});
|
@ -0,0 +1 @@
|
||||
function showPurchases(a){var b=$("#show-purchase-button-"+a);if($("#table-content-"+a).is(":hidden")){b.attr("class","show-purchase-button-open");$("#table-content-"+a).slideDown("slow")}else{b.attr("class","show-purchase-button-close");$("#table-content-"+a).slideUp("slow")}};
|
File diff suppressed because one or more lines are too long
@ -0,0 +1 @@
|
||||
(function(d){d.fn.jCarouselLite=function(e){e=d.extend({btnPrev:null,btnNext:null,btnGo:null,mouseWheel:false,auto:null,speed:200,easing:null,vertical:false,circular:true,visible:3,start:0,scroll:1,beforeStart:null,afterEnd:null},e||{});return this.each(function(){var w=false,n=e.vertical?"top":"left",i=e.vertical?"height":"width";var u=d(this),t=d("ul",u),l=d("li",t),y=l.size(),x=e.visible;if(e.circular){t.prepend(l.slice(y-x-1+1).clone()).append(l.slice(0,x).clone());e.start+=x}var s=d("li",t),r=s.size(),z=e.start;u.css("visibility","visible");s.css({overflow:"hidden","float":e.vertical?"none":"left"});t.css({margin:"0",padding:"0",position:"relative","list-style-type":"none","z-index":"1"});u.css({overflow:"hidden",position:"relative","z-index":"2",left:"0px"});var q=e.vertical?a(s):c(s);var p=q*r;var o=q*x;s.css({width:s.width(),height:s.height()});t.css(i,p+"px").css(n,-(z*q));u.css(i,o+"px");if(e.btnPrev){d(e.btnPrev).click(function(){return m(z-e.scroll)})}if(e.btnNext){d(e.btnNext).click(function(){return m(z+e.scroll)})}if(e.btnGo){d.each(e.btnGo,function(g,f){d(f).click(function(){return m(e.circular?e.visible+g:g)})})}if(e.mouseWheel&&u.mousewheel){u.mousewheel(function(f,g){return g>0?m(z-e.scroll):m(z+e.scroll)})}if(e.auto){setInterval(function(){m(z+e.scroll)},e.auto+e.speed)}function k(){return s.slice(z).slice(0,x)}function m(f){if(!w){if(e.beforeStart){e.beforeStart.call(this,k())}if(e.circular){if(f<=e.start-x-1){t.css(n,-((r-(x*2))*q)+"px");z=f==e.start-x-1?r-(x*2)-1:r-(x*2)-e.scroll}else{if(f>=r-x+1){t.css(n,-((x)*q)+"px");z=f==r-x+1?x+1:x+e.scroll}else{z=f}}}else{if(f<0||f>r-x){return}else{z=f}}w=true;t.animate(n=="left"?{left:-(z*q)}:{top:-(z*q)},e.speed,e.easing,function(){if(e.afterEnd){e.afterEnd.call(this,k())}w=false});if(!e.circular){d(e.btnPrev+","+e.btnNext).removeClass("disabled");d((z-e.scroll<0&&e.btnPrev)||(z+e.scroll>r-x&&e.btnNext)||[]).addClass("disabled")}}return false}})};function b(f,e){return parseInt(d.css(f[0],e))||0}function c(e){return e[0].offsetWidth+b(e,"marginLeft")+b(e,"marginRight")}function a(e){return e[0].offsetHeight+b(e,"marginTop")+b(e,"marginBottom")}})(jQuery);
|
@ -0,0 +1 @@
|
||||
function showHelpTip(a){$("#help").tipTip({activation:"click"}).trigger("click").unbind(".tipTip").removeData("tipTip").unbind("click");window.setTimeout('$("#tiptip_holder").fadeOut(500, function() {$("#help").tipTip({content:"'+a+'",activation:"hover"});});',6000)}function highlightNext(b,a,f){var h=b%16;if(h==0){h=16}if(b!=a){$("#pos"+h).animate({top:"-=10"},100).animate({top:"+=10"},400)}var g=(h-1)*312;if(clockwise){$("#spinner").css("background-position","0 -"+g+"px")}else{if(h==1){$("#spinner").css("background-position","0 0")}else{$("#spinner").css("background-position","0 -"+(4992-g)+"px")}}var e=a-b;var d=startingDelay;if(e<=f){d+=900-(e*Math.floor(900/f))}if(b==a){var c=1500;rewardPosition=h;animateReward(h);if(gotKey){openLock(h);c+=1000}window.setTimeout("showReward()",c)}else{window.setTimeout("highlightNext("+(b+1)+", "+a+", "+f+")",d)}}function animateReward(a){$("#pos"+a).css("z-index",2).animate({width:"+=60",height:"+=60",top:"-=30",left:"-=30"},200).animate({width:"-=40",height:"-=40",top:"+=20",left:"+=20"},300).animate({width:"+=30",height:"+=30",top:"-=15",left:"-=15"},300).animate({width:"-=20",height:"-=20",top:"+=10",left:"+=10"},400).animate({width:"+=10",height:"+=10",top:"-=5",left:"-=5"},400)}function openLock(b){var d=parseInt($("#key"+b).css("left"));var a=parseInt($("#key"+b).css("top"));var f=parseInt($(".unlockable").css("left"))+16;var c=parseInt($(".unlockable").css("top"))+16;var e=1000-parseInt(0.2*Math.sqrt(Math.pow(Math.abs(d-f),2)+Math.pow(Math.abs(a-c),2)));$("#key"+b).css("z-index",2).animate({left:parseInt(((f-d)/2)+d),top:parseInt(((c-a)/2)+a),width:80,height:80},parseInt(e/2),"linear").animate({left:f,top:c,width:10,height:10},parseInt(e/2),"linear").animate({width:80,height:80,left:f-35,top:c-35,opacity:0},400,"linear",function(){$("#key"+b).hide();$(".unlockable").addClass("open").removeClass("unlockable closed");if(gotLastKey){openExit()}})}function openExit(){$("#exitClosed").removeClass("enabled").addClass("disabled");$("#exitOpen").removeClass("disabled").addClass("enabled")}function showReward(){$.fancybox({href:"#reward",autoDimensions:false,width:340,height:"auto",overlayOpacity:0.6,showCloseButton:true,enableEscapeButton:false,hideOnOverlayClick:false,hideOnContentClick:false,padding:0,onStart:function(){$("#fancybox-outer").addClass("fancybox-outer-wheel")},onClosed:function(){$("#breadcrumbInfoText").fadeIn(1000);enableTips();$("#spinButton").fadeIn(600);$("#fancybox-outer").removeClass("fancybox-outer-wheel")}});$("#reward").find("div").bind("click",$.fancybox.close)}function enableTips(){$(".key, #locks div").addClass("tipTip").tipTip({content:keyTipText,enter:function(){$("#tiptip_content").removeClass()}});$("#exitClosed").tipTip({edgeOffset:-14,enter:function(){$("#tiptip_content").removeClass()}});$(".reward").each(function(){var a=$(this).find(".shopItemTipContent").html();if(a){$(this).addClass("shopItemTip");$(this).tipTip({content:a,keepAlive:true,enter:function(){$("#tiptip_content").removeClass();$("#tiptip_content").addClass("shopItemTipTip")},exit:function(){$("#tiptip_content").removeClass("shopItemTipTip")}})}else{var b=$(this).find(".nonShopItemTipContent").html();if(b){$(this).addClass("tipTip");$(this).tipTip({content:b,enter:function(){$("#tiptip_content").removeClass()}})}}})}function animation(){$(".reward").show();$("#spinnerBlank").fadeOut(2000,function(){$(".reward").css("z-index",2)});window.setTimeout("highlightNext(1, "+spinCount+", "+slowDownCount+")",3000)}function teaser(a,d){if(doTeaser){if(d>16){a++;d=1}if(a>3){a=1}var c=0;var b=0;$("#teaser"+a).find(".teaserPos"+d).each(function(){b=parseInt($(this).css("top"));c=parseInt($(this).css("left"));$(this).css({height:0,width:0,display:"block",left:c+20,top:b+20}).animate({width:"+=40",height:"+=40",top:"-=20",left:"-=20"},400).delay(800).animate({width:"-=40",height:"-=40",top:"+=20",left:"+=20"},400,function(){$(this).css({left:c,top:b})})});window.setTimeout("teaser("+a+", "+(d+1)+")",200)}}function reset(c,b){c.preventDefault();$("#tiptip_holder").fadeOut(500).remove();var a=b.attr("href");$("#breadcrumbInfoText").fadeOut(500);$(".reward").css("z-index",0);$("#pos"+rewardPosition).css("z-index",0).animate({width:"-=40",height:"-=40",top:"+=20",left:"+=20"},400,function(){$("#spinButton").fadeOut(500);$("#spinnerBlank").fadeIn(2000,function(){window.location=a})})}function start(c,b){c.preventDefault();var a=b.attr("href");doTeaser=false;$("#breadcrumbInfoText").fadeOut(500);if($("#teasers").find("img").is(":visible")){$("#teasers").fadeOut(500,function(){$("#spinButton").fadeOut(500,function(){window.location=a})})}else{$("#spinButton").fadeOut(500,function(){window.location=a})}};
|
File diff suppressed because one or more lines are too long
BIN
public/assets/mall/js/jquery.js
vendored
Normal file
BIN
public/assets/mall/js/jquery.js
vendored
Normal file
Binary file not shown.
Reference in New Issue
Block a user