var aviepicker=(function(){var b={},a=null,c=null;b.background=(function(){var e=[],d=-1,f=null;f=function(h){var g=h<1?-1:1;if(d===-1){return null;}if(h<0){h*=-1;}while(h!==0){d+=g;d%=e.length;d=d<0?e.length-1:d;if(e[d].hidden===false){h-=1;}}};return{add:function(j,g,i,h){h=h||false;if(h===false&&d===-1){d=0;}e.push({name:j,url:g,name_image:i,hidden:h});return this;},image:function(){return e[d].url;},name:function(){return e[d].name;},name_img:function(){return e[d].name_image;},set_index:function(g){if(g<e.length){d=g;return d;}return null;},value:function(){if(d===-1){return null;}return e[d].n;},next:function(g){g=g||1;g%=e.length;f(g);return this;},prev:function(g){g=(-1*g)||-1;g%=e.length;f(g);return this;},unhide:function(){var h,g=null;for(h=0;h<e.length;h+=1){if(e[h].hidden===true){e[h].hidden=false;g=h;}}return g;}};}());a=function(){var f={},g={index:-1,vals:[]},e=null,h=null,d=null;e=function(k){var j=null;for(j=0;j<g.vals.length;j+=1){if(g.vals[j]===k){return true;}}return false;};h=function(){return g.vals[g.index];};d=function(){var i={},j=null;j=function(){return i[h()].vals[i[h()].index];};return{add:function(l,k,n,m){if(e(l)===true){if(i[l]===undefined){i[l]={index:0,vals:[]};}i[l].vals.push({name:k,pids:n,imgs:m});}return this;},next:function(){i[h()].index+=1;i[h()].index%=i[h()].vals.length;return this;},prev:function(){i[h()].index-=1;if(i[h()].index<0){i[h()].index=i[h()].vals.length-1;}return this;},pids:function(){return j().pids;},index:function(){return i[h()].index;},size:function(){return i[h()].vals.length;},set_pid:function(k){var m=null,l=null;for(m=0;m<g.vals.length;m+=1){for(l=0;l<i[g.vals[m]].vals.length;l+=1){if(i[g.vals[m]].vals[l].pids===k){i[g.vals[m]].index=l;return;}}}throw {name:"MissingPid",message:"Pid '"+k+"' does not exist."};},name:function(){return j().name;},images:function(){return j().imgs;}};};return{add_poses:function(i){if(g.index===-1){g.index=0;g.vals=[];}if(e(i)===true){throw {name:"DuplicateEntry",message:"Pose '"+i+"' already exists."};}g.vals.push(i);f[i]=[];return this;},pose:h,add_skin:function(k,j,i){if(e(k)===false){throw {name:"MissingEntry",message:"Pose '"+k+"' is missing."};}if(f[k]===undefined||f[k].vals===undefined){f[k]={index:0,vals:[]};}f[k].vals.push({skin:j,url:i});return this;},length_skin:function(){return f[h()].vals.length;},index_skin:function(){return f[h()].index;},next_skin:function(){f[h()].index+=1;f[h()].index%=f[h()].vals.length;return this;},prev_skin:function(){f[h()].index-=1;if(f[h()].index<0){f[h()].index=f[h()].vals.length-1;}return this;},name_skin:function(){return f[h()].vals[f[h()].index].skin;},url_skin:function(){return f[h()].vals[f[h()].index].url;},bottom:d(),hair:d(),shoe:d(),top:d()};};b.male=a();b.female=a();c=function(){var h="/media/",f=h+"background/",n=f+"names/",j="welcome",d="Milk",m="Ginger",i="Butterscotch",g="Mocha",l="Chocolate",k=h+"pose/",e=h+"avatars/";b.male.add_poses(j).add_skin(j,d,k+"ap001mt0_milk.png").add_skin(j,m,k+"ap001mt0_ginger.png").add_skin(j,i,k+"ap001mt0_butterscotch.png").add_skin(j,g,k+"ap001mt0_mocha.png").add_skin(j,l,k+"ap001mt0_chocolate.png");b.male.bottom.add(j,"Blue Shorts","1000907",[{img:e+"ap001mt0_1000907.png",zindex:20}]).add(j,"Long Pants","1000892",[{img:e+"ap001mt0_1000892.png",zindex:20}]).add(j,"Weekend Pants","1023509",[{img:e+"ap001mt0_1023509.png",zindex:20}]).add(j,"Surfer Shorts","1000901",[{img:e+"ap001mt0_1000901.png",zindex:20}]).add(j,"Bell Bottoms","1023539",[{img:e+"ap001mt0_1023539.png",zindex:20}]).add(j,"Black Jeans","1000894",[{img:e+"ap001mt0_1000894.png",zindex:20}]).add(j,"Bell Bottoms","1023542",[{img:e+"ap001mt0_1023542.png",zindex:20}]);b.male.hair.add(j,"The V","1000771",[{img:e+"ap001mt0_1000771.png",zindex:50}]).add(j,"The Line","1000739",[{img:e+"ap001mt0_1000739.png",zindex:50}]).add(j,"The Dude","1000634",[{img:e+"ap001mt0_1000634.png",zindex:50}]).add(j,"The Mod","1003337",[{img:e+"ap001mt0_1003337.png",zindex:50}]).add(j,"The Zack","1000686",[{img:e+"ap001mt0_1000686.png",zindex:50}]).add(j,"The Fro","1003396",[{img:e+"ap001mt0_1003396.png",zindex:50}]).add(j,"The Bif","1002027",[{img:e+"ap001mt0_1002027.png",zindex:50}]).add(j,"The Skullcap","1000863",[{img:e+"ap001mt0_1000863.png",zindex:50}]);b.male.shoe.add(j,"Sneakers","1000919",[{img:e+"ap001mt0_1000919.png",zindex:10}]).add(j,"Loafers","1000909",[{img:e+"ap001mt0_1000909.png",zindex:10}]).add(j,"Hiking Boots","1002267",[{img:e+"ap001mt0_1002267.png",zindex:10}]).add(j,"Sandals","1000914",[{img:e+"ap001mt0_1000914.png",zindex:10}]).add(j,"Classic Loafers","1000910",[{img:e+"ap001mt0_1000910.png",zindex:10}]).add(j,"Trail Runners","1000922",[{img:e+"ap001mt0_1000922.png",zindex:10}]).add(j,"Cuban Heels","1023538",[{img:e+"ap001mt0_1023538.png",zindex:10}]);b.male.top.add(j,"Motu Island","1023506",[{img:e+"ap001mt0_1023506.png",zindex:30}]).add(j,"Blue Hoodie","1001286",[{img:e+"ap001mt0_1001286.png",zindex:30}]).add(j,"Blue Oxford","1002257",[{img:e+"ap001mt0_1002257.png",zindex:30}]).add(j,"Fave T-Shirt","1000955",[{img:e+"ap001mt0_1000955.png",zindex:30}]).add(j,"Celery Vest","1023525",[{img:e+"ap001mt0_1023525.png",zindex:30}]).add(j,"Bowling Shirt","1000933",[{img:e+"ap001mt0_1000933.png",zindex:30}]).add(j,"Black Shirt","1002254",[{img:e+"ap001mt0_1002254.png",zindex:30}]).add(j,"White Tee","1001069",[{img:e+"ap001mt0_1001069.png",zindex:30}]);b.female.add_poses(j).add_skin(j,d,k+"ap001ft0_milk.png").add_skin(j,m,k+"ap001ft0_ginger.png").add_skin(j,i,k+"ap001ft0_butterscotch.png").add_skin(j,g,k+"ap001ft0_mocha.png").add_skin(j,l,k+"ap001ft0_chocolate.png");b.female.bottom.add(j,"Gold Capris","1000536",[{img:e+"ap001ft0_1000536.png",zindex:20}]).add(j,"Noir Capris","1000541",[{img:e+"ap001ft0_1000541.png",zindex:20}]).add(j,"Flare Pants","1023453",[{img:e+"ap001ft0_1023453.png",zindex:20}]).add(j,"Yellow Shorts","1023463",[{img:e+"ap001ft0_1023463.png",zindex:20}]).add(j,"Board Shorts","1000520",[{img:e+"ap001ft0_1000520.png",zindex:20}]).add(j,"Lounge Pants","1002241",[{img:e+"ap001ft0_1002241.png",zindex:20}]).add(j,"Evening Capris","1000533",[{img:e+"ap001ft0_1000533.png",zindex:20}]);b.female.hair.add(j,"The Flip","1000325",[{img:e+"ap001ft0_1000325.png",zindex:50}]).add(j,"The Pixie","1000259",[{img:e+"ap001ft0_1000259.png",zindex:50}]).add(j,"The Sweep","1000446",[{img:e+"ap001ft0_1000446.png",zindex:50}]).add(j,"The Bob","1000383",[{img:e+"ap001ft0_1000383.png",zindex:50}]).add(j,"The Medusa","1002163",[{img:e+"ap001ft0_1002163.png",zindex:50}]).add(j,"The Dazzle","1000363",[{img:e+"ap001ft0_1000363.png",zindex:50}]).add(j,"The Fro","1003240",[{img:e+"ap001ft0_1003240.png",zindex:50}]).add(j,"The Hudson","1023580",[{img:e+"ap001ft0_1023580.png",zindex:50}]);b.female.shoe.add(j,"White Sneakers","1001064",[{img:e+"ap001ft0_1001064.png",zindex:10}]).add(j,"Trail Runners","1000559",[{img:e+"ap001ft0_1000559.png",zindex:10}]).add(j,"Sneakers","1000556",[{img:e+"ap001ft0_1000556.png",zindex:10}]).add(j,"Red Check","1000547",[{img:e+"ap001ft0_1000547.png",zindex:10}]).add(j,"Flip-Flops","1023444",[{img:e+"ap001ft0_1023444.png",zindex:10}]).add(j,"Hiking Boots","1002248",[{img:e+"ap001ft0_1002248.png",zindex:10}]).add(j,"Leopard","1000549",[{img:e+"ap001ft0_1000549.png",zindex:10}]);b.female.top.add(j,"White Lace Top","1023431",[{img:e+"ap001ft0_1023431.png",zindex:30}]).add(j,"Yellow Hoodie","1001281",[{img:e+"ap001ft0_1001281.png",zindex:30}]).add(j,"Rose Tee","1000581",[{img:e+"ap001ft0_1000581.png",zindex:30}]).add(j,"Cream Jacket","1023448",[{img:e+"ap001ft0_1023448.png",zindex:30}]).add(j,"Plaid Oxford","1002238",[{img:e+"ap001ft0_1002238.png",zindex:30}]).add(j,"Black Jacket","1023446",[{img:e+"ap001ft0_1023446.png",zindex:30}]).add(j,"Black Jacket","1023433",[{img:e+"ap001ft0_1023433.png",zindex:30}]).add(j,"Red Halter Top","1023459",[{img:e+"ap001ft0_1023459.png",zindex:30}]);b.background.add("Forest",f+"bg007www_forest.jpg",n+"sevensacredpools.png").add("Suburb",f+"bg001www_winter09.jpg",n+"CharityTreePark.png").add("Desert",f+"bg002www_desert.jpg",n+"MizmarCafe.png").add("Night",f+"bg003www_night.jpg",n+"ClubCaldera.png").add("Interior",f+"bg004www_interior.jpg",n+"HouseofGlass.png").add("Urban",f+"bg005www_urban.jpg",n+"JacksonSquare.png").add("Welcome Walkway",f+"bg006www_welcomewalkway.jpg",n+"WelcomeWalkway.png",true);};c();return b;}());

