OwlCyberSecurity - MANAGER
Edit File: dressup.js
var dressup = function(game) { } dressup.prototype = { create: function() { CenterX = this.world.centerX; CenterY = this.world.centerY; hairColor = 44; hlColor = 0; lipsColor = 6; bodyColor = 0; hlVisible = false; colorPage = 1; openedMenu = 1; openedMenuPage = 1; skinColorPage = 1; //this.game.renderer.renderSession.roundPixels = true; BG = this.add.sprite(0,-.5,"background"); BG2 = this.add.sprite(0,-.5,"background2"); BG3 = this.add.sprite(0,-.5,"background3"); BG2.visible = false; BG3.visible = false; /*Ref = this.add.sprite(249,391,"ref"); Ref.anchor.setTo(0.5,0.5);*/ Body = this.add.sprite(249,424,"body"); Body.anchor.setTo(0.5,0.5); Body.tint = BodyColor2[9]; Body_Outline = this.add.sprite(Body.x-1,Body.y+1.3,"body_outline"); Body_Outline.anchor.setTo(0.5,0.5); Bra = this.add.sprite(248,315,"bra"); Bra.anchor.setTo(0.5,0.5); Bra.visible = false; Head = this.add.sprite(286,205,"head"); Head.anchor.setTo(0.5,0.5); Head.tint = BodyColor2[9]; Head_Outline = this.add.sprite(Head.x,Head.y,"head_outline"); Head_Outline.anchor.setTo(0.5,0.5); Panties = this.add.sprite(251,393,"panties"); Panties.anchor.setTo(0.5,0.5); Panties.visible = false; SocksX = [269]; SocksY = [477]; Socks = this.add.sprite(SocksX[0],SocksY[0],"socks"); Socks.anchor.setTo(0.5,0.5); Socks.frame = 0; Socks.tint = Colors[0]; Socks.visible = false; Socks_Outline = this.add.sprite(Socks.x,Socks.y,"socks_outline"); Socks_Outline.anchor.setTo(0.5,0.5); Socks_Outline.frame = Socks.frame; Socks_Outline.visible = false; BottomsX = [272]; BottomsY = [467]; Bottoms = this.add.sprite(BottomsX[0],BottomsY[0],"bottoms"); Bottoms.anchor.setTo(0.5,0.5); Bottoms.tint = Colors[1]; Bottoms.frame = 0; Bottoms_Outline = this.add.sprite(Bottoms.x,Bottoms.y,"bottoms_outline"); Bottoms_Outline.anchor.setTo(0.5,0.5); Bottoms_Outline.frame = Bottoms.frame; TopsX = [257]; TopsY = [424]; DressX = [272]; DressY = [383]; Clothes = this.add.sprite(TopsX[0],TopsY[0],"tops"); Clothes.anchor.setTo(0.5,0.5); Clothes.name = "Tops"; Clothes.tint = Colors[4]; Clothes.frame = 0; Clothes_Outline = this.add.sprite(Clothes.x,Clothes.y,"tops_outline"); Clothes_Outline.anchor.setTo(0.5,0.5); Clothes_Outline.name = "Tops"; Clothes_Outline.frame = Clothes.frame; Eye_Shadow = this.add.sprite(278,176,"eye_shadow"); Eye_Shadow.anchor.setTo(0.5,0.5); Eye_Shadow.tint = Colors[0]; Eye_Shadow.visible = false; Eyes_White = this.add.sprite(278,185,"eyes_white"); Eyes_White.anchor.setTo(0.5,0.5); EyebrowX = [280,279,279]; EyebrowY = [162,161,161]; Eyebrows = this.add.button(EyebrowX[0],EyebrowY[0],"eyebrows"); Eyebrows.anchor.setTo(0.5,0.5); Eyebrows.frame = 0; Eyes = this.add.sprite(281.5,188.9,"eyes"); Eyes.anchor.setTo(0.5,0.5); Eyes.tint = Colors[0]; Face_Details = this.add.sprite(270,206,"face_details"); Face_Details.anchor.setTo(0.5,0.5); LipsX = [273]; LipsY = [239]; Lips = this.add.sprite(LipsX[0],LipsY[0],"lips"); Lips.anchor.setTo(0.5,0.5); Lips.frame = 0; /*Lips_Outline = this.add.sprite(Lips.x,Lips.y,"lips_outline"); Lips_Outline.anchor.setTo(0.5,0.5); Lips_Outline.frame = Lips.frame;*/ /*TeethX3 = 467; TeethY3 = 194; TeethX4 = 460; TeethY4 = 188; TeethX5 = 473; TeethY5 = 194; Teeth = this.add.sprite(TeethX3,TeethY3,"teeth"); Teeth.anchor.setTo(0.5,0.5); Teeth.frame = 0; Teeth.visible = false;*/ HairX = [248,250,250,250,249,250]; HairY = [306,201,201,207,199.2,201]; Hair = this.add.sprite(HairX[0],HairY[0],"hair"); Hair.anchor.setTo(0.5,0.5); Hair.frame = 0; Hair.tint = Colors2[24]; Hair_Outline = this.add.sprite(Hair.x,Hair.y,"hair_outline"); Hair_Outline.anchor.setTo(0.5,0.5); Hair_Outline.frame = Hair.frame; Hair_HlX = [250,250,250,250,249,250]; Hair_HlY = [195,195,195,200,194,195]; Hair_Hl = this.add.button(Hair.x,Hair.y,"hair_hl"); Hair_Hl.anchor.setTo(0.5,0.5); Hair_Hl.frame = Hair.frame; Hair_Hl.visible = false; /*BangsX = [247]; BangsY = [162]; Bangs = this.add.sprite(BangsX[0],BangsY[0],"bangs"); Bangs.anchor.setTo(0.5,0.5); Bangs.frame = 4; Bangs.tint = Colors[10]; Bangs.visible = false;// Bangs_Outline = this.add.sprite(Bangs.x,Bangs.y + 1,"bangs_outline"); Bangs_Outline.anchor.setTo(0.5,0.5); Bangs_Outline.frame = Bangs.frame; Bangs_Outline.visible = false;// Bang_HlX = [247]; Bang_HlY = [162]; Bang_Hl = this.add.sprite(Bang_HlX[0],Bang_HlY[0],"bang_hl"); Bang_Hl.anchor.setTo(0.5,0.5); Bang_Hl.frame = Bangs.frame; Bang_Hl.visible = false;*/ Extra = this.add.sprite(271,194,"extras"); Extra.anchor.setTo(0.5,0.5); Extra.tint = Colors[0]; Extra.visible = false; Extra_Outline = this.add.sprite(271,194,"extras_outline"); Extra_Outline.anchor.setTo(0.5,0.5); Extra_Outline.visible = false; Extra2 = this.add.sprite(244,376,"extras2"); Extra2.anchor.setTo(0.5,0.5); Extra2.tint = Colors[21]; Extra2.visible = false; Extra2_Outline = this.add.sprite(244,376,"extras2_outline"); Extra2_Outline.anchor.setTo(0.5,0.5); Extra2_Outline.visible = false; Extra3 = this.add.sprite(249,527,"extras3"); Extra3.anchor.setTo(0.5,0.5); Extra3.tint = Colors[1]; Extra3.visible = false; Extra3_Outline = this.add.sprite(283,516,"extras3_outline"); Extra3_Outline.anchor.setTo(0.5,0.5); Extra3_Outline.visible = false; Extra4 = this.add.sprite(326.5,168,"extras4"); Extra4.anchor.setTo(0.5,0.5); Extra4.tint = Colors[1]; Extra4.visible = false; Extra4_Outline = this.add.sprite(326,168,"extras4_outline"); Extra4_Outline.anchor.setTo(0.5,0.5); Extra4_Outline.visible = false; Extra5 = this.add.sprite(264,275,"extras5"); Extra5.anchor.setTo(0.5,0.5); Extra5.tint = Colors[1]; Extra5.visible = false; Extra5_Outline = this.add.sprite(272,275,"extras5_outline"); Extra5_Outline.anchor.setTo(0.5,0.5); Extra5_Outline.visible = false; Extra6 = this.add.sprite(274,140,"extras6"); Extra6.anchor.setTo(0.5,0.5); Extra6.tint = Colors[1]; Extra6.visible = false; Extra6_Outline = this.add.sprite(Extra6.x,Extra6.y,"extras6_outline"); Extra6_Outline.anchor.setTo(0.5,0.5); Extra6_Outline.visible = false; ShoesX = [268.3]; ShoesY = [526]; Shoes = this.add.sprite(ShoesX[0],ShoesY[0],"shoes"); Shoes.anchor.setTo(0.5,0.5); Shoes.frame = 0; Shoes.tint = Colors[4]; Shoes_Outline = this.add.sprite(ShoesX[0],ShoesY[0],"shoes_outline"); Shoes_Outline.anchor.setTo(0.5,0.5); Shoes_Outline.frame = Shoes.frame; Shadow = this.add.sprite(260,581,"shadow"); Shadow.anchor.setTo(0.5,0.5); /*CakeX = [386,386,372,373,385,390]; CakeY = [217,232,234,235,226,191]; Cake = this.add.sprite(CakeX[0],CakeY[0],"cake"); Cake.anchor.setTo(0.5,0.5); Cake.frame = 0; Cake.tint = Colors[11]; Cake.visible = false;// Cake_Outline = this.add.sprite(Cake.x,Cake.y,"cake_outline"); Cake_Outline.anchor.setTo(0.5,0.5); Cake_Outline.frame = Cake.frame; Cake_Outline.visible = false;//*/ Doll_Group = this.add.group(); this.SortMainGroup_fnc(); //Doll_Group.setAll("smoothed",false); //Doll_Group.scale.setTo(0.5,0.5); Doll_Group.x = 0; Doll_Group.y = 1; /*debug_fnc(Shadow); Head.visible = false; Head_Outline.visible = false; Body.visible = false; Body_Outline.visible = false;*/ //dressup Border = this.add.sprite(713,283,"border"); Border.anchor.setTo(0.5,0.5); //Hair_Menu /*Bang01_Icon = this.add.button(Border.x + 1,130,"bang_icon",function() { //this.Bang_fnc("bangs","Bang01",BangsX,BangsY); Bangs.frame = 0; Bangs.x = BangsX[0]; Bangs.y = BangsY[0]; Bangs_Outline.frame = Bangs.frame; Bangs_Outline.x = Bangs.x; Bangs_Outline.y = Bangs.y + 1; Bang_Hl.frame = Bangs.frame; this.checkBangsColor(); },this,1,0,0); Bang01_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Bang01_Icon); this.buttonDown_fnc(Bang01_Icon);}; Bang02_Icon = this.add.button(Border.x + 1,Bang01_Icon.y + Bang01_Icon.height + 10,"bang_icon2",function() { //this.Bang_fnc("bangs2","Bang02",BangsX2,BangsY2); Bangs.frame = 1; Bangs.x = BangsX[0]; Bangs.y = BangsY[0]; Bangs_Outline.frame = Bangs.frame; Bangs_Outline.x = Bangs.x; Bangs_Outline.y = Bangs.y + 1; Bang_Hl.frame = Bangs.frame; this.checkBangsColor(); },this,1,0,0); Bang02_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Bang02_Icon); this.buttonDown_fnc(Bang02_Icon);}; Bang03_Icon = this.add.button(Border.x + 1,Bang02_Icon.y + Bang02_Icon.height + 10,"bang_icon3",function() { //this.Bang_fnc("bangs3","Bang03",BangsX3,BangsY3); Bangs.frame = 2; Bangs.x = BangsX[0]; Bangs.y = BangsY[0]; Bangs_Outline.frame = Bangs.frame; Bangs_Outline.x = Bangs.x; Bangs_Outline.y = Bangs.y + 1; Bang_Hl.frame = Bangs.frame; this.checkBangsColor(); },this,1,0,0); Bang03_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Bang03_Icon); this.buttonDown_fnc(Bang03_Icon);}; Bang04_Icon = this.add.button(Border.x + 1,Bang01_Icon.y,"bang_icon4",function() { //this.Bang_fnc("bangs4","Bang04",BangsX4,BangsY4); Bangs.frame = 3; Bangs.x = BangsX[0]; Bangs.y = BangsY[0]; Bangs_Outline.frame = Bangs.frame; Bangs_Outline.x = Bangs.x; Bangs_Outline.y = Bangs.y + 1; Bang_Hl.frame = Bangs.frame; this.checkBangsColor(); },this,1,0,0); Bang04_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Bang04_Icon); this.buttonDown_fnc(Bang04_Icon);}; Bang04_Icon.visible = false; Bang05_Icon = this.add.button(Border.x + 1,Bang04_Icon.y + Bang04_Icon.height + 10,"bang_icon5",function() { //this.Bang_fnc("bangs5","Bang05",BangsX5,BangsY5); Bangs.frame = 4; Bangs.x = BangsX[0]; Bangs.y = BangsY[0]; Bangs_Outline.frame = Bangs.frame; Bangs_Outline.x = Bangs.x; Bangs_Outline.y = Bangs.y + 1; Bang_Hl.frame = Bangs.frame; this.checkBangsColor(); },this,1,0,0); Bang05_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Bang05_Icon); this.buttonDown_fnc(Bang05_Icon);}; Bang05_Icon.visible = false; Bang06_Icon = this.add.button(Border.x + 1,Bang05_Icon.y + Bang05_Icon.height + 9.2,"bang_icon6",function() { //this.Bang_fnc("bangs6","Bang06",BangsX6,BangsY6); Bangs.frame = 5; Bangs.x = BangsX[0]; Bangs.y = BangsY[0]; Bangs_Outline.frame = Bangs.frame; Bangs_Outline.x = Bangs.x; Bangs_Outline.y = Bangs.y + 1; Bang_Hl.frame = Bangs.frame; this.checkBangsColor(); },this,1,0,0); Bang06_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Bang06_Icon); this.buttonDown_fnc(Bang06_Icon);}; Bang06_Icon.visible = false;*/ Hair01_Icon = this.add.button(Border.x + 1,130,"hair01_icon",function() { //this.Hair_fnc("hair","Hair01",HairX,HairY); Hair.frame = 0; /*Hair.x = HairX[0]; Hair.y = HairY[0];*/ Hair_Outline.frame = Hair.frame; /*Hair_Outline.x = Hair.x; Hair_Outline.y = Hair.y;*/ Hair_Hl.frame = Hair.frame; /*Hair_Hl.x = Hair_HlX[Hair.frame]; Hair_Hl.y = Hair_HlY[Hair.frame];*/ this.checkHairColor(); },this,1,0,0); Hair01_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Hair01_Icon); this.buttonDown_fnc(Hair01_Icon);}; //Hair01_Icon.visible = false; Hair02_Icon = this.add.button(Border.x + 1,Hair01_Icon.y + Hair01_Icon.height + 10,"hair02_icon",function() { //this.Hair_fnc("hair2","Hair02",HairX2,HairY2); Hair.frame = 1; /*Hair.x = HairX[1]; Hair.y = HairY[1];*/ Hair_Outline.frame = Hair.frame; /*Hair_Outline.x = Hair.x; Hair_Outline.y = Hair.y;*/ Hair_Hl.frame = Hair.frame; /*Hair_Hl.x = Hair_HlX[Hair.frame]; Hair_Hl.y = Hair_HlY[Hair.frame];*/ this.checkHairColor(); },this,1,0,0); Hair02_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Hair02_Icon); this.buttonDown_fnc(Hair02_Icon);}; //Hair02_Icon.visible = false; Hair03_Icon = this.add.button(Border.x + 1,Hair02_Icon.y + Hair02_Icon.height + 10,"hair03_icon",function() { //this.Hair_fnc("hair3","Hair03",HairX3,HairY3); Hair.frame = 2; /*Hair.x = HairX[2]; Hair.y = HairY[2];*/ Hair_Outline.frame = Hair.frame; /*Hair_Outline.x = Hair.x; Hair_Outline.y = Hair.y;*/ Hair_Hl.frame = Hair.frame; /*Hair_Hl.x = Hair_HlX[Hair.frame]; Hair_Hl.y = Hair_HlY[Hair.frame];*/ this.checkHairColor(); },this,1,0,0); Hair03_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Hair03_Icon); this.buttonDown_fnc(Hair03_Icon);}; //Hair03_Icon.visible = false; Hair04_Icon = this.add.button(Border.x + 1,129,"hair04_icon",function() { //this.Hair_fnc("hair4","Hair04",HairX4,HairY4); Hair.frame = 3; /*Hair.x = HairX[3]; Hair.y = HairY[3];*/ Hair_Outline.frame = Hair.frame; /*Hair_Outline.x = Hair.x; Hair_Outline.y = Hair.y;*/ Hair_Hl.frame = Hair.frame; /*Hair_Hl.x = Hair_HlX[Hair.frame]; Hair_Hl.y = Hair_HlY[Hair.frame];*/ this.checkHairColor(); },this,1,0,0); Hair04_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Hair04_Icon); this.buttonDown_fnc(Hair04_Icon);}; Hair04_Icon.visible = false; Hair05_Icon = this.add.button(Border.x + 1,Hair04_Icon.y + Hair04_Icon.height + 10,"hair05_icon",function() { //this.Hair_fnc("hair5","Hair05",HairX5,HairY5); Hair.frame = 4; /*Hair.x = HairX[4]; Hair.y = HairY[4];*/ Hair_Outline.frame = Hair.frame; /*Hair_Outline.x = Hair.x; Hair_Outline.y = Hair.y;*/ Hair_Hl.frame = Hair.frame; /*Hair_Hl.x = Hair_HlX[Hair.frame]; Hair_Hl.y = Hair_HlY[Hair.frame];*/ this.checkHairColor(); },this,1,0,0); Hair05_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Hair05_Icon); this.buttonDown_fnc(Hair05_Icon);}; Hair05_Icon.visible = false; Hair06_Icon = this.add.button(Border.x + 1.7,Hair05_Icon.y + Hair05_Icon.height + 8.7,"hair06_icon",function() { //this.Hair_fnc("hair6","Hair06",HairX6,HairY6); Hair.frame = 5; /*Hair.x = HairX[5]; Hair.y = HairY[5];*/ Hair_Outline.frame = Hair.frame; /*Hair_Outline.x = Hair.x; Hair_Outline.y = Hair.y;*/ Hair_Hl.frame = Hair.frame; /*Hair_Hl.x = Hair_HlX[Hair.frame]; Hair_Hl.y = Hair_HlY[Hair.frame];*/ this.checkHairColor(); },this,1,0,0); Hair06_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Hair06_Icon); this.buttonDown_fnc(Hair06_Icon);}; Hair06_Icon.visible = false; Hair_Menu_Group = this.add.group(); /*Hair_Menu_Group.add(Bang01_Icon); Hair_Menu_Group.add(Bang02_Icon); Hair_Menu_Group.add(Bang03_Icon); Hair_Menu_Group.add(Bang04_Icon); Hair_Menu_Group.add(Bang05_Icon); Hair_Menu_Group.add(Bang06_Icon);*/ Hair_Menu_Group.add(Hair01_Icon); Hair_Menu_Group.add(Hair02_Icon); Hair_Menu_Group.add(Hair03_Icon); Hair_Menu_Group.add(Hair04_Icon); Hair_Menu_Group.add(Hair05_Icon); Hair_Menu_Group.add(Hair06_Icon); Hair_Menu_Group.setAll("input.pixelPerfectClick",true); Hair_Menu_Group.setAll("input.pixelPerfectOver",true); //Color_Icon Color_Pallette = this.add.sprite(714,255,"color_pallette"); Color_Pallette.anchor.setTo(0.5,0.5); Color_Pallette2 = this.add.sprite(714,255,"color_pallette2"); Color_Pallette2.anchor.setTo(0.5,0.5); Color_Pallette2.visible = false; Color01_Icon = this.add.button(615,83,"color_icon_btn",function() { this.changeColor(0,40); },this); Color01_Icon.anchor.setTo(0.5,0.5); Color01_Icon.alpha = 0; Color02_Icon = this.add.button(Color01_Icon.x + Color01_Icon.width + 2,Color01_Icon.y,"color_icon_btn",function() { this.changeColor(1,41); },this,1,0,0); Color02_Icon.anchor.setTo(0.5,0.5); Color02_Icon.alpha = 0; Color03_Icon = this.add.button(Color02_Icon.x + Color02_Icon.width + 2,Color02_Icon.y,"color_icon_btn",function() { this.changeColor(2,42); },this,1,0,0); Color03_Icon.anchor.setTo(0.5,0.5); Color03_Icon.alpha = 0; Color04_Icon = this.add.button(Color03_Icon.x + Color03_Icon.width + 5,Color03_Icon.y,"color_icon_btn",function() { this.changeColor(3,43); },this,1,0,0); Color04_Icon.anchor.setTo(0.5,0.5); Color04_Icon.alpha = 0; Color05_Icon = this.add.button(Color04_Icon.x + Color04_Icon.width + 3,Color04_Icon.y + 2,"color_icon_btn",function() { this.changeColor(4,44); },this,1,0,0); Color05_Icon.anchor.setTo(0.5,0.5); Color05_Icon.alpha = 0; Color06_Icon = this.add.button(Color01_Icon.x,Color01_Icon.y + Color01_Icon.height + 2,"color_icon_btn",function() { this.changeColor(5,45); },this,1,0,0); Color06_Icon.anchor.setTo(0.5,0.5); Color06_Icon.alpha = 0; Color07_Icon = this.add.button(Color02_Icon.x,Color02_Icon.y + Color02_Icon.height + 2,"color_icon_btn",function() { this.changeColor(6,46); },this,1,0,0); Color07_Icon.anchor.setTo(0.5,0.5); Color07_Icon.alpha = 0; Color08_Icon = this.add.button(Color03_Icon.x + 2,Color03_Icon.y + Color03_Icon.height + 2,"color_icon_btn",function() { this.changeColor(7,47); },this,1,0,0); Color08_Icon.anchor.setTo(0.5,0.5); Color08_Icon.alpha = 0; Color09_Icon = this.add.button(Color04_Icon.x,Color04_Icon.y + Color04_Icon.height + 2,"color_icon_btn",function() { this.changeColor(8,48); },this,1,0,0); Color09_Icon.anchor.setTo(0.5,0.5); Color09_Icon.alpha = 0; Color10_Icon = this.add.button(Color05_Icon.x,Color05_Icon.y + Color05_Icon.height + 1,"color_icon_btn",function() { this.changeColor(9,49); },this,1,0,0); Color10_Icon.anchor.setTo(0.5,0.5); Color10_Icon.alpha = 0; Color11_Icon = this.add.button(Color06_Icon.x,Color06_Icon.y + Color06_Icon.height + 2,"color_icon_btn",function() { this.changeColor(10,50); },this,1,0,0); Color11_Icon.anchor.setTo(0.5,0.5); Color11_Icon.alpha = 0; Color12_Icon = this.add.button(Color07_Icon.x,Color07_Icon.y + Color07_Icon.height + 2,"color_icon_btn",function() { this.changeColor(11,51); },this); Color12_Icon.anchor.setTo(0.5,0.5); Color12_Icon.alpha = 0; Color13_Icon = this.add.button(Color08_Icon.x,Color08_Icon.y + Color08_Icon.height + 2,"color_icon_btn",function() { this.changeColor(12,52); },this); Color13_Icon.anchor.setTo(0.5,0.5); Color13_Icon.alpha = 0; Color14_Icon = this.add.button(Color09_Icon.x,Color09_Icon.y + Color09_Icon.height + 2,"color_icon_btn",function() { this.changeColor(13,53); },this); Color14_Icon.anchor.setTo(0.5,0.5); Color14_Icon.alpha = 0; Color15_Icon = this.add.button(Color10_Icon.x,Color10_Icon.y + Color10_Icon.height + 1,"color_icon_btn",function() { this.changeColor(14,54); },this); Color15_Icon.anchor.setTo(0.5,0.5); Color15_Icon.alpha = 0; Color16_Icon = this.add.button(Color11_Icon.x,Color11_Icon.y + Color11_Icon.height + 2,"color_icon_btn",function() { this.changeColor(15,55); },this); Color16_Icon.anchor.setTo(0.5,0.5); Color16_Icon.alpha = 0; Color17_Icon = this.add.button(Color12_Icon.x,Color12_Icon.y + Color12_Icon.height + 2,"color_icon_btn",function() { this.changeColor(16,56); },this); Color17_Icon.anchor.setTo(0.5,0.5); Color17_Icon.alpha = 0; Color18_Icon = this.add.button(Color13_Icon.x,Color13_Icon.y + Color13_Icon.height + 1,"color_icon_btn",function() { this.changeColor(17,57); },this); Color18_Icon.anchor.setTo(0.5,0.5); Color18_Icon.alpha = 0; Color19_Icon = this.add.button(Color14_Icon.x,Color14_Icon.y + Color14_Icon.height + 1,"color_icon_btn",function() { this.changeColor(18,58); },this); Color19_Icon.anchor.setTo(0.5,0.5); Color19_Icon.alpha = 0; Color20_Icon = this.add.button(Color15_Icon.x,Color15_Icon.y + Color15_Icon.height + 1,"color_icon_btn",function() { this.changeColor(19,59); },this); Color20_Icon.anchor.setTo(0.5,0.5); Color20_Icon.alpha = 0; Color21_Icon = this.add.button(Color16_Icon.x,Color16_Icon.y + Color16_Icon.height + 2,"color_icon_btn",function() { this.changeColor(20,60); },this); Color21_Icon.anchor.setTo(0.5,0.5); Color21_Icon.alpha = 0; Color22_Icon = this.add.button(Color17_Icon.x,Color17_Icon.y + Color17_Icon.height + 2,"color_icon_btn",function() { this.changeColor(21,61); },this); Color22_Icon.anchor.setTo(0.5,0.5); Color22_Icon.alpha = 0; Color23_Icon = this.add.button(Color18_Icon.x,Color18_Icon.y + Color18_Icon.height + 2,"color_icon_btn",function() { this.changeColor(22,62); },this); Color23_Icon.anchor.setTo(0.5,0.5); Color23_Icon.alpha = 0; Color24_Icon = this.add.button(Color19_Icon.x,Color19_Icon.y + Color19_Icon.height + 2,"color_icon_btn",function() { this.changeColor(23,63); },this); Color24_Icon.anchor.setTo(0.5,0.5); Color24_Icon.alpha = 0; Color25_Icon = this.add.button(Color20_Icon.x,Color20_Icon.y + Color20_Icon.height + 1,"color_icon_btn",function() { this.changeColor(24,64); },this); Color25_Icon.anchor.setTo(0.5,0.5); Color25_Icon.alpha = 0; Color26_Icon = this.add.button(Color21_Icon.x,Color21_Icon.y + Color21_Icon.height + 1,"color_icon_btn",function() { this.changeColor(25,65); },this); Color26_Icon.anchor.setTo(0.5,0.5); Color26_Icon.alpha = 0; Color27_Icon = this.add.button(Color22_Icon.x,Color22_Icon.y + Color22_Icon.height + 1,"color_icon_btn",function() { this.changeColor(26,66); },this); Color27_Icon.anchor.setTo(0.5,0.5); Color27_Icon.alpha = 0; Color28_Icon = this.add.button(Color23_Icon.x,Color23_Icon.y + Color23_Icon.height + 1,"color_icon_btn",function() { this.changeColor(27,67); },this); Color28_Icon.anchor.setTo(0.5,0.5); Color28_Icon.alpha = 0; Color29_Icon = this.add.button(Color24_Icon.x,Color24_Icon.y + Color24_Icon.height + 1,"color_icon_btn",function() { this.changeColor(28,68); },this); Color29_Icon.anchor.setTo(0.5,0.5); Color29_Icon.alpha = 0; Color30_Icon = this.add.button(Color25_Icon.x,Color25_Icon.y + Color25_Icon.height + 1,"color_icon_btn",function() { this.changeColor(29,69); },this); Color30_Icon.anchor.setTo(0.5,0.5); Color30_Icon.alpha = 0; Color31_Icon = this.add.button(Color26_Icon.x,Color26_Icon.y + Color26_Icon.height + 1,"color_icon_btn",function() { this.changeColor(30,70); },this); Color31_Icon.anchor.setTo(0.5,0.5); Color31_Icon.alpha = 0; Color32_Icon = this.add.button(Color27_Icon.x,Color27_Icon.y + Color27_Icon.height + 1,"color_icon_btn",function() { this.changeColor(31,71); },this); Color32_Icon.anchor.setTo(0.5,0.5); Color32_Icon.alpha = 0; Color33_Icon = this.add.button(Color28_Icon.x,Color28_Icon.y + Color28_Icon.height + 1,"color_icon_btn",function() { this.changeColor(32,72); },this); Color33_Icon.anchor.setTo(0.5,0.5); Color33_Icon.alpha = 0; Color34_Icon = this.add.button(Color29_Icon.x,Color29_Icon.y + Color29_Icon.height + 1,"color_icon_btn",function() { this.changeColor(33,73); },this); Color34_Icon.anchor.setTo(0.5,0.5); Color34_Icon.alpha = 0; Color35_Icon = this.add.button(Color30_Icon.x,Color30_Icon.y + Color30_Icon.height + 1,"color_icon_btn",function() { this.changeColor(34,74); },this); Color35_Icon.anchor.setTo(0.5,0.5); Color35_Icon.alpha = 0; Color36_Icon = this.add.button(Color31_Icon.x,Color31_Icon.y + Color31_Icon.height + 1,"color_icon_btn",function() { this.changeColor(35,75); },this); Color36_Icon.anchor.setTo(0.5,0.5); Color36_Icon.alpha = 0; Color37_Icon = this.add.button(Color32_Icon.x,Color32_Icon.y + Color32_Icon.height + 1,"color_icon_btn",function() { this.changeColor(36,76); },this); Color37_Icon.anchor.setTo(0.5,0.5); Color37_Icon.alpha = 0; Color38_Icon = this.add.button(Color33_Icon.x,Color33_Icon.y + Color33_Icon.height + 1,"color_icon_btn",function() { this.changeColor(37,77); },this); Color38_Icon.anchor.setTo(0.5,0.5); Color38_Icon.alpha = 0; Color39_Icon = this.add.button(Color34_Icon.x,Color34_Icon.y + Color34_Icon.height + 1,"color_icon_btn",function() { this.changeColor(38,78); },this); Color39_Icon.anchor.setTo(0.5,0.5); Color39_Icon.alpha = 0; Color40_Icon = this.add.button(Color35_Icon.x,Color35_Icon.y + Color35_Icon.height + 1,"color_icon_btn",function() { this.changeColor(39,79); },this); Color40_Icon.anchor.setTo(0.5,0.5); Color40_Icon.alpha = 0; //Eyebrows_Icon Eyebrows_Icon = this.add.button(Border.x - 2.3, 132.5, "eyebrows_icon",function() { Eyebrows.frame = 0; /*Eyebrows.x = EyebrowX[0]; Eyebrows.y = EyebrowY[0];*/ },this,1,0,0); Eyebrows_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Eyebrows_Icon); this.buttonDown_fnc(Eyebrows_Icon);}; Eyebrows_Icon2 = this.add.button(Border.x - 2.3, Eyebrows_Icon.y + Eyebrows_Icon.height + 10, "eyebrows_icon2",function() { Eyebrows.frame = 1; /*Eyebrows.x = EyebrowX[1]; Eyebrows.y = EyebrowY[1];*/ },this,1,0,0); Eyebrows_Icon2.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Eyebrows_Icon2); this.buttonDown_fnc(Eyebrows_Icon2);}; Eyebrows_Icon3 = this.add.button(Border.x - 2.3, Eyebrows_Icon2.y + Eyebrows_Icon2.height + 10, "eyebrows_icon3",function() { Eyebrows.frame = 2; /*Eyebrows.x = EyebrowX[2]; Eyebrows.y = EyebrowY[2];*/ },this,1,0,0); Eyebrows_Icon3.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Eyebrows_Icon3); this.buttonDown_fnc(Eyebrows_Icon3);}; Eyebrows_Menu_Group = this.add.group(); Eyebrows_Menu_Group.add(Eyebrows_Icon); Eyebrows_Menu_Group.add(Eyebrows_Icon2); Eyebrows_Menu_Group.add(Eyebrows_Icon3); Eyebrows_Menu_Group.visible = false; //Eyes_Icon Eyes_Icon = this.add.button(Border.x - 1, 131, "eyes_icon",function() { Eyes.frame = 0; Eyes_White.frame = Eyes.frame; Eye_Shadow.frame = Eyes.frame; /*Eyes.x = EyebrowX[0]; Eyes.y = EyebrowY[0];*/ },this,1,0,0); Eyes_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Eyes_Icon); this.buttonDown_fnc(Eyes_Icon);}; Eyes_Icon2 = this.add.button(Border.x - 1, Eyes_Icon.y + Eyes_Icon.height + 10, "eyes_icon2",function() { Eyes.frame = 1; Eyes_White.frame = Eyes.frame; Eye_Shadow.frame = Eyes.frame; /*Eyes.x = EyebrowX[1]; Eyes.y = EyebrowY[1];*/ },this,1,0,0); Eyes_Icon2.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Eyes_Icon2); this.buttonDown_fnc(Eyes_Icon2);}; Eyes_Icon3 = this.add.button(Border.x - 1, Eyes_Icon2.y + Eyes_Icon2.height + 10, "eyes_icon3",function() { Eyes.frame = 2; Eyes_White.frame = Eyes.frame; Eye_Shadow.frame = Eyes.frame; /*Eyes.x = EyebrowX[2]; Eyes.y = EyebrowY[2];*/ },this,1,0,0); Eyes_Icon3.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Eyes_Icon3); this.buttonDown_fnc(Eyes_Icon3);}; Eyes_Menu_Group = this.add.group(); Eyes_Menu_Group.add(Eyes_Icon); Eyes_Menu_Group.add(Eyes_Icon2); Eyes_Menu_Group.add(Eyes_Icon3); Eyes_Menu_Group.visible = false; //Lips_Icon Lips01_Icon = this.add.button(Border.x + 1,130,"lips01_icon",function() { Lips.frame = 0; /*Lips.x = LipsX[0]; Lips.y = LipsY[0];*/ /*Lips_Outline.frame = Lips.frame; Lips_Outline.x = Lips.x; Lips_Outline.y = Lips.y;*/ },this,1,0,0); Lips01_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Lips01_Icon); this.buttonDown_fnc(Lips01_Icon);}; Lips02_Icon = this.add.button(Border.x + 1,Lips01_Icon.y + Lips01_Icon.height + 10,"lips02_icon",function() { Lips.frame = 1; /*Lips.x = LipsX[0]; Lips.y = LipsY[0];*/ /*Lips_Outline.frame = Lips.frame; Lips_Outline.x = Lips.x; Lips_Outline.y = Lips.y;*/ },this,1,0,0); Lips02_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Lips02_Icon); this.buttonDown_fnc(Lips02_Icon);}; Lips03_Icon = this.add.button(Border.x + 1,Lips02_Icon.y + Lips02_Icon.height + 10,"lips03_icon",function() { Lips.frame = 2; /*Lips.x = LipsX[0]; Lips.y = LipsY[0];*/ /*Lips_Outline.frame = Lips.frame; Lips_Outline.x = Lips.x; Lips_Outline.y = Lips.y;*/ },this,1,0,0); Lips03_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Lips03_Icon); this.buttonDown_fnc(Lips03_Icon);}; Lips04_Icon = this.add.button(Border.x + 1,130,"lips04_icon",function() { Lips.frame = 3; /*Lips.x = LipsX[0]; Lips.y = LipsY[0];*/ /*Lips_Outline.frame = Lips.frame; Lips_Outline.x = Lips.x; Lips_Outline.y = Lips.y;*/ },this,1,0,0); Lips04_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Lips04_Icon); this.buttonDown_fnc(Lips04_Icon);}; Lips04_Icon.visible = false; Lips05_Icon = this.add.button(Border.x + 1,Lips04_Icon.y + Lips04_Icon.height + 11,"lips05_icon",function() { Lips.frame = 4; /*Lips.x = LipsX[0]; Lips.y = LipsY[0];*/ /*Lips_Outline.frame = Lips.frame; Lips_Outline.x = Lips.x; Lips_Outline.y = Lips.y;*/ },this,1,0,0); Lips05_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Lips05_Icon); this.buttonDown_fnc(Lips05_Icon);}; Lips05_Icon.visible = false; Lips06_Icon = this.add.button(Border.x + 1,Lips05_Icon.y + Lips05_Icon.height + 11.5,"lips06_icon",function() { Lips.frame = 5; /*Lips.x = LipsX[0]; Lips.y = LipsY[0];*/ /*Lips_Outline.frame = Lips.frame; Lips_Outline.x = Lips.x; Lips_Outline.y = Lips.y;*/ },this,1,0,0); Lips06_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Lips06_Icon); this.buttonDown_fnc(Lips06_Icon);}; Lips06_Icon.visible = false; Lips_Menu_Group = this.add.group(); Lips_Menu_Group.add(Lips01_Icon); Lips_Menu_Group.add(Lips02_Icon); Lips_Menu_Group.add(Lips03_Icon); Lips_Menu_Group.add(Lips04_Icon); Lips_Menu_Group.add(Lips05_Icon); Lips_Menu_Group.add(Lips06_Icon); Lips_Menu_Group.setAll("input.pixelPerfectClick",true); Lips_Menu_Group.setAll("input.pixelPerfectOver",true); Lips_Menu_Group.visible = false; //SkinColor_Icon SkinColor_Pallette = this.add.sprite(714,255,"skincolor01_icon"); SkinColor_Pallette.anchor.setTo(0.5,0.5); SkinColor_Pallette2 = this.add.sprite(714,255,"skincolor02_icon"); SkinColor_Pallette2.anchor.setTo(0.5,0.5); SkinColor_Pallette2.visible = false; SkinColor01_Icon = this.add.button(615,83,"color_icon_btn",function() { this.SkinColor_fnc(0); },this); SkinColor01_Icon.anchor.setTo(0.5,0.5); SkinColor01_Icon.alpha = 0; SkinColor02_Icon = this.add.button(SkinColor01_Icon.x + SkinColor01_Icon.width + 2,SkinColor01_Icon.y,"color_icon_btn",function() { this.SkinColor_fnc(1); },this,1,0,0); SkinColor02_Icon.anchor.setTo(0.5,0.5); SkinColor02_Icon.alpha = 0; SkinColor03_Icon = this.add.button(SkinColor02_Icon.x + SkinColor02_Icon.width + 2,SkinColor02_Icon.y,"color_icon_btn",function() { this.SkinColor_fnc(2); },this,1,0,0); SkinColor03_Icon.anchor.setTo(0.5,0.5); SkinColor03_Icon.alpha = 0; SkinColor04_Icon = this.add.button(SkinColor03_Icon.x + SkinColor03_Icon.width + 5,SkinColor03_Icon.y,"color_icon_btn",function() { this.SkinColor_fnc(3); },this,1,0,0); SkinColor04_Icon.anchor.setTo(0.5,0.5); SkinColor04_Icon.alpha = 0; SkinColor05_Icon = this.add.button(SkinColor04_Icon.x + SkinColor04_Icon.width + 3,SkinColor04_Icon.y + 2,"color_icon_btn",function() { this.SkinColor_fnc(4); },this,1,0,0); SkinColor05_Icon.anchor.setTo(0.5,0.5); SkinColor05_Icon.alpha = 0; SkinColor06_Icon = this.add.button(SkinColor01_Icon.x,SkinColor01_Icon.y + SkinColor01_Icon.height + 2,"color_icon_btn",function() { this.SkinColor_fnc(5); },this,1,0,0); SkinColor06_Icon.anchor.setTo(0.5,0.5); SkinColor06_Icon.alpha = 0; SkinColor07_Icon = this.add.button(SkinColor02_Icon.x,SkinColor02_Icon.y + SkinColor02_Icon.height + 2,"color_icon_btn",function() { this.SkinColor_fnc(6); },this,1,0,0); SkinColor07_Icon.anchor.setTo(0.5,0.5); SkinColor07_Icon.alpha = 0; SkinColor08_Icon = this.add.button(SkinColor03_Icon.x + 2,SkinColor03_Icon.y + SkinColor03_Icon.height + 2,"color_icon_btn",function() { this.SkinColor_fnc(7); },this,1,0,0); SkinColor08_Icon.anchor.setTo(0.5,0.5); SkinColor08_Icon.alpha = 0; SkinColor09_Icon = this.add.button(SkinColor04_Icon.x,SkinColor04_Icon.y + SkinColor04_Icon.height + 2,"color_icon_btn",function() { this.SkinColor_fnc(8); },this,1,0,0); SkinColor09_Icon.anchor.setTo(0.5,0.5); SkinColor09_Icon.alpha = 0; SkinColor10_Icon = this.add.button(SkinColor05_Icon.x,SkinColor05_Icon.y + SkinColor05_Icon.height + 1,"color_icon_btn",function() { this.SkinColor_fnc(9); },this,1,0,0); SkinColor10_Icon.anchor.setTo(0.5,0.5); SkinColor10_Icon.alpha = 0; SkinColor11_Icon = this.add.button(SkinColor06_Icon.x,SkinColor06_Icon.y + SkinColor06_Icon.height + 2,"color_icon_btn",function() { this.SkinColor_fnc(10); },this,1,0,0); SkinColor11_Icon.anchor.setTo(0.5,0.5); SkinColor11_Icon.alpha = 0; SkinColor12_Icon = this.add.button(SkinColor07_Icon.x,SkinColor07_Icon.y + SkinColor07_Icon.height + 2,"color_icon_btn",function() { this.SkinColor_fnc(11); },this); SkinColor12_Icon.anchor.setTo(0.5,0.5); SkinColor12_Icon.alpha = 0; SkinColor13_Icon = this.add.button(SkinColor08_Icon.x,SkinColor08_Icon.y + SkinColor08_Icon.height + 2,"color_icon_btn",function() { this.SkinColor_fnc(12); },this); SkinColor13_Icon.anchor.setTo(0.5,0.5); SkinColor13_Icon.alpha = 0; SkinColor14_Icon = this.add.button(SkinColor09_Icon.x,SkinColor09_Icon.y + SkinColor09_Icon.height + 2,"color_icon_btn",function() { this.SkinColor_fnc(13); },this); SkinColor14_Icon.anchor.setTo(0.5,0.5); SkinColor14_Icon.alpha = 0; SkinColor15_Icon = this.add.button(SkinColor10_Icon.x,SkinColor10_Icon.y + SkinColor10_Icon.height + 1,"color_icon_btn",function() { this.SkinColor_fnc(14); },this); SkinColor15_Icon.anchor.setTo(0.5,0.5); SkinColor15_Icon.alpha = 0; SkinColor16_Icon = this.add.button(SkinColor11_Icon.x,SkinColor11_Icon.y + SkinColor11_Icon.height + 2,"color_icon_btn",function() { this.SkinColor_fnc(15); },this); SkinColor16_Icon.anchor.setTo(0.5,0.5); SkinColor16_Icon.alpha = 0; SkinColor17_Icon = this.add.button(SkinColor12_Icon.x,SkinColor12_Icon.y + SkinColor12_Icon.height + 2,"color_icon_btn",function() { this.SkinColor_fnc(16); },this); SkinColor17_Icon.anchor.setTo(0.5,0.5); SkinColor17_Icon.alpha = 0; SkinColor18_Icon = this.add.button(SkinColor13_Icon.x,SkinColor13_Icon.y + SkinColor13_Icon.height + 1,"color_icon_btn",function() { this.SkinColor_fnc(17); },this); SkinColor18_Icon.anchor.setTo(0.5,0.5); SkinColor18_Icon.alpha = 0; SkinColor19_Icon = this.add.button(SkinColor14_Icon.x,SkinColor14_Icon.y + SkinColor14_Icon.height + 1,"color_icon_btn",function() { this.SkinColor_fnc(18); },this); SkinColor19_Icon.anchor.setTo(0.5,0.5); SkinColor19_Icon.alpha = 0; SkinColor20_Icon = this.add.button(SkinColor15_Icon.x,SkinColor15_Icon.y + SkinColor15_Icon.height + 1,"color_icon_btn",function() { this.SkinColor_fnc(19); },this); SkinColor20_Icon.anchor.setTo(0.5,0.5); SkinColor20_Icon.alpha = 0; SkinColor21_Icon = this.add.button(SkinColor16_Icon.x,SkinColor16_Icon.y + SkinColor16_Icon.height + 2,"color_icon_btn",function() { this.SkinColor_fnc(20); },this); SkinColor21_Icon.anchor.setTo(0.5,0.5); SkinColor21_Icon.alpha = 0; SkinColor22_Icon = this.add.button(SkinColor17_Icon.x,SkinColor17_Icon.y + SkinColor17_Icon.height + 2,"color_icon_btn",function() { this.SkinColor_fnc(21); },this); SkinColor22_Icon.anchor.setTo(0.5,0.5); SkinColor22_Icon.alpha = 0; SkinColor23_Icon = this.add.button(SkinColor18_Icon.x,SkinColor18_Icon.y + SkinColor18_Icon.height + 2,"color_icon_btn",function() { this.SkinColor_fnc(22); },this); SkinColor23_Icon.anchor.setTo(0.5,0.5); SkinColor23_Icon.alpha = 0; SkinColor24_Icon = this.add.button(SkinColor19_Icon.x,SkinColor19_Icon.y + SkinColor19_Icon.height + 2,"color_icon_btn",function() { this.SkinColor_fnc(23); },this); SkinColor24_Icon.anchor.setTo(0.5,0.5); SkinColor24_Icon.alpha = 0; SkinColor25_Icon = this.add.button(SkinColor20_Icon.x,SkinColor20_Icon.y + SkinColor20_Icon.height + 1,"color_icon_btn",function() { this.SkinColor_fnc(24); },this); SkinColor25_Icon.anchor.setTo(0.5,0.5); SkinColor25_Icon.alpha = 0; SkinColor26_Icon = this.add.button(SkinColor21_Icon.x,SkinColor21_Icon.y + SkinColor21_Icon.height + 1,"color_icon_btn",function() { this.SkinColor_fnc(25); },this); SkinColor26_Icon.anchor.setTo(0.5,0.5); SkinColor26_Icon.alpha = 0; SkinColor27_Icon = this.add.button(SkinColor22_Icon.x,SkinColor22_Icon.y + SkinColor22_Icon.height + 1,"color_icon_btn",function() { this.SkinColor_fnc(26); },this); SkinColor27_Icon.anchor.setTo(0.5,0.5); SkinColor27_Icon.alpha = 0; SkinColor28_Icon = this.add.button(SkinColor23_Icon.x,SkinColor23_Icon.y + SkinColor23_Icon.height + 1,"color_icon_btn",function() { this.SkinColor_fnc(27); },this); SkinColor28_Icon.anchor.setTo(0.5,0.5); SkinColor28_Icon.alpha = 0; SkinColor29_Icon = this.add.button(SkinColor24_Icon.x,SkinColor24_Icon.y + SkinColor24_Icon.height + 1,"color_icon_btn",function() { this.SkinColor_fnc(28); },this); SkinColor29_Icon.anchor.setTo(0.5,0.5); SkinColor29_Icon.alpha = 0; SkinColor30_Icon = this.add.button(SkinColor25_Icon.x,SkinColor25_Icon.y + SkinColor25_Icon.height + 1,"color_icon_btn",function() { this.SkinColor_fnc(29); },this); SkinColor30_Icon.anchor.setTo(0.5,0.5); SkinColor30_Icon.alpha = 0; SkinColor31_Icon = this.add.button(SkinColor26_Icon.x,SkinColor26_Icon.y + SkinColor26_Icon.height + 1,"color_icon_btn",function() { this.SkinColor_fnc(30); },this); SkinColor31_Icon.anchor.setTo(0.5,0.5); SkinColor31_Icon.alpha = 0; SkinColor32_Icon = this.add.button(SkinColor27_Icon.x,SkinColor27_Icon.y + SkinColor27_Icon.height + 1,"color_icon_btn",function() { this.SkinColor_fnc(31); },this); SkinColor32_Icon.anchor.setTo(0.5,0.5); SkinColor32_Icon.alpha = 0; SkinColor33_Icon = this.add.button(SkinColor28_Icon.x,SkinColor28_Icon.y + SkinColor28_Icon.height + 1,"color_icon_btn",function() { this.SkinColor_fnc(32); },this); SkinColor33_Icon.anchor.setTo(0.5,0.5); SkinColor33_Icon.alpha = 0; SkinColor34_Icon = this.add.button(SkinColor29_Icon.x,SkinColor29_Icon.y + SkinColor29_Icon.height + 1,"color_icon_btn",function() { this.SkinColor_fnc(33); },this); SkinColor34_Icon.anchor.setTo(0.5,0.5); SkinColor34_Icon.alpha = 0; SkinColor35_Icon = this.add.button(SkinColor30_Icon.x,SkinColor30_Icon.y + SkinColor30_Icon.height + 1,"color_icon_btn",function() { this.SkinColor_fnc(34); },this); SkinColor35_Icon.anchor.setTo(0.5,0.5); SkinColor35_Icon.alpha = 0; SkinColor36_Icon = this.add.button(SkinColor31_Icon.x,SkinColor31_Icon.y + SkinColor31_Icon.height + 1,"color_icon_btn",function() { this.SkinColor_fnc(35); },this); SkinColor36_Icon.anchor.setTo(0.5,0.5); SkinColor36_Icon.alpha = 0; SkinColor37_Icon = this.add.button(SkinColor32_Icon.x,SkinColor32_Icon.y + SkinColor32_Icon.height + 1,"color_icon_btn",function() { this.SkinColor_fnc(36); },this); SkinColor37_Icon.anchor.setTo(0.5,0.5); SkinColor37_Icon.alpha = 0; SkinColor38_Icon = this.add.button(SkinColor33_Icon.x,SkinColor33_Icon.y + SkinColor33_Icon.height + 1,"color_icon_btn",function() { this.SkinColor_fnc(37); },this); SkinColor38_Icon.anchor.setTo(0.5,0.5); SkinColor38_Icon.alpha = 0; SkinColor39_Icon = this.add.button(SkinColor34_Icon.x,SkinColor34_Icon.y + SkinColor34_Icon.height + 1,"color_icon_btn",function() { this.SkinColor_fnc(38); },this); SkinColor39_Icon.anchor.setTo(0.5,0.5); SkinColor39_Icon.alpha = 0; SkinColor40_Icon = this.add.button(SkinColor35_Icon.x,SkinColor35_Icon.y + SkinColor35_Icon.height + 1,"color_icon_btn",function() { this.SkinColor_fnc(39); },this); SkinColor40_Icon.anchor.setTo(0.5,0.5); SkinColor40_Icon.alpha = 0; Skin_Prev = this.add.button(615,480,"back_btn",function() { skinColorPage--; if(skinColorPage == 2) { SkinColor_Pallette.visible = false; SkinColor_Pallette2.visible = true; } else if(skinColorPage <= 1) { SkinColor_Pallette.visible = true; SkinColor_Pallette2.visible = false; skinColorPage = 1; } },this,1,0,2); Skin_Prev.anchor.setTo(0.5,0.5); Skin_Next = this.add.button(811,Skin_Prev.y,"back_btn",function() { skinColorPage++; if(skinColorPage == 1) { SkinColor_Pallette.visible = true; SkinColor_Pallette2.visible = false; } else if(skinColorPage >= 2) { SkinColor_Pallette.visible = false; SkinColor_Pallette2.visible = true; skinColorPage = 2; } },this,1,0,2); Skin_Next.anchor.setTo(0.5,0.5); Skin_Next.scale.setTo(-1,1); SkinColor_Menu_Group = this.add.group(); SkinColor_Menu_Group.add(SkinColor_Pallette); SkinColor_Menu_Group.add(SkinColor_Pallette2); SkinColor_Menu_Group.add(SkinColor01_Icon); SkinColor_Menu_Group.add(SkinColor02_Icon); SkinColor_Menu_Group.add(SkinColor03_Icon); SkinColor_Menu_Group.add(SkinColor04_Icon); SkinColor_Menu_Group.add(SkinColor05_Icon); SkinColor_Menu_Group.add(SkinColor06_Icon); SkinColor_Menu_Group.add(SkinColor07_Icon); SkinColor_Menu_Group.add(SkinColor08_Icon); SkinColor_Menu_Group.add(SkinColor09_Icon); SkinColor_Menu_Group.add(SkinColor10_Icon); SkinColor_Menu_Group.add(SkinColor11_Icon); SkinColor_Menu_Group.add(SkinColor12_Icon); SkinColor_Menu_Group.add(SkinColor13_Icon); SkinColor_Menu_Group.add(SkinColor14_Icon); SkinColor_Menu_Group.add(SkinColor15_Icon); SkinColor_Menu_Group.add(SkinColor16_Icon); SkinColor_Menu_Group.add(SkinColor17_Icon); SkinColor_Menu_Group.add(SkinColor18_Icon); SkinColor_Menu_Group.add(SkinColor19_Icon); SkinColor_Menu_Group.add(SkinColor20_Icon); SkinColor_Menu_Group.add(SkinColor21_Icon); SkinColor_Menu_Group.add(SkinColor22_Icon); SkinColor_Menu_Group.add(SkinColor23_Icon); SkinColor_Menu_Group.add(SkinColor24_Icon); SkinColor_Menu_Group.add(SkinColor25_Icon); SkinColor_Menu_Group.add(SkinColor26_Icon); SkinColor_Menu_Group.add(SkinColor27_Icon); SkinColor_Menu_Group.add(SkinColor28_Icon); SkinColor_Menu_Group.add(SkinColor29_Icon); SkinColor_Menu_Group.add(SkinColor30_Icon); SkinColor_Menu_Group.add(SkinColor31_Icon); SkinColor_Menu_Group.add(SkinColor32_Icon); SkinColor_Menu_Group.add(SkinColor33_Icon); SkinColor_Menu_Group.add(SkinColor34_Icon); SkinColor_Menu_Group.add(SkinColor35_Icon); SkinColor_Menu_Group.add(SkinColor36_Icon); SkinColor_Menu_Group.add(SkinColor37_Icon); SkinColor_Menu_Group.add(SkinColor38_Icon); SkinColor_Menu_Group.add(SkinColor39_Icon); SkinColor_Menu_Group.add(SkinColor40_Icon); SkinColor_Menu_Group.add(Skin_Prev); SkinColor_Menu_Group.add(Skin_Next); SkinColor_Menu_Group.visible = false; //Tops_Icon Tops_Icon = this.add.button(Border.x,128,"tops_icon",function() { Clothes.visible = true; Clothes_Outline.visible = true; Clothes.frame = 0; Clothes.tint = Colors[4]; Clothes.x = TopsX[0]; Clothes.y = TopsY[0]; Clothes_Outline.frame = Clothes.frame; Clothes_Outline.x = Clothes.x; Clothes_Outline.y = Clothes.y; if(Bra.visible){Bra.visible = false;} if(Bottoms.visible == false){Panties.visible = true;} },this,1,0,0); Tops_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Tops_Icon); this.buttonDown_fnc(Tops_Icon);}; Tops_Icon2 = this.add.button(Border.x + 3,Tops_Icon.y + Tops_Icon.height + 11,"tops_icon2",function() { Clothes.visible = true; Clothes_Outline.visible = true; Clothes.frame = 1; Clothes.tint = Colors[1]; Clothes.x = TopsX[0]; Clothes.y = TopsY[0]; Clothes_Outline.frame = Clothes.frame; Clothes_Outline.x = Clothes.x; Clothes_Outline.y = Clothes.y; if(Bra.visible){Bra.visible = false;} if(Bottoms.visible == false){Panties.visible = true;} },this,1,0,0); Tops_Icon2.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Tops_Icon2); this.buttonDown_fnc(Tops_Icon2);}; Tops_Icon3 = this.add.button(Border.x,Tops_Icon2.y + Tops_Icon2.height + 10.7,"tops_icon3",function() { Clothes.visible = true; Clothes_Outline.visible = true; Clothes.frame = 2; Clothes.tint = Colors[36]; Clothes.x = TopsX[0]; Clothes.y = TopsY[0]; Clothes_Outline.frame = Clothes.frame; Clothes_Outline.x = Clothes.x; Clothes_Outline.y = Clothes.y; if(!Bra.visible){Bra.visible = true;} if(Bottoms.visible == false){Panties.visible = true;} },this,1,0,0); Tops_Icon3.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Tops_Icon3); this.buttonDown_fnc(Tops_Icon3);}; Tops_Icon4 = this.add.button(Border.x,Tops_Icon.y + 1,"tops_icon4",function() { Clothes.visible = true; Clothes_Outline.visible = true; Clothes.frame = 3; Clothes.tint = Colors[1]; Clothes.x = TopsX[0]; Clothes.y = TopsY[0]; Clothes_Outline.frame = Clothes.frame; Clothes_Outline.x = Clothes.x; Clothes_Outline.y = Clothes.y; if(Bra.visible){Bra.visible = false;} if(Bottoms.visible == false){Panties.visible = true;} },this,1,0,0); Tops_Icon4.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Tops_Icon4); this.buttonDown_fnc(Tops_Icon4);}; Tops_Icon4.visible = false; Tops_Icon5 = this.add.button(Border.x,Tops_Icon4.y + Tops_Icon4.height + 10,"tops_icon5",function() { Clothes.visible = true; Clothes_Outline.visible = true; Clothes.frame = 4; Clothes.tint = Colors[1]; Clothes.x = TopsX[0]; Clothes.y = TopsY[0]; Clothes_Outline.frame = Clothes.frame; Clothes_Outline.x = Clothes.x; Clothes_Outline.y = Clothes.y; if(!Bra.visible){Bra.visible = true;} if(Bottoms.visible == false){Panties.visible = true;} },this,1,0,0); Tops_Icon5.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Tops_Icon5); this.buttonDown_fnc(Tops_Icon5);}; Tops_Icon5.visible = false; Tops_Icon6 = this.add.button(Border.x,Tops_Icon5.y + Tops_Icon5.height + 10,"tops_icon6",function() { Clothes.visible = true; Clothes_Outline.visible = true; Clothes.frame = 5; Clothes.tint = Colors[4]; Clothes.x = TopsX[0]; Clothes.y = TopsY[0]; Clothes_Outline.frame = Clothes.frame; Clothes_Outline.x = Clothes.x; Clothes_Outline.y = Clothes.y; if(!Bra.visible){Bra.visible = true;} if(Bottoms.visible == false){Panties.visible = true;} },this,1,0,0); Tops_Icon6.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Tops_Icon6); this.buttonDown_fnc(Tops_Icon6);}; Tops_Icon6.visible = false; Tops_Menu_Group = this.add.group(); Tops_Menu_Group.add(Tops_Icon); Tops_Menu_Group.add(Tops_Icon2); Tops_Menu_Group.add(Tops_Icon3); Tops_Menu_Group.add(Tops_Icon4); Tops_Menu_Group.add(Tops_Icon5); Tops_Menu_Group.add(Tops_Icon6); Tops_Menu_Group.setAll("input.pixelPerfectClick",true); Tops_Menu_Group.setAll("input.pixelPerfectOver",true); Tops_Menu_Group.visible = false; //Bottoms_Icon Bottoms_Icon = this.add.button(Border.x,129.5,"bottoms_icon",function() { Bottoms.frame = 0; Bottoms_Outline.frame = Bottoms.frame; Bottoms.tint = Colors[1]; Bottoms.visible = true; Bottoms_Outline.visible = true; if(Panties.visible){Panties.visible = false;} /*if(Clothes.frame <= 5) { Bottoms.visible = true; Bottoms_Outline.visible = true; } else { Bottoms.visible = true; Bottoms_Outline.visible = true; }*/ },this,1,0,0); Bottoms_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Bottoms_Icon); this.buttonDown_fnc(Bottoms_Icon);}; Bottoms_Icon2 = this.add.button(Border.x,Bottoms_Icon.y + Bottoms_Icon.height + 10,"bottoms_icon2",function() { Bottoms.frame = 1; Bottoms_Outline.frame = Bottoms.frame; Bottoms.tint = Colors[0]; Bottoms.visible = true; Bottoms_Outline.visible = true; if(Panties.visible){Panties.visible = false;} /*if(Clothes.frame <= 5) { Bottoms.visible = true; Bottoms_Outline.visible = true; } else { Bottoms.visible = false; Bottoms_Outline.visible = false; }*/ },this,1,0,0); Bottoms_Icon2.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Bottoms_Icon2); this.buttonDown_fnc(Bottoms_Icon2);}; Bottoms_Icon3 = this.add.button(Border.x,Bottoms_Icon2.y + Bottoms_Icon2.height + 10,"bottoms_icon3",function() { Bottoms.frame = 2; Bottoms_Outline.frame = Bottoms.frame; Bottoms.tint = Colors2[5]; Bottoms.visible = true; Bottoms_Outline.visible = true; if(Panties.visible){Panties.visible = false;} /*if(Clothes.frame <= 5) { Bottoms.visible = true; Bottoms_Outline.visible = true; } else { Bottoms.visible = false; Bottoms_Outline.visible = false; }*/ },this,1,0,0); Bottoms_Icon3.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Bottoms_Icon3); this.buttonDown_fnc(Bottoms_Icon3);}; Bottoms_Icon4 = this.add.button(Border.x,Bottoms_Icon.y,"bottoms_icon4",function() { Bottoms.frame = 3; Bottoms_Outline.frame = Bottoms.frame; Bottoms.tint = Colors2[3]; Bottoms.visible = true; Bottoms_Outline.visible = true; if(Panties.visible){Panties.visible = false;} /*if(Clothes.frame <= 5) { Bottoms.visible = true; Bottoms_Outline.visible = true; } else { Bottoms.visible = false; Bottoms_Outline.visible = false; }*/ },this,1,0,0); Bottoms_Icon4.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Bottoms_Icon4); this.buttonDown_fnc(Bottoms_Icon4);}; Bottoms_Icon4.visible = false; Bottoms_Icon5 = this.add.button(Border.x,Bottoms_Icon4.y + Bottoms_Icon4.height + 10,"bottoms_icon5",function() { Bottoms.frame = 4; Bottoms_Outline.frame = Bottoms.frame; Bottoms.tint = Colors[0]; Bottoms.visible = true; Bottoms_Outline.visible = true; if(Panties.visible){Panties.visible = false;} /*if(Clothes.frame <= 5) { Bottoms.visible = true; Bottoms_Outline.visible = true; } else { Bottoms.visible = false; Bottoms_Outline.visible = false; }*/ },this,1,0,0); Bottoms_Icon5.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Bottoms_Icon5); this.buttonDown_fnc(Bottoms_Icon5);}; Bottoms_Icon5.visible = false; Bottoms_Icon6 = this.add.button(Border.x,Bottoms_Icon5.y + Bottoms_Icon5.height + 10,"bottoms_icon6",function() { Bottoms.frame = 5; Bottoms_Outline.frame = Bottoms.frame; Bottoms.tint = Colors[1]; Bottoms.visible = true; Bottoms_Outline.visible = true; if(Panties.visible){Panties.visible = false;} /*if(Clothes.frame <= 5) { Bottoms.visible = true; Bottoms_Outline.visible = true; } else { Bottoms.visible = false; Bottoms_Outline.visible = false; }*/ },this,1,0,0); Bottoms_Icon6.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Bottoms_Icon6); this.buttonDown_fnc(Bottoms_Icon6);}; Bottoms_Icon6.visible = false; Bottoms_Menu_Group = this.add.group(); Bottoms_Menu_Group.add(Bottoms_Icon); Bottoms_Menu_Group.add(Bottoms_Icon2); Bottoms_Menu_Group.add(Bottoms_Icon3); Bottoms_Menu_Group.add(Bottoms_Icon4); Bottoms_Menu_Group.add(Bottoms_Icon5); Bottoms_Menu_Group.add(Bottoms_Icon6); Bottoms_Menu_Group.visible = false; //Dress_Icon Dress_Icon = this.add.button(Border.x,128,"dress_icon",function() { Clothes.visible = true; Clothes_Outline.visible = true; Clothes.frame = 6; Clothes_Outline.frame = Clothes.frame; /*Clothes.x = DressX[0]; Clothes.y = DressY[0]; Clothes_Outline.x = Clothes.x; Clothes_Outline.y = Clothes.y;*/ Clothes.tint = Colors[1]; Bottoms.visible = false; Bottoms_Outline.visible = false; if(Bra.visible){Bra.visible = false;} if(Panties.visible){Panties.visible = false;} },this,1,0,0); Dress_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Dress_Icon); this.buttonDown_fnc(Dress_Icon);}; Dress_Icon2 = this.add.button(Border.x,Dress_Icon.y + Dress_Icon.height + 10.5,"dress_icon2",function() { Clothes.visible = true; Clothes_Outline.visible = true; Clothes.frame = 7; Clothes_Outline.frame = Clothes.frame; /*Clothes.x = DressX[0]; Clothes.y = DressY[0]; Clothes_Outline.x = Clothes.x; Clothes_Outline.y = Clothes.y;*/ Clothes.tint = Colors[38]; Bottoms.visible = false; Bottoms_Outline.visible = false; if(Bra.visible){Bra.visible = false;} if(Panties.visible){Panties.visible = false;} },this,1,0,0); Dress_Icon2.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Dress_Icon2); this.buttonDown_fnc(Dress_Icon2);}; Dress_Icon3 = this.add.button(Border.x,Dress_Icon2.y + Dress_Icon2.height + 11,"dress_icon3",function() { Clothes.visible = true; Clothes_Outline.visible = true; Clothes.frame = 8; Clothes_Outline.frame = Clothes.frame; /*Clothes.x = DressX[0]; Clothes.y = DressY[0]; Clothes_Outline.x = Clothes.x; Clothes_Outline.y = Clothes.y;*/ Clothes.tint = Colors[1]; Bottoms.visible = false; Bottoms_Outline.visible = false; if(Bra.visible){Bra.visible = false;} if(Panties.visible){Panties.visible = false;} },this,1,0,0); Dress_Icon3.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Dress_Icon3); this.buttonDown_fnc(Dress_Icon3);}; Dress_Icon4 = this.add.button(Border.x + .7,Dress_Icon.y + 1.7,"dress_icon4",function() { Clothes.visible = true; Clothes_Outline.visible = true; Clothes.frame = 9; Clothes_Outline.frame = Clothes.frame; /*Clothes.x = DressX[0]; Clothes.y = DressY[0]; Clothes_Outline.x = Clothes.x; Clothes_Outline.y = Clothes.y;*/ Clothes.tint = Colors[1]; Bottoms.visible = false; Bottoms_Outline.visible = false; if(Bra.visible){Bra.visible = false;} if(Panties.visible){Panties.visible = false;} },this,1,0,0); Dress_Icon4.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Dress_Icon4); this.buttonDown_fnc(Dress_Icon4);}; Dress_Icon4.visible = false; Dress_Icon5 = this.add.button(Border.x + 1,Dress_Icon4.y + Dress_Icon4.height + 9,"dress_icon5",function() { Clothes.visible = true; Clothes_Outline.visible = true; Clothes.frame = 10; Clothes_Outline.frame = Clothes.frame; /*Clothes.x = DressX[0]; Clothes.y = DressY[0]; Clothes_Outline.x = Clothes.x; Clothes_Outline.y = Clothes.y;*/ Clothes.tint = Colors2[7]; Bottoms.visible = false; Bottoms_Outline.visible = false; if(!Bra.visible){Bra.visible = true;} if(Panties.visible){Panties.visible = false;} },this,1,0,0); Dress_Icon5.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Dress_Icon5); this.buttonDown_fnc(Dress_Icon5);}; Dress_Icon5.visible = false; Dress_Icon6 = this.add.button(Border.x + 1,Dress_Icon5.y + Dress_Icon5.height + 10,"dress_icon6",function() { Clothes.visible = true; Clothes_Outline.visible = true; Clothes.frame = 11; Clothes_Outline.frame = Clothes.frame; /*Clothes.x = DressX[0]; Clothes.y = DressY[0]; Clothes_Outline.x = Clothes.x; Clothes_Outline.y = Clothes.y;*/ Clothes.tint = Colors[1]; Bottoms.visible = false; Bottoms_Outline.visible = false; if(Bra.visible){Bra.visible = false;} if(Panties.visible){Panties.visible = false;} },this,1,0,0); Dress_Icon6.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Dress_Icon6); this.buttonDown_fnc(Dress_Icon6);}; Dress_Icon6.visible = false; Dress_Menu_Group = this.add.group(); Dress_Menu_Group.add(Dress_Icon); Dress_Menu_Group.add(Dress_Icon2); Dress_Menu_Group.add(Dress_Icon3); Dress_Menu_Group.add(Dress_Icon4); Dress_Menu_Group.add(Dress_Icon5); Dress_Menu_Group.add(Dress_Icon6); Dress_Menu_Group.visible = false; //Shoes_Icon Shoes_Icon = this.add.button(Border.x + .5,130,"shoes_icon",function() { Shoes.visible = true; Shoes_Outline.visible = true; Shoes.frame = 0; Shoes_Outline.frame = Shoes.frame; Shoes.tint = Colors[4]; },this,1,0,0); Shoes_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Shoes_Icon); this.buttonDown_fnc(Shoes_Icon);}; Shoes_Icon2 = this.add.button(Border.x + .5,Shoes_Icon.y + Shoes_Icon.height + 10,"shoes_icon2",function() { Shoes.visible = true; Shoes_Outline.visible = true; Shoes.frame = 1; Shoes_Outline.frame = Shoes.frame; Shoes.tint = Colors[1]; },this,1,0,0); Shoes_Icon2.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Shoes_Icon2); this.buttonDown_fnc(Shoes_Icon2);}; Shoes_Icon3 = this.add.button(Border.x + .5,Shoes_Icon2.y + Shoes_Icon2.height + 10,"shoes_icon3",function() { Shoes.visible = true; Shoes_Outline.visible = true; Shoes.frame = 2; Shoes_Outline.frame = Shoes.frame; Shoes.tint = Colors[1]; },this,1,0,0); Shoes_Icon3.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Shoes_Icon3); this.buttonDown_fnc(Shoes_Icon3);}; Shoes_Icon4 = this.add.button(Border.x,Shoes_Icon.y,"shoes_icon4",function() { Shoes.visible = true; Shoes_Outline.visible = true; Shoes.frame = 3; Shoes_Outline.frame = Shoes.frame; Shoes.tint = Colors[1]; },this,1,0,0); Shoes_Icon4.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Shoes_Icon4); this.buttonDown_fnc(Shoes_Icon4);}; Shoes_Icon4.visible = false; Shoes_Icon5 = this.add.button(Border.x,Shoes_Icon4.y + Shoes_Icon4.height + 11,"shoes_icon5",function() { Shoes.visible = true; Shoes_Outline.visible = true; Shoes.frame = 4; Shoes_Outline.frame = Shoes.frame; Shoes.tint = Colors[36]; },this,1,0,0); Shoes_Icon5.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Shoes_Icon5); this.buttonDown_fnc(Shoes_Icon5);}; Shoes_Icon5.visible = false; Shoes_Icon6 = this.add.button(Border.x,Shoes_Icon5.y + Shoes_Icon5.height + 11,"shoes_icon6",function() { Shoes.visible = true; Shoes_Outline.visible = true; Shoes.frame = 5; Shoes_Outline.frame = Shoes.frame; Shoes.tint = Colors[1]; },this,1,0,0); Shoes_Icon6.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Shoes_Icon6); this.buttonDown_fnc(Shoes_Icon6);}; Shoes_Icon6.visible = false; Shoes_Menu_Group = this.add.group(); Shoes_Menu_Group.add(Shoes_Icon); Shoes_Menu_Group.add(Shoes_Icon2); Shoes_Menu_Group.add(Shoes_Icon3); Shoes_Menu_Group.add(Shoes_Icon4); Shoes_Menu_Group.add(Shoes_Icon5); Shoes_Menu_Group.add(Shoes_Icon6); Shoes_Menu_Group.visible = false; //Socks_Icon Socks_Icon = this.add.button(Border.x + .5,130,"socks_icon",function() { Socks.visible = true; Socks_Outline.visible = true; Socks.frame = 0; Socks_Outline.frame = Socks.frame; Socks.tint = Colors[1]; if(!Bottoms.visible && Clothes.frame <= 5){Panties.visible = true;} },this,1,0,0); Socks_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Socks_Icon); this.buttonDown_fnc(Socks_Icon);}; Socks_Icon2 = this.add.button(Border.x + .5,Socks_Icon.y + Socks_Icon.height + 10,"socks_icon2",function() { Socks.visible = true; Socks_Outline.visible = true; Socks.frame = 1; Socks_Outline.frame = Socks.frame; Socks.tint = Colors[1]; },this,1,0,0); Socks_Icon2.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Socks_Icon2); this.buttonDown_fnc(Socks_Icon2);}; Socks_Icon3 = this.add.button(Border.x + .5,Socks_Icon2.y + Socks_Icon2.height + 10,"socks_icon3",function() { Socks.visible = true; Socks_Outline.visible = true; Socks.frame = 2; Socks_Outline.frame = Socks.frame; Socks.tint = Colors[1]; },this,1,0,0); Socks_Icon3.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Socks_Icon3); this.buttonDown_fnc(Socks_Icon3);}; Socks_Icon4 = this.add.button(Border.x + .5,Socks_Icon.y +.5,"socks_icon4",function() { Socks.visible = true; Socks_Outline.visible = true; Socks.frame = 3; Socks_Outline.frame = Socks.frame; Socks.tint = Colors[1]; },this,1,0,0); Socks_Icon4.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Socks_Icon4); this.buttonDown_fnc(Socks_Icon4);}; Socks_Icon4.visible = false; Socks_Icon5 = this.add.button(Border.x + .5,Socks_Icon4.y + Socks_Icon4.height + 9,"socks_icon5",function() { Socks.visible = true; Socks_Outline.visible = true; Socks.frame = 4; Socks_Outline.frame = Socks.frame; Socks.tint = Colors[1]; },this,1,0,0); Socks_Icon5.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Socks_Icon5); this.buttonDown_fnc(Socks_Icon5);}; Socks_Icon5.visible = false; Socks_Icon6 = this.add.button(Border.x + .5,Socks_Icon5.y + Socks_Icon5.height + 8,"socks_icon6",function() { Socks.visible = true; Socks_Outline.visible = false; Socks.frame = 5; Socks_Outline.frame = Socks.frame; Socks.tint = Colors[1]; },this,1,0,0); Socks_Icon6.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Socks_Icon6); this.buttonDown_fnc(Socks_Icon6);}; Socks_Icon6.visible = false; Socks_Menu_Group = this.add.group(); Socks_Menu_Group.add(Socks_Icon); Socks_Menu_Group.add(Socks_Icon2); Socks_Menu_Group.add(Socks_Icon3); Socks_Menu_Group.add(Socks_Icon4); Socks_Menu_Group.add(Socks_Icon5); Socks_Menu_Group.add(Socks_Icon6); Socks_Menu_Group.visible = false; //Extra_Icon Extra_Icon = this.add.button(Border.x,129,"extra_icon",function() { if(Extra.visible) { Extra.visible = false; Extra_Outline.visible = false; } else { Extra.visible = true; Extra_Outline.visible = true; Extra.tint = Colors[0]; } },this,1,0,0); Extra_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Extra_Icon); this.buttonDown_fnc(Extra_Icon);}; Extra_Icon2 = this.add.button(Border.x,Extra_Icon.y + Extra_Icon.height + 10.2,"extra_icon2",function() { if(!Extra2.visible) { Extra2.visible = true; Extra2_Outline.visible = true; Extra2.tint = Colors[21]; } else { Extra2.visible = false; Extra2_Outline.visible = false; } },this,1,0,0); Extra_Icon2.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Extra_Icon2); this.buttonDown_fnc(Extra_Icon2);}; Extra_Icon3 = this.add.button(Border.x,Extra_Icon2.y + Extra_Icon2.height + 9.2,"extra_icon3",function() { if(Extra3.visible) { Extra3.visible = false; Extra3_Outline.visible = false; } else { Extra3.visible = true; Extra3_Outline.visible = true; Extra3.tint = Colors[1]; } },this,1,0,0); Extra_Icon3.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Extra_Icon3); this.buttonDown_fnc(Extra_Icon3);}; Extra_Icon4 = this.add.button(Border.x,Extra_Icon.y - 1,"extra_icon4",function() { if(!Extra4.visible) { Extra4.visible = true; Extra4_Outline.visible = true; Extra4.tint = Colors[1]; } else { Extra4.visible = false; Extra4_Outline.visible = false; } },this,1,0,0); Extra_Icon4.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Extra_Icon4); this.buttonDown_fnc(Extra_Icon4);}; Extra_Icon4.visible = false; Extra_Icon5 = this.add.button(Border.x,Extra_Icon4.y + Extra_Icon4.height + 11,"extra_icon5",function() { if(!Extra5.visible) { Extra5.visible = true; Extra5_Outline.visible = true; Extra5.tint = Colors[1]; } else { Extra5.visible = false; Extra5_Outline.visible = false; } },this,1,0,0); Extra_Icon5.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Extra_Icon5); this.buttonDown_fnc(Extra_Icon5);}; Extra_Icon5.visible = false; Extra_Icon6 = this.add.button(Border.x,Extra_Icon5.y + Extra_Icon5.height + 10,"extra_icon6",function() { if(!Extra6.visible) { Extra6.visible = true; Extra6_Outline.visible = true; Extra6.tint = Colors[1]; } else { Extra6.visible = false; Extra6_Outline.visible = false; } },this,1,0,0); Extra_Icon6.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Extra_Icon6); this.buttonDown_fnc(Extra_Icon6);}; Extra_Icon6.visible = false; Extra_Menu_Group = this.add.group(); Extra_Menu_Group.add(Extra_Icon); Extra_Menu_Group.add(Extra_Icon2); Extra_Menu_Group.add(Extra_Icon3); Extra_Menu_Group.add(Extra_Icon4); Extra_Menu_Group.add(Extra_Icon5); Extra_Menu_Group.add(Extra_Icon6); Extra_Menu_Group.visible = false; //Cake_Icon Cake_Icon = this.add.button(Border.x,130,"cake_icon",function() { BG.visible = true; BG2.visible = false; BG3.visible = false; },this,1,0,0); Cake_Icon.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Cake_Icon); this.buttonDown_fnc(Cake_Icon);}; Cake_Icon2 = this.add.button(Border.x,Cake_Icon.y + Cake_Icon.height + 10.7,"cake_icon2",function() { BG.visible = false; BG2.visible = true; BG3.visible = false; },this,1,0,0); Cake_Icon2.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Cake_Icon2); this.buttonDown_fnc(Cake_Icon2);}; Cake_Icon3 = this.add.button(Border.x,Cake_Icon2.y + Cake_Icon2.height + 9.7,"cake_icon3",function() { BG.visible = false; BG2.visible = false; BG3.visible = true; },this,1,0,0); Cake_Icon3.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Cake_Icon3); this.buttonDown_fnc(Cake_Icon3);}; /*Cake_Icon4 = this.add.button(Border.x,130,"cake_icon4",function() { Cake.frame = 3; Cake.x = CakeX[3]; Cake.y = CakeY[3]; Cake.tint = Colors[12]; Cake_Outline.frame = Cake.frame; Cake_Outline.x = Cake.x; Cake_Outline.y = Cake.y; if(!Cake.visible) { Cake.visible = true; Cake_Outline.visible = true; } },this,1,0,0); Cake_Icon4.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Cake_Icon4); this.buttonDown_fnc(Cake_Icon4);}; Cake_Icon4.visible = false; Cake_Icon5 = this.add.button(Border.x,Cake_Icon4.y + Cake_Icon4.height + 10.2,"cake_icon5",function() { Cake.frame = 4; Cake.x = CakeX[4]; Cake.y = CakeY[4]; Cake.tint = Colors[4]; Cake_Outline.frame = Cake.frame; Cake_Outline.x = Cake.x; Cake_Outline.y = Cake.y; if(!Cake.visible) { Cake.visible = true; Cake_Outline.visible = true; } },this,1,0,0); Cake_Icon5.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Cake_Icon5); this.buttonDown_fnc(Cake_Icon5);}; Cake_Icon6 = this.add.button(Border.x,Cake_Icon5.y + Cake_Icon5.height + 10.2,"cake_icon6",function() { Cake.frame = 5; Cake.x = CakeX[5]; Cake.y = CakeY[5]; Cake.tint = Colors[1]; Cake_Outline.frame = Cake.frame; Cake_Outline.x = Cake.x; Cake_Outline.y = Cake.y; if(!Cake.visible) { Cake.visible = true; Cake_Outline.visible = true; } },this,1,0,0); Cake_Icon6.anchor.setTo(0.5,0.5); if(!this.game.device.desktop){this.buttonUp_fnc(Cake_Icon6); this.buttonDown_fnc(Cake_Icon6);};*/ Cake_Menu_Group = this.add.group(); Cake_Menu_Group.add(Cake_Icon); Cake_Menu_Group.add(Cake_Icon2); Cake_Menu_Group.add(Cake_Icon3); /*Cake_Menu_Group.add(Cake_Icon4); Cake_Menu_Group.add(Cake_Icon5); Cake_Menu_Group.add(Cake_Icon6);*/ Cake_Menu_Group.visible = false; Color_Prev = this.add.button(672,480,"back_btn",function() { colorPage--; if(colorPage == 2) { Color_Pallette.visible = false; Color_Pallette2.visible = true; } else if(colorPage <= 1) { Color_Pallette.visible = true; Color_Pallette2.visible = false; colorPage = 1; } },this,1,0,2); Color_Prev.anchor.setTo(0.5,0.5); Color_Next = this.add.button(Color_Prev.x + Color_Prev.width + 22,Color_Prev.y,"back_btn",function() { colorPage++; if(colorPage == 1) { Color_Pallette.visible = true; Color_Pallette2.visible = false; } else if(colorPage >= 2) { Color_Pallette.visible = false; Color_Pallette2.visible = true; colorPage = 2; } },this,1,0,2); Color_Next.anchor.setTo(0.5,0.5); Color_Next.scale.setTo(-1,1); Color_Group = this.add.group(); Color_Group.add(Color_Pallette); Color_Group.add(Color_Pallette2); Color_Group.add(Color01_Icon); Color_Group.add(Color02_Icon); Color_Group.add(Color03_Icon); Color_Group.add(Color04_Icon); Color_Group.add(Color05_Icon); Color_Group.add(Color06_Icon); Color_Group.add(Color07_Icon); Color_Group.add(Color08_Icon); Color_Group.add(Color09_Icon); Color_Group.add(Color10_Icon); Color_Group.add(Color11_Icon); Color_Group.add(Color12_Icon); Color_Group.add(Color13_Icon); Color_Group.add(Color14_Icon); Color_Group.add(Color15_Icon); Color_Group.add(Color16_Icon); Color_Group.add(Color17_Icon); Color_Group.add(Color18_Icon); Color_Group.add(Color19_Icon); Color_Group.add(Color20_Icon); Color_Group.add(Color21_Icon); Color_Group.add(Color22_Icon); Color_Group.add(Color23_Icon); Color_Group.add(Color24_Icon); Color_Group.add(Color25_Icon); Color_Group.add(Color26_Icon); Color_Group.add(Color27_Icon); Color_Group.add(Color28_Icon); Color_Group.add(Color29_Icon); Color_Group.add(Color30_Icon); Color_Group.add(Color31_Icon); Color_Group.add(Color32_Icon); Color_Group.add(Color33_Icon); Color_Group.add(Color34_Icon); Color_Group.add(Color35_Icon); Color_Group.add(Color36_Icon); Color_Group.add(Color37_Icon); Color_Group.add(Color38_Icon); Color_Group.add(Color39_Icon); Color_Group.add(Color40_Icon); Color_Group.add(Color_Prev); Color_Group.add(Color_Next); Color_Group.visible = false; //Next_Prev Next_Btn = this.add.button(827,266,"next_btn",function() { if(openedMenu == 1) { openedMenuPage ++; if(openedMenuPage > 2) { openedMenuPage = 1; } if(openedMenuPage == 1) { /*Bang01_Icon.visible = true; Bang02_Icon.visible = true; Bang03_Icon.visible = true; Bang04_Icon.visible = false; Bang05_Icon.visible = false; Bang06_Icon.visible = false;*/ Hair01_Icon.visible = true; Hair02_Icon.visible = true; Hair03_Icon.visible = true; Hair04_Icon.visible = false; Hair05_Icon.visible = false; Hair06_Icon.visible = false; } if(openedMenuPage == 2) { /*Bang01_Icon.visible = false; Bang02_Icon.visible = false; Bang03_Icon.visible = false; Bang04_Icon.visible = true; Bang05_Icon.visible = true; Bang06_Icon.visible = true;*/ Hair01_Icon.visible = false; Hair02_Icon.visible = false; Hair03_Icon.visible = false; Hair04_Icon.visible = true; Hair05_Icon.visible = true; Hair06_Icon.visible = true; } if(openedMenuPage == 3) { Bang01_Icon.visible = false; Bang02_Icon.visible = false; Bang03_Icon.visible = false; Bang04_Icon.visible = false; Bang05_Icon.visible = false; Bang06_Icon.visible = false; Hair01_Icon.visible = true; Hair02_Icon.visible = true; Hair03_Icon.visible = true; } if(openedMenuPage == 4) { Bang01_Icon.visible = false; Bang02_Icon.visible = false; Bang03_Icon.visible = false; Bang04_Icon.visible = false; Bang05_Icon.visible = false; Bang06_Icon.visible = false; Hair01_Icon.visible = false; Hair02_Icon.visible = false; Hair03_Icon.visible = false; Hair04_Icon.visible = true; Hair05_Icon.visible = true; Hair06_Icon.visible = true; } } if(openedMenu == 6) { openedMenuPage ++; if(openedMenuPage > 2) { openedMenuPage = 1; } if(openedMenuPage == 1) { Lips01_Icon.visible = true; Lips02_Icon.visible = true; Lips03_Icon.visible = true; Lips04_Icon.visible = false; Lips05_Icon.visible = false; Lips06_Icon.visible = false; } if(openedMenuPage == 2) { Lips01_Icon.visible = false; Lips02_Icon.visible = false; Lips03_Icon.visible = false; Lips04_Icon.visible = true; Lips05_Icon.visible = true; Lips06_Icon.visible = true; } } if(openedMenu == 8) { openedMenuPage ++; if(openedMenuPage >= 3) { openedMenuPage = 1; } if(openedMenuPage == 1) { /*Tops_Menu_Group.visible = true; Tops_Menu_Group2.visible = false;*/ Tops_Icon.visible = true; Tops_Icon2.visible = true; Tops_Icon3.visible = true; Tops_Icon4.visible = false; Tops_Icon5.visible = false; Tops_Icon6.visible = false; } if(openedMenuPage == 2) { /*Tops_Menu_Group.visible = false; Tops_Menu_Group2.visible = true;*/ Tops_Icon.visible = false; Tops_Icon2.visible = false; Tops_Icon3.visible = false; Tops_Icon4.visible = true; Tops_Icon5.visible = true; Tops_Icon6.visible = true; } } if(openedMenu == 9) { openedMenuPage ++; if(openedMenuPage > 2) { openedMenuPage = 1; } if(openedMenuPage == 1) { Bottoms_Icon.visible = true; Bottoms_Icon2.visible = true; Bottoms_Icon3.visible = true; Bottoms_Icon4.visible = false; Bottoms_Icon5.visible = false; Bottoms_Icon6.visible = false; } if(openedMenuPage == 2) { Bottoms_Icon.visible = false; Bottoms_Icon2.visible = false; Bottoms_Icon3.visible = false; Bottoms_Icon4.visible = true; Bottoms_Icon5.visible = true; Bottoms_Icon6.visible = true; } } if(openedMenu == 10) { openedMenuPage ++; if(openedMenuPage > 2) { openedMenuPage = 1; } if(openedMenuPage == 1) { Dress_Icon.visible = true; Dress_Icon2.visible = true; Dress_Icon3.visible = true; Dress_Icon4.visible = false; Dress_Icon5.visible = false; Dress_Icon6.visible = false; } if(openedMenuPage == 2) { Dress_Icon.visible = false; Dress_Icon2.visible = false; Dress_Icon3.visible = false; Dress_Icon4.visible = true; Dress_Icon5.visible = true; Dress_Icon6.visible = true; } } if(openedMenu == 11) { openedMenuPage ++; if(openedMenuPage > 2) { openedMenuPage = 1; } if(openedMenuPage == 1) { Shoes_Icon.visible = true; Shoes_Icon2.visible = true; Shoes_Icon3.visible = true; Shoes_Icon4.visible = false; Shoes_Icon5.visible = false; Shoes_Icon6.visible = false; } if(openedMenuPage == 2) { Shoes_Icon.visible = false; Shoes_Icon2.visible = false; Shoes_Icon3.visible = false; Shoes_Icon4.visible = true; Shoes_Icon5.visible = true; Shoes_Icon6.visible = true; } } if(openedMenu == 12) { openedMenuPage ++; if(openedMenuPage > 2) { openedMenuPage = 1; } if(openedMenuPage == 1) { Socks_Icon.visible = true; Socks_Icon2.visible = true; Socks_Icon3.visible = true; Socks_Icon4.visible = false; Socks_Icon5.visible = false; Socks_Icon6.visible = false; } if(openedMenuPage == 2) { Socks_Icon.visible = false; Socks_Icon2.visible = false; Socks_Icon3.visible = false; Socks_Icon4.visible = true; Socks_Icon5.visible = true; Socks_Icon6.visible = true; } } if(openedMenu == 13) { openedMenuPage ++; if(openedMenuPage > 2) { openedMenuPage = 1; } if(openedMenuPage == 1) { Extra_Icon.visible = true; Extra_Icon2.visible = true; Extra_Icon3.visible = true; Extra_Icon4.visible = false; Extra_Icon5.visible = false; Extra_Icon6.visible = false; /*Extra_Icon7.visible = false; Extra_Icon8.visible = false; Extra_Icon9.visible = false; Extra_Icon10.visible = false; Extra_Icon11.visible = false; Extra_Icon12.visible = false;*/ } if(openedMenuPage == 2) { Extra_Icon.visible = false; Extra_Icon2.visible = false; Extra_Icon3.visible = false; Extra_Icon4.visible = true; Extra_Icon5.visible = true; Extra_Icon6.visible = true; } /*if(openedMenuPage == 3) { Extra_Icon.visible = false; Extra_Icon2.visible = false; Extra_Icon3.visible = false; Extra_Icon4.visible = false; Extra_Icon5.visible = false; Extra_Icon6.visible = false; Extra_Icon7.visible = true; Extra_Icon8.visible = true; Extra_Icon9.visible = true; } if(openedMenuPage == 4) { Extra_Icon.visible = false; Extra_Icon2.visible = false; Extra_Icon3.visible = false; Extra_Icon4.visible = false; Extra_Icon5.visible = false; Extra_Icon6.visible = false; Extra_Icon7.visible = false; Extra_Icon8.visible = false; Extra_Icon9.visible = false; Extra_Icon10.visible = true; Extra_Icon11.visible = true; Extra_Icon12.visible = true; }*/ } if(openedMenu == 14) { openedMenuPage ++; if(openedMenuPage > 2) { openedMenuPage = 1; } if(openedMenuPage == 1) { Cake_Icon.visible = true; Cake_Icon2.visible = true; Cake_Icon3.visible = true; Cake_Icon4.visible = false; Cake_Icon5.visible = false; Cake_Icon6.visible = false; } if(openedMenuPage == 2) { Cake_Icon.visible = false; Cake_Icon2.visible = false; Cake_Icon3.visible = false; Cake_Icon4.visible = true; Cake_Icon5.visible = true; Cake_Icon6.visible = true; } } },this); Next_Btn.anchor.setTo(0.5,0.5); Next_Btn.input.pixelPerfectClick = true; Next_Btn.input.pixelPerfectOver = true; Prev_Btn = this.add.sprite(614,Next_Btn.y,"prev_btn"); Prev_Btn.anchor.setTo(0.5,0.5); Prev_Btn.inputEnabled = true; Prev_Btn.input.pixelPerfectClick = true; Prev_Btn.input.pixelPerfectOver = true; Prev_Btn.events.onInputUp.add(function() { if(openedMenu == 1) { openedMenuPage --; if(openedMenuPage < 1) { openedMenuPage = 2; } if(openedMenuPage == 1) { /*Bang01_Icon.visible = true; Bang02_Icon.visible = true; Bang03_Icon.visible = true; Bang04_Icon.visible = false; Bang05_Icon.visible = false; Bang06_Icon.visible = false;*/ Hair01_Icon.visible = true; Hair02_Icon.visible = true; Hair03_Icon.visible = true; Hair04_Icon.visible = false; Hair05_Icon.visible = false; Hair06_Icon.visible = false; } if(openedMenuPage == 2) { /*Bang01_Icon.visible = false; Bang02_Icon.visible = false; Bang03_Icon.visible = false; Bang04_Icon.visible = true; Bang05_Icon.visible = true; Bang06_Icon.visible = true;*/ Hair01_Icon.visible = false; Hair02_Icon.visible = false; Hair03_Icon.visible = false; Hair04_Icon.visible = true; Hair05_Icon.visible = true; Hair06_Icon.visible = true; } if(openedMenuPage == 3) { Bang01_Icon.visible = false; Bang02_Icon.visible = false; Bang03_Icon.visible = false; Bang04_Icon.visible = false; Bang05_Icon.visible = false; Bang06_Icon.visible = false; Hair01_Icon.visible = true; Hair02_Icon.visible = true; Hair03_Icon.visible = true; Hair04_Icon.visible = false; Hair05_Icon.visible = false; Hair06_Icon.visible = false; } if(openedMenuPage == 4) { Bang01_Icon.visible = false; Bang02_Icon.visible = false; Bang03_Icon.visible = false; Bang04_Icon.visible = false; Bang05_Icon.visible = false; Bang06_Icon.visible = false; Hair01_Icon.visible = false; Hair02_Icon.visible = false; Hair03_Icon.visible = false; Hair04_Icon.visible = true; Hair05_Icon.visible = true; Hair06_Icon.visible = true; } } else if(openedMenu == 6) { openedMenuPage --; if(openedMenuPage < 1) { openedMenuPage = 2; } if(openedMenuPage == 1) { Lips01_Icon.visible = true; Lips02_Icon.visible = true; Lips03_Icon.visible = true; Lips04_Icon.visible = false; Lips05_Icon.visible = false; Lips06_Icon.visible = false; } if(openedMenuPage == 2) { Lips01_Icon.visible = false; Lips02_Icon.visible = false; Lips03_Icon.visible = false; Lips04_Icon.visible = true; Lips05_Icon.visible = true; Lips06_Icon.visible = true; } } else if(openedMenu == 8) { openedMenuPage --; if(openedMenuPage < 1) { openedMenuPage = 2; } if(openedMenuPage == 1) { Tops_Icon.visible = true; Tops_Icon2.visible = true; Tops_Icon3.visible = true; Tops_Icon4.visible = false; Tops_Icon5.visible = false; Tops_Icon6.visible = false; } if(openedMenuPage == 2) { Tops_Icon.visible = false; Tops_Icon2.visible = false; Tops_Icon3.visible = false; Tops_Icon4.visible = true; Tops_Icon5.visible = true; Tops_Icon6.visible = true; } } else if(openedMenu == 9) { openedMenuPage --; if(openedMenuPage < 1) { openedMenuPage = 2; } if(openedMenuPage == 1) { Bottoms_Icon.visible = true; Bottoms_Icon2.visible = true; Bottoms_Icon3.visible = true; Bottoms_Icon4.visible = false; Bottoms_Icon5.visible = false; Bottoms_Icon6.visible = false; } if(openedMenuPage == 2) { Bottoms_Icon.visible = false; Bottoms_Icon2.visible = false; Bottoms_Icon3.visible = false; Bottoms_Icon4.visible = true; Bottoms_Icon5.visible = true; Bottoms_Icon6.visible = true; } } else if(openedMenu == 10) { openedMenuPage --; if(openedMenuPage < 1) { openedMenuPage = 2; } if(openedMenuPage == 1) { Dress_Icon.visible = true; Dress_Icon2.visible = true; Dress_Icon3.visible = true; Dress_Icon4.visible = false; Dress_Icon5.visible = false; Dress_Icon6.visible = false; } if(openedMenuPage == 2) { Dress_Icon.visible = false; Dress_Icon2.visible = false; Dress_Icon3.visible = false; Dress_Icon4.visible = true; Dress_Icon5.visible = true; Dress_Icon6.visible = true; } } else if(openedMenu == 11) { openedMenuPage --; if(openedMenuPage < 1) { openedMenuPage = 2; } if(openedMenuPage == 1) { Shoes_Icon.visible = true; Shoes_Icon2.visible = true; Shoes_Icon3.visible = true; Shoes_Icon4.visible = false; Shoes_Icon5.visible = false; Shoes_Icon6.visible = false; } if(openedMenuPage == 2) { Shoes_Icon.visible = false; Shoes_Icon2.visible = false; Shoes_Icon3.visible = false; Shoes_Icon4.visible = true; Shoes_Icon5.visible = true; Shoes_Icon6.visible = true; } } else if(openedMenu == 12) { openedMenuPage --; if(openedMenuPage < 1) { openedMenuPage = 2; } if(openedMenuPage == 1) { Socks_Icon.visible = true; Socks_Icon2.visible = true; Socks_Icon3.visible = true; Socks_Icon4.visible = false; Socks_Icon5.visible = false; Socks_Icon6.visible = false; } if(openedMenuPage == 2) { Socks_Icon.visible = false; Socks_Icon2.visible = false; Socks_Icon3.visible = false; Socks_Icon4.visible = true; Socks_Icon5.visible = true; Socks_Icon6.visible = true; } } else if(openedMenu == 13) { openedMenuPage --; if(openedMenuPage < 1) { openedMenuPage = 2; } if(openedMenuPage == 1) { Extra_Icon.visible = true; Extra_Icon2.visible = true; Extra_Icon3.visible = true; Extra_Icon4.visible = false; Extra_Icon5.visible = false; Extra_Icon6.visible = false; /*Extra_Icon7.visible = false; Extra_Icon8.visible = false; Extra_Icon9.visible = false; Extra_Icon10.visible = false; Extra_Icon11.visible = false; Extra_Icon12.visible = false;*/ } if(openedMenuPage == 2) { Extra_Icon.visible = false; Extra_Icon2.visible = false; Extra_Icon3.visible = false; Extra_Icon4.visible = true; Extra_Icon5.visible = true; Extra_Icon6.visible = true; /*Extra_Icon7.visible = false; Extra_Icon8.visible = false; Extra_Icon9.visible = false;*/ } /*if(openedMenuPage == 3) { Extra_Icon.visible = false; Extra_Icon2.visible = false; Extra_Icon3.visible = false; Extra_Icon4.visible = false; Extra_Icon5.visible = false; Extra_Icon6.visible = false; Extra_Icon7.visible = true; Extra_Icon8.visible = true; Extra_Icon9.visible = true; Extra_Icon10.visible = false; Extra_Icon11.visible = false; Extra_Icon12.visible = false; } if(openedMenuPage == 4) { Extra_Icon.visible = false; Extra_Icon2.visible = false; Extra_Icon3.visible = false; Extra_Icon4.visible = false; Extra_Icon5.visible = false; Extra_Icon6.visible = false; Extra_Icon7.visible = false; Extra_Icon8.visible = false; Extra_Icon9.visible = false; Extra_Icon10.visible = true; Extra_Icon11.visible = true; Extra_Icon12.visible = true; }*/ } else if(openedMenu == 14) { openedMenuPage --; if(openedMenuPage < 1) { openedMenuPage = 2; } if(openedMenuPage == 1) { Cake_Icon.visible = true; Cake_Icon2.visible = true; Cake_Icon3.visible = true; Cake_Icon4.visible = false; Cake_Icon5.visible = false; Cake_Icon6.visible = false; } if(openedMenuPage == 2) { Cake_Icon.visible = false; Cake_Icon2.visible = false; Cake_Icon3.visible = false; Cake_Icon4.visible = true; Cake_Icon5.visible = true; Cake_Icon6.visible = true; } } },this); Color_Btn = this.add.button(624,479,"color_btn",function() { Color_Btn.visible = false; Next_Btn.visible = false; Prev_Btn.visible = false; Trash_Btn.visible = false; Color_Group.visible = true; Color_Pallette.visible = true; Color_Pallette2.visible = false; colorPage = 1; Color_Prev.x = 672; Color_Prev.y = 480; Color_Next.x = Color_Prev.x + Color_Prev.width + 22; Color_Next.y = Color_Prev.y; if(openedMenu == 1){Hair_Menu_Group.visible = false;} if(openedMenu == 3){Eyes_Menu_Group.visible = false;} if(openedMenu == 6){Lips_Menu_Group.visible = false;} if(openedMenu == 8){Tops_Menu_Group.visible = false;} if(openedMenu == 9){Bottoms_Menu_Group.visible = false;} if(openedMenu == 10){Dress_Menu_Group.visible = false;} if(openedMenu == 11){Shoes_Menu_Group.visible = false;} if(openedMenu == 12){Socks_Menu_Group.visible = false;} if(openedMenu == 13){Extra_Menu_Group.visible = false;} if(openedMenu == 14){Cake_Menu_Group.visible = false;} },this,1,0,2); Color_Btn.anchor.setTo(0.5,0.5); Trash_Btn = this.add.button(816,Color_Prev.y,"trash_btn",function() { if(openedMenu == 1) { /*Bangs.frame = 4; Bangs_Outline.frame = Bangs.frame; Bangs.tint = Colors[10]*/ Hair.frame = 0; Hair_Outline.frame = Hair.frame; Hair.tint = Colors2[24]; hairColor = 44; //Bang_Hl.frame = Bangs.frame; Hair_Hl.frame = Hair.frame; /*Hair_Hl.x = Hair_HlX[Hair_Hl.frame]; Hair_Hl.y = Hair_HlY[Hair_Hl.frame];*/ } else if(openedMenu == 2) { //Bang_Hl.visible = false; Hair_Hl.visible = false; hlVisible = false; } else if(openedMenu == 3) { Eyes.tint = Colors[0]; Eyes.frame = 0; Eyes_White.frame = Eyes.frame; Eye_Shadow.frame = Eyes.frame; } else if(openedMenu == 4) { //Eye_Shadow.visible = false; Eyebrows.frame = 0; Eyebrows.x = EyebrowX[0]; Eyebrows.y = EyebrowY[0]; } else if(openedMenu == 5) { Eye_Shadow.visible = false; } else if(openedMenu == 6) { Lips.frame = 0; //Lips_Outline.frame = 0; //Lips.tint = Colors[8] } else if(openedMenu == 7) { Head.tint = BodyColor2[9]; Body.tint = BodyColor2[9]; } else if(openedMenu == 8) { Clothes.visible = false; Clothes_Outline.visible = false; Bra.visible = true; if(!Bottoms.visible){Panties.visible = true;} } else if(openedMenu == 9) { Bottoms.visible = false; Bottoms_Outline.visible = false; Panties.visible = true; } else if(openedMenu == 10) { Clothes.visible = false; Clothes_Outline.visible = false; Bra.visible = true; if(!Bottoms.visible){Panties.visible = true;} } else if(openedMenu == 11) { Shoes.visible = false; Shoes_Outline.visible = false; } else if(openedMenu == 12) { Socks.visible = false; Socks_Outline.visible = false; if(Clothes.frame <= 5){Panties.visible = true;} else{Panties.visible = false;} } else if(openedMenu == 13) { Extra.visible = false; Extra_Outline.visible = false; Extra2.visible = false; Extra2_Outline.visible = false; Extra3.visible = false; Extra3_Outline.visible = false; Extra4.visible = false; Extra4_Outline.visible = false; Extra5.visible = false; Extra5_Outline.visible = false; Extra6.visible = false; Extra6_Outline.visible = false; } else if(openedMenu == 14) { BG.visible = false; BG2.visible = false; BG3.visible = false; } },this,1,0,2); Trash_Btn.anchor.setTo(0.5,0.5); //Left Side Buttons Hair_Btn = this.add.button(515,55,"hair_btn",function() { openedMenu = 1; openedMenuPage = 1; Next_Btn.visible = true; Prev_Btn.visible = true; Color_Btn.visible = true; Trash_Btn.visible = true; Trash_Btn.x = 816; Hair_Menu_Group.visible = true; Hair_Menu_Group.setAll("visible",false); /*Bang01_Icon.visible = true; Bang02_Icon.visible = true; Bang03_Icon.visible = true;*/ Hair01_Icon.visible = true; Hair02_Icon.visible = true; Hair03_Icon.visible = true; //Eyeshadow_Color_Group.visible = false; Eyebrows_Menu_Group.visible = false; Lips_Menu_Group.visible = false; SkinColor_Menu_Group.visible = false; Tops_Menu_Group.visible = false; Bottoms_Menu_Group.visible = false; Dress_Menu_Group.visible = false; Shoes_Menu_Group.visible = false; Socks_Menu_Group.visible = false; Extra_Menu_Group.visible = false; Cake_Menu_Group.visible = false; Eyes_Menu_Group.visible = false; Color_Group.visible = false; colorPage = 1; },this,1,0,2); Hair_Btn.anchor.setTo(0.5,0.5); Hair_Btn.input.pixelPerfectClick = true; Hair_Btn.input.pixelPerfectOver = true; Hl_Btn = this.add.button(Hair_Btn.x,Hair_Btn.y + Hair_Btn.height + 16,"hl_btn",function() { openedMenu = 2; openedMenuPage = 1; Next_Btn.visible = false; Prev_Btn.visible = false; Hair_Menu_Group.visible = false; Color_Btn.visible = false; Color_Group.visible = true; colorPage = 1; Color_Pallette.visible = true; Color_Pallette2.visible = false; Trash_Btn.x = 722; Trash_Btn.visible = true; Color_Prev.x = 615; Color_Next.x = 811; //Eyeshadow_Color_Group.visible = false; Eyebrows_Menu_Group.visible = false; Lips_Menu_Group.visible = false; SkinColor_Menu_Group.visible = false; Tops_Menu_Group.visible = false; Bottoms_Menu_Group.visible = false; Dress_Menu_Group.visible = false; Shoes_Menu_Group.visible = false; Socks_Menu_Group.visible = false; Extra_Menu_Group.visible = false; Cake_Menu_Group.visible = false; Eyes_Menu_Group.visible = false; },this,1,0,2); Hl_Btn.anchor.setTo(0.5,0.5); Hl_Btn.input.pixelPerfectClick = true; Hl_Btn.input.pixelPerfectOver = true; Eye_Btn = this.add.button(Hair_Btn.x,Hl_Btn.y + Hl_Btn.height + 16,"eye_btn",function() { openedMenu = 3; Next_Btn.visible = false; Prev_Btn.visible = false; Color_Btn.visible = true; Trash_Btn.visible = true; Trash_Btn.x = 816; Eyes_Menu_Group.visible = true; Hair_Menu_Group.visible = false; //Eyeshadow_Color_Group.visible = false; Eyebrows_Menu_Group.visible = false; Lips_Menu_Group.visible = false; SkinColor_Menu_Group.visible = false; Tops_Menu_Group.visible = false; Bottoms_Menu_Group.visible = false; Dress_Menu_Group.visible = false; Shoes_Menu_Group.visible = false; Socks_Menu_Group.visible = false; Extra_Menu_Group.visible = false; Cake_Menu_Group.visible = false; Color_Group.visible = false; },this,1,0,2); Eye_Btn.anchor.setTo(0.5,0.5); Eye_Btn.input.pixelPerfectClick = true; Eye_Btn.input.pixelPerfectOver = true; Eyebrows_Btn = this.add.button(Eye_Btn.x - 7,Eye_Btn.y + Eye_Btn.height + 16,"eyebrow_btn",function() { openedMenu = 4; Next_Btn.visible = false; Prev_Btn.visible = false; Color_Btn.visible = false; Trash_Btn.visible = true; Trash_Btn.x = 816; Lips_Menu_Group.visible = false; Eyebrows_Menu_Group.visible = true; //Eyeshadow_Color_Group.visible = false; Hair_Menu_Group.visible = false; Color_Group.visible = false; SkinColor_Menu_Group.visible = false; Tops_Menu_Group.visible = false; Bottoms_Menu_Group.visible = false; Dress_Menu_Group.visible = false; Shoes_Menu_Group.visible = false; Socks_Menu_Group.visible = false; Extra_Menu_Group.visible = false; Cake_Menu_Group.visible = false; Eyes_Menu_Group.visible = false; },this,1,0,2); Eyebrows_Btn.anchor.setTo(0.5,0.5); Eye_Shadow_Btn = this.add.button(Eyebrows_Btn.x,Eyebrows_Btn.y + Eyebrows_Btn.height + 16,"eyeshadow_btn",function() { openedMenu = 5; Next_Btn.visible = false; Prev_Btn.visible = false; Hair_Menu_Group.visible = false; Color_Btn.visible = false; Color_Group.visible = true; colorPage = 1; Color_Pallette.visible = true; Color_Pallette2.visible = false; Trash_Btn.x = 722; Trash_Btn.visible = true; Color_Prev.x = 615; Color_Next.x = 811; //Eyeshadow_Color_Group.visible = true; Eyebrows_Menu_Group.visible = false; Lips_Menu_Group.visible = false; SkinColor_Menu_Group.visible = false; Tops_Menu_Group.visible = false; Bottoms_Menu_Group.visible = false; Dress_Menu_Group.visible = false; Shoes_Menu_Group.visible = false; Socks_Menu_Group.visible = false; Extra_Menu_Group.visible = false; Cake_Menu_Group.visible = false; Eyes_Menu_Group.visible = false; },this,1,0,2); Eye_Shadow_Btn.anchor.setTo(0.5,0.5); Eye_Shadow_Btn.input.pixelPerfectClick = true; Eye_Shadow_Btn.input.pixelPerfectOver = true; Lips_Btn = this.add.button(Eye_Shadow_Btn.x,Eye_Shadow_Btn.y + Eye_Shadow_Btn.height + 16,"lips_btn",function() { openedMenu = 6; openedMenuPage = 1; Next_Btn.visible = true; Prev_Btn.visible = true; Color_Btn.visible = false; Trash_Btn.visible = true; Trash_Btn.x = 816; Lips_Menu_Group.visible = true; Lips_Menu_Group.setAll("visible",false); Lips01_Icon.visible = true; Lips02_Icon.visible = true; Lips03_Icon.visible = true; //Eyeshadow_Color_Group.visible = false; Eyebrows_Menu_Group.visible = false; Hair_Menu_Group.visible = false; Color_Group.visible = false; SkinColor_Menu_Group.visible = false; Tops_Menu_Group.visible = false; Bottoms_Menu_Group.visible = false; Dress_Menu_Group.visible = false; Shoes_Menu_Group.visible = false; Socks_Menu_Group.visible = false; Extra_Menu_Group.visible = false; Cake_Menu_Group.visible = false; Eyes_Menu_Group.visible = false; },this,1,0,2); Lips_Btn.anchor.setTo(0.5,0.5); Lips_Btn.input.pixelPerfectClick = true; Lips_Btn.input.pixelPerfectOver = true; SkinTone_Btn = this.add.button(Lips_Btn.x + 7,Lips_Btn.y + Lips_Btn.height + 14,"skintone_btn",function() { openedMenu = 7; Next_Btn.visible = false; Prev_Btn.visible = false; Trash_Btn.x = 720; Trash_Btn.visible = true; Hair_Menu_Group.visible = false; Color_Group.visible = false; Color_Btn.visible = false; //Eyeshadow_Color_Group.visible = false; Eyebrows_Menu_Group.visible = false; Hair_Menu_Group.visible = false; Color_Group.visible = false; Lips_Menu_Group.visible = false; SkinColor_Menu_Group.visible = true; Tops_Menu_Group.visible = false; Bottoms_Menu_Group.visible = false; Dress_Menu_Group.visible = false; Shoes_Menu_Group.visible = false; Socks_Menu_Group.visible = false; Extra_Menu_Group.visible = false; Cake_Menu_Group.visible = false; Eyes_Menu_Group.visible = false; },this,1,0,2); SkinTone_Btn.anchor.setTo(0.5,0.5); SkinTone_Btn.input.pixelPerfectClick = true; SkinTone_Btn.input.pixelPerfectOver = true; //Right Side Buttons Tops_Btn = this.add.button(925,Hair_Btn.y,"tops_btn",function() { openedMenu = 8; openedMenuPage = 1; Next_Btn.visible = true; Prev_Btn.visible = true; Color_Btn.visible = true; Trash_Btn.visible = true; Trash_Btn.x = 816; Tops_Menu_Group.visible = true; Tops_Menu_Group.setAll("visible",false); Tops_Icon.visible = true; Tops_Icon2.visible = true; Tops_Icon3.visible = true; //Eyeshadow_Color_Group.visible = false; Eyebrows_Menu_Group.visible = false; Hair_Menu_Group.visible = false; Color_Group.visible = false; Lips_Menu_Group.visible = false; SkinColor_Menu_Group.visible = false; Bottoms_Menu_Group.visible = false; Dress_Menu_Group.visible = false; Shoes_Menu_Group.visible = false; Socks_Menu_Group.visible = false; Extra_Menu_Group.visible = false; Cake_Menu_Group.visible = false; Eyes_Menu_Group.visible = false; },this,1,0,2); Tops_Btn.anchor.setTo(0.5,0.5); Tops_Btn.input.pixelPerfectClick = true; Tops_Btn.input.pixelPerfectOver = true; Bottoms_Btn = this.add.button(Tops_Btn.x,Tops_Btn.y + Tops_Btn.height + 16,"bottoms_btn",function() { openedMenu = 9; openedMenuPage = 1; Next_Btn.visible = true; Prev_Btn.visible = true; Color_Btn.visible = true; Trash_Btn.visible = true; Trash_Btn.x = 816; Bottoms_Menu_Group.visible = true; Bottoms_Menu_Group.setAll("visible",false); Bottoms_Icon.visible = true; Bottoms_Icon2.visible = true; Bottoms_Icon3.visible = true; //Eyeshadow_Color_Group.visible = false; Eyebrows_Menu_Group.visible = false; Hair_Menu_Group.visible = false; Color_Group.visible = false; Lips_Menu_Group.visible = false; SkinColor_Menu_Group.visible = false; Tops_Menu_Group.visible = false; Dress_Menu_Group.visible = false; Shoes_Menu_Group.visible = false; Socks_Menu_Group.visible = false; Extra_Menu_Group.visible = false; Cake_Menu_Group.visible = false; Eyes_Menu_Group.visible = false; },this,1,0,2); Bottoms_Btn.anchor.setTo(0.5,0.5); Bottoms_Btn.input.pixelPerfectClick = true; Bottoms_Btn.input.pixelPerfectOver = true; Dress_Btn = this.add.button(Bottoms_Btn.x - 7,Bottoms_Btn.y + Bottoms_Btn.height + 16,"dress_btn",function() { openedMenu = 10; openedMenuPage = 1; Next_Btn.visible = true; Prev_Btn.visible = true; Color_Btn.visible = true; Trash_Btn.visible = true; Trash_Btn.x = 816; Dress_Menu_Group.visible = true; Dress_Menu_Group.setAll("visible",false); Dress_Icon.visible = true; Dress_Icon2.visible = true; Dress_Icon3.visible = true; //Eyeshadow_Color_Group.visible = false; Eyebrows_Menu_Group.visible = false; Hair_Menu_Group.visible = false; Color_Group.visible = false; Lips_Menu_Group.visible = false; SkinColor_Menu_Group.visible = false; Tops_Menu_Group.visible = false; Bottoms_Menu_Group.visible = false; Shoes_Menu_Group.visible = false; Socks_Menu_Group.visible = false; Extra_Menu_Group.visible = false; Cake_Menu_Group.visible = false; Eyes_Menu_Group.visible = false; },this,1,0,2); Dress_Btn.anchor.setTo(0.5,0.5); Dress_Btn.input.pixelPerfectClick = true; Dress_Btn.input.pixelPerfectOver = true; Shoes_Btn = this.add.button(Dress_Btn.x,Dress_Btn.y + Dress_Btn.height + 16,"shoes_btn",function() { openedMenu = 11; openedMenuPage = 1; Next_Btn.visible = true; Prev_Btn.visible = true; Color_Btn.visible = true; Trash_Btn.visible = true; Trash_Btn.x = 816; Shoes_Menu_Group.visible = true; Shoes_Menu_Group.setAll("visible",false); Shoes_Icon.visible = true; Shoes_Icon2.visible = true; Shoes_Icon3.visible = true; //Eyeshadow_Color_Group.visible = false; Eyebrows_Menu_Group.visible = false; Hair_Menu_Group.visible = false; Color_Group.visible = false; Lips_Menu_Group.visible = false; SkinColor_Menu_Group.visible = false; Tops_Menu_Group.visible = false; Bottoms_Menu_Group.visible = false; Dress_Menu_Group.visible = false; Socks_Menu_Group.visible = false; Extra_Menu_Group.visible = false; Cake_Menu_Group.visible = false; Eyes_Menu_Group.visible = false; },this,1,0,2); Shoes_Btn.anchor.setTo(0.5,0.5); Shoes_Btn.input.pixelPerfectClick = true; Shoes_Btn.input.pixelPerfectOver = true; Socks_Btn = this.add.button(Shoes_Btn.x + 7,Shoes_Btn.y + Shoes_Btn.height + 16,"socks_btn",function() { openedMenu = 12; openedMenuPage = 1; Next_Btn.visible = true; Prev_Btn.visible = true; Color_Btn.visible = true; Trash_Btn.visible = true; Trash_Btn.x = 816; Socks_Menu_Group.visible = true; Socks_Menu_Group.setAll("visible",false); Socks_Icon.visible = true; Socks_Icon2.visible = true; Socks_Icon3.visible = true; //Eyeshadow_Color_Group.visible = false; Eyebrows_Menu_Group.visible = false; Hair_Menu_Group.visible = false; Color_Group.visible = false; Lips_Menu_Group.visible = false; SkinColor_Menu_Group.visible = false; Tops_Menu_Group.visible = false; Bottoms_Menu_Group.visible = false; Dress_Menu_Group.visible = false; Shoes_Menu_Group.visible = false; Extra_Menu_Group.visible = false; Cake_Menu_Group.visible = false; Eyes_Menu_Group.visible = false; },this,1,0,2); Socks_Btn.anchor.setTo(0.5,0.5); Socks_Btn.input.pixelPerfectClick = true; Socks_Btn.input.pixelPerfectOver = true; Extra_Btn = this.add.button(Socks_Btn.x,Socks_Btn.y + Socks_Btn.height + 16,"extra_btn",function() { openedMenu = 13; openedMenuPage = 1; Next_Btn.visible = true; Prev_Btn.visible = true; Color_Btn.visible = true; Trash_Btn.visible = true; Trash_Btn.x = 816; Extra_Menu_Group.visible = true; Extra_Menu_Group.setAll("visible",false); Extra_Icon.visible = true; Extra_Icon2.visible = true; Extra_Icon3.visible = true; //Eyeshadow_Color_Group.visible = false; Eyebrows_Menu_Group.visible = false; Hair_Menu_Group.visible = false; Color_Group.visible = false; Lips_Menu_Group.visible = false; SkinColor_Menu_Group.visible = false; Tops_Menu_Group.visible = false; Bottoms_Menu_Group.visible = false; Dress_Menu_Group.visible = false; Shoes_Menu_Group.visible = false; Socks_Menu_Group.visible = false; Cake_Menu_Group.visible = false; Eyes_Menu_Group.visible = false; },this,1,0,2); Extra_Btn.anchor.setTo(0.5,0.5); Extra_Btn.input.pixelPerfectClick = true; Extra_Btn.input.pixelPerfectOver = true; Cake_Btn = this.add.button(Extra_Btn.x - 7,Extra_Btn.y + Extra_Btn.height + 16,"bg_btn",function() { openedMenu = 14; openedMenuPage = 1; Next_Btn.visible = false; Prev_Btn.visible = false; Color_Btn.visible = false; Trash_Btn.visible = true; Trash_Btn.x = 816; Cake_Menu_Group.visible = true; Cake_Menu_Group.setAll("visible",false); Cake_Icon.visible = true; Cake_Icon2.visible = true; Cake_Icon3.visible = true; //Eyeshadow_Color_Group.visible = false; Extra_Menu_Group.visible = false; Eyebrows_Menu_Group.visible = false; Hair_Menu_Group.visible = false; Color_Group.visible = false; Lips_Menu_Group.visible = false; SkinColor_Menu_Group.visible = false; Tops_Menu_Group.visible = false; Bottoms_Menu_Group.visible = false; Dress_Menu_Group.visible = false; Shoes_Menu_Group.visible = false; Socks_Menu_Group.visible = false; Eyes_Menu_Group.visible = false; },this,1,0,2); Cake_Btn.anchor.setTo(0.5,0.5); Cake_Btn.input.pixelPerfectClick = true; Cake_Btn.input.pixelPerfectOver = true; //Bottom Buttons Shuffle_Btn = this.add.button(615,593,"shuffle_btn",function() { this.Shuffle_Items(); },this,1,0,2); Shuffle_Btn.anchor.setTo(0.5,0.5); Show_Btn = this.add.button(Shuffle_Btn.x + Shuffle_Btn.width + 17,592,"show_btn",function() { Border.visible = false; Hair_Btn.visible = false; Hl_Btn.visible = false; Eye_Btn.visible = false; Eyebrows_Btn.visible = false; Eye_Shadow_Btn.visible = false; Lips_Btn.visible = false; SkinTone_Btn.visible = false; Tops_Btn.visible = false; Bottoms_Btn.visible = false; Dress_Btn.visible = false; Shoes_Btn.visible = false; Socks_Btn.visible = false; Extra_Btn.visible = false; Cake_Btn.visible = false; Color_Btn.visible = false; Trash_Btn.visible = false; Next_Btn.visible = false; Prev_Btn.visible = false; Shuffle_Btn.visible = false; Show_Btn.visible = false; Reset_Btn.visible = false; Retry_Btn.visible = true; Save_Btn.visible = true; MoreGames_Btn.visible = true; End_Logo.visible = true; Logo.visible = false; //openedMenu == 1 Hair_Menu_Group.visible = false; Color_Group.visible = false; //openedMenu == 2 //Hl_Color_Group.visible = false; //openedMenu == 3 //openedMenu == 4 //Eyeshadow_Color_Group.visible = false; Eyebrows_Menu_Group.visible = false; //openedMenu == 5 Lips_Menu_Group.visible = false; //openedMenu == 6 SkinColor_Menu_Group.visible = false; //openedMenu == 7 Tops_Menu_Group.visible = false; //openedMenu == 8 Bottoms_Menu_Group.visible = false; //openedMenu == 9 Dress_Menu_Group.visible = false; //openedMenu == 10 Shoes_Menu_Group.visible = false; //openedMenu == 11 Socks_Menu_Group.visible = false; //openedMenu == 12 Extra_Menu_Group.visible = false; Cake_Menu_Group.visible = false; Eyes_Menu_Group.visible = false; Doll_Group.x = 217; Doll_Group.y = -2; },this,1,0,2); Show_Btn.anchor.setTo(0.5,0.5); Reset_Btn = this.add.button(Show_Btn.x + Show_Btn.width + 5,Show_Btn.y,"reset_btn",function() { Bra.visible = true; Panties.visible = true; /*Bangs.frame = 4; Bangs_Outline.frame = Bangs.frame; Bangs.tint = Colors[10]*/ Hair.frame = 0; Hair_Outline.frame = Hair.frame; Hair.tint = Colors2[24]; hairColor = 44; //Bang_Hl.frame = Bangs.frame; Hair_Hl.frame = Hair.frame; /*Hair_Hl.x = Hair_HlX[Hair_Hl.frame]; Hair_Hl.y = Hair_HlY[Hair_Hl.frame];*/ //Bang_Hl.visible = false; Hair_Hl.visible = false; hlVisible = false; Eyes.tint = Colors[0]; Eyes.frame = 0; Eyes_White.frame = Eyes.frame; Eye_Shadow.frame = Eyes.frame; Eyebrows.frame = 0; Eyebrows.x = EyebrowX[0]; Eyebrows.y = EyebrowY[0]; Eye_Shadow.visible = false; Lips.frame = 0; Head.tint = BodyColor2[9]; Body.tint = BodyColor2[9]; Clothes.visible = false; Clothes_Outline.visible = false; Bottoms.visible = false; Bottoms_Outline.visible = false; Clothes.visible = false; Clothes_Outline.visible = false; Shoes.visible = false; Shoes_Outline.visible = false; Socks.visible = false; Socks_Outline.visible = false; Extra.visible = false; Extra_Outline.visible = false; Extra2.visible = false; Extra2_Outline.visible = false; Extra3.visible = false; Extra3_Outline.visible = false; Extra4.visible = false; Extra4_Outline.visible = false; Extra5.visible = false; Extra5_Outline.visible = false; Extra6.visible = false; Extra6_Outline.visible = false; BG.visible = false; BG2.visible = false; BG3.visible = false; },this,1,0,2); Reset_Btn.anchor.setTo(0.5,0.5); //End Screen Buttons Retry_Btn = this.add.button(926,448,"retry_btn",function() { Border.visible = true; Hair_Btn.visible = true; Hl_Btn.visible = true; Eye_Btn.visible = true; Eyebrows_Btn.visible = true; Eye_Shadow_Btn.visible = true; Lips_Btn.visible = true; SkinTone_Btn.visible = true; Tops_Btn.visible = true; Bottoms_Btn.visible = true; Dress_Btn.visible = true; Shoes_Btn.visible = true; Socks_Btn.visible = true; Extra_Btn.visible = true; Cake_Btn.visible = true; Color_Btn.visible = true; Next_Btn.visible = true; Prev_Btn.visible = true; Trash_Btn.visible = true; Shuffle_Btn.visible = true; Show_Btn.visible = true; Reset_Btn.visible = true; Retry_Btn.visible = false; Save_Btn.visible = false; MoreGames_Btn.visible = false; End_Logo.visible = false; Logo.visible = true; openedMenu = 1; openedMenuPage = 1; colorPage = 1; Next_Btn.visible = true; Prev_Btn.visible = true; Color_Btn.visible = true; Trash_Btn.x = 816; Hair_Menu_Group.visible = true; Hair_Menu_Group.setAll("visible",false); /*Bang01_Icon.visible = true; Bang02_Icon.visible = true; Bang03_Icon.visible = true;*/ Hair01_Icon.visible = true; Hair02_Icon.visible = true; Hair03_Icon.visible = true; Color_Group.visible = false; Eyebrows_Menu_Group.visible = false; Lips_Menu_Group.visible = false; SkinColor_Menu_Group.visible = false; Tops_Menu_Group.visible = false; Bottoms_Menu_Group.visible = false; Dress_Menu_Group.visible = false; Shoes_Menu_Group.visible = false; Socks_Menu_Group.visible = false; Extra_Menu_Group.visible = false; Cake_Menu_Group.visible = false; Eyes_Menu_Group.visible = false; Doll_Group.x = 0; Doll_Group.y = 1; },this,1,0,2); Retry_Btn.anchor.setTo(0.5,0.5); Retry_Btn.visible = false; Save_Btn = this.add.button(Retry_Btn.x,Retry_Btn.y + Retry_Btn.height,"save_btn",function() { this.SaveScreenshot(); },this,1,0,2); Save_Btn.anchor.setTo(0.5,0.5); Save_Btn.visible = false; MoreGames_Btn = this.add.button(Save_Btn.x,Save_Btn.y + Save_Btn.height,"moregames_btn",function() { window.open("http://www.kawaiigames.net/exclusive-games","_blank"); },this,1,0,2); MoreGames_Btn.anchor.setTo(0.5,0.5); MoreGames_Btn.visible = false; End_Logo = this.add.button(893,78,"logo",function() { window.open("http://www.kawaiigames.net/?utm_source="+ GameTitle + "&utm_medium=html5game","_blank"); },this,1,0,2); End_Logo.anchor.setTo(0.5,0.5); End_Logo.scale.setTo(1.2,1.2); End_Logo.smoothed = false; End_Logo.visible = false; Logo = this.add.button(76,548,"logo",function() { window.open("http://www.kawaiigames.net/?utm_source="+ GameTitle + "&utm_medium=html5game","_blank"); },this,1,0,2); Logo.anchor.setTo(0.5,0.5); Logo.scale.setTo(0.7,0.7); Credits_Btn = this.add.button(0,0,"credits_btn",function() { //hide the Credits_Btn Credits_Btn.visible = false; //make the Credits_Group visible Credits_Group.visible = true; //disable all buttons that is not meant to be clickable when Credits shows up Hair_Btn.inputEnabled = false; Hl_Btn.inputEnabled = false; Eye_Btn.inputEnabled = false; Eyebrows_Btn.inputEnabled = false; Eye_Shadow_Btn.inputEnabled = false; Lips_Btn.inputEnabled = false; SkinTone_Btn.inputEnabled = false; Tops_Btn.inputEnabled = false; Bottoms_Btn.inputEnabled = false; Dress_Btn.inputEnabled = false; Shoes_Btn.inputEnabled = false; Socks_Btn.inputEnabled = false; Extra_Btn.inputEnabled = false; Cake_Btn.inputEnabled = false; Color_Btn.inputEnabled = false; Next_Btn.inputEnabled = false; Prev_Btn.inputEnabled = false; Trash_Btn.inputEnabled = false; Shuffle_Btn.inputEnabled = false; Show_Btn.inputEnabled = false; Reset_Btn.inputEnabled = false; Next_Btn.inputEnabled = false; Prev_Btn.inputEnabled = false; Logo.inputEnabled = false; End_Logo.inputEnabled = false; Retry_Btn.inputEnabled = false; Save_Btn.inputEnabled = false; MoreGames_Btn.inputEnabled = false; Hair_Menu_Group.setAll("inputEnabled",false); Color_Group.setAll("inputEnabled",false); //Eyeshadow_Color_Group.setAll("inputEnabled",false); Eyebrows_Menu_Group.setAll("inputEnabled",false); Lips_Menu_Group.setAll("inputEnabled",false); SkinColor_Menu_Group.setAll("inputEnabled",false); Tops_Menu_Group.setAll("inputEnabled",false); Bottoms_Menu_Group.setAll("inputEnabled",false); Dress_Menu_Group.setAll("inputEnabled",false); Shoes_Menu_Group.setAll("inputEnabled",false); Socks_Menu_Group.setAll("inputEnabled",false); Extra_Menu_Group.setAll("inputEnabled",false); Cake_Menu_Group.setAll("inputEnabled",false); Eyes_Menu_Group.setAll("inputEnabled",false); },this,1,0,2); Credits_Btn.anchor.setTo(0.5,0.5); Credits_Btn.x = 75; Credits_Btn.y = 614; //---------------------------------------------------------// //Credits Screen //Screen_Effect (black screen at the back of the credits screen) //the first 0 is the x and the second 0 is the y Screen_Effect = this.add.sprite(0,0,"screen_effect"); //Credits_Text includes the credits text and the pink border Credits_Text = this.add.sprite(0,0,"credits_text"); Credits_Text.anchor.setTo(0.5,0.5); Credits_Text.x = CenterX; Credits_Text.y = CenterY; Link_Btn = this.add.button(591,303,"link_btn",function() { window.open("http://cartoonnetwork.com","_blank"); },this); Link_Btn.anchor.setTo(0.5,0.5); Link_Btn.scale.setTo(2.7,0.3); Link_Btn.alpha = 0; //Close button at the upper right corner of the Credits_Text /*We add it as a sprite so that we can make it zoom in and zoom out by scaling it when the user click the close button*/ Close_Btn = this.add.button(0,0,"close_btn",function() { //we make the Credits_Group invisible and the Credits_Btn visible again Credits_Group.visible = false; Credits_Btn.visible = true; //enable all buttons that is meant to be clickable when Credits is closed Hair_Btn.inputEnabled = true; Hl_Btn.inputEnabled = true; Eye_Btn.inputEnabled = true; Eyebrows_Btn.inputEnabled = true; Eye_Shadow_Btn.inputEnabled = true; Lips_Btn.inputEnabled = true; SkinTone_Btn.inputEnabled = true; Tops_Btn.inputEnabled = true; Bottoms_Btn.inputEnabled = true; Dress_Btn.inputEnabled = true; Shoes_Btn.inputEnabled = true; Socks_Btn.inputEnabled = true; Extra_Btn.inputEnabled = true; Cake_Btn.inputEnabled = true; Color_Btn.inputEnabled = true; Next_Btn.inputEnabled = true; Prev_Btn.inputEnabled = true; Trash_Btn.inputEnabled = true; Shuffle_Btn.inputEnabled = true; Show_Btn.inputEnabled = true; Reset_Btn.inputEnabled = true; Next_Btn.inputEnabled = true; Prev_Btn.inputEnabled = true; Logo.inputEnabled = true; End_Logo.inputEnabled = true; Retry_Btn.inputEnabled = true; Save_Btn.inputEnabled = true; MoreGames_Btn.inputEnabled = true; Hair_Menu_Group.setAll("inputEnabled",true); Color_Group.setAll("inputEnabled",true); Eyebrows_Menu_Group.setAll("inputEnabled",true); Lips_Menu_Group.setAll("inputEnabled",true); SkinColor_Menu_Group.setAll("inputEnabled",true); Tops_Menu_Group.setAll("inputEnabled",true); Bottoms_Menu_Group.setAll("inputEnabled",true); Dress_Menu_Group.setAll("inputEnabled",true); Shoes_Menu_Group.setAll("inputEnabled",true); Socks_Menu_Group.setAll("inputEnabled",true); Extra_Menu_Group.setAll("inputEnabled",true); Cake_Menu_Group.setAll("inputEnabled",true); Eyes_Menu_Group.setAll("inputEnabled",true); },this,1,0,2); Close_Btn.anchor.setTo(0.5,0.5); Close_Btn.x = 876; Close_Btn.y = 91; //Group that will hold all the graphics that we need for the credits screen Credits_Group = this.add.group(); Credits_Group.add(Screen_Effect); Credits_Group.add(Credits_Text); Credits_Group.add(Link_Btn); Credits_Group.add(Close_Btn); //we make it initially invisible to hide it from the users view Credits_Group.visible = false; //-----------------------------------------------------------// //Soundbtn SoundBtn = this.add.button(46,42,"sound_btn", function() { if(!MuteBool) { SoundBtn.animations.play("soundOff"); this.sound.mute = true; MuteBool = true; } else if(MuteBool) { SoundBtn.animations.play("soundOn"); this.sound.mute = false; MuteBool = false; } },this); SoundBtn.anchor.setTo(0.5,0.5); SoundBtn.animations.add("soundOn",[0],1,false); SoundBtn.animations.add("soundOff",[1],1,false); if(!MuteBool) { SoundBtn.animations.play("soundOn"); } else if(MuteBool) { SoundBtn.animations.play("soundOff"); } //--------------------------------------------------------------------------// PosTextBool = false; /*PosTextBool = true; PosText = this.add.text(870,110,"Hello",{font:"40px Arial",fill:"#ffffff"}); PosText.anchor.setTo(0.5,0.5); PosText.setShadow(3,3,"rgba(0,0,0,0.5)",2); debug_fnc(PosText);*/ }, buttonUp_fnc: function(buttonObj) { buttonObj.events.onInputUp.add(function(){buttonObj.frame = 0;},this); }, buttonDown_fnc: function(buttonObj) { buttonObj.events.onInputDown.add(function(){buttonObj.frame = 1;},this); }, SaveScreenshot: function() { /*We set all of this buttons visibility to false so that when the game makes a screenshot, there are no buttons in it*/ Credits_Btn.visible = false; Retry_Btn.visible = false; Save_Btn.visible = false; MoreGames_Btn.visible = false; SoundBtn.visible = false; /*We add a game timer and set it to 90 miliseconds to give the Savescreenshot function some time to take a screenshot while there are no buttons in the screen*/ this.game.time.events.add(90,function() { /*this is a pure javascript code for taking a screenshot of the canvas and saving it locally in the players laptop,pc, chrome mobile/tablet*/ var a = document.createElement('a'); var Data = this.game.canvas.toDataURL( 'image/png' ).replace( 'image/png', 'image/octet-stream' ); a.setAttribute('download', 'kawaii-games-'+ GameTitle +'.png'); // change this ^^^^^ if you want a different file name a.href = Data; a.innerHTML = 'testing'; a.style.display = 'none'; a.click(); /*after taking a screenshot and saving it, we will set the buttons visibility to true again so we can use them*/ Credits_Btn.visible = true; Retry_Btn.visible = true; Save_Btn.visible = true; MoreGames_Btn.visible = true; SoundBtn.visible = true; },this); }, NormalSize_fnc: function() { /*Set the Character_Group that holds all the doll's assets X and Y position and scale/resize it to it's normal size*/ //Doll_Group.scale.setTo(0.5,0.5); Doll_Group.x = 0; Doll_Group.y = 1; /*this will set the smoothness filter for all the graphics/assets that are in the Character_Group. If you wanted all the graphics to be crisp, you can set this v to false. (I don't know if you're going to like it)*/ //Doll_Group.setAll("smoothed",true); }, ScaleDoll: function() { /*Set the Character_Group that holds all the doll's assets X and Y position and scale/resize it to a much bigger size (Zoom in effect)*/ /*Doll_Group.x = -209; Doll_Group.y = -26; Doll_Group.scale.setTo(1,1);*/ /*this will set the smoothness filter for all the graphics/assets that are in the Doll_Group. It is set to false v so that when we scale the graphics to a larger size, it will still be going to be crisp.*/ //Doll_Group.setAll("smoothed",false); }, changeColor: function(Num,HairColorNum2) { console.log("changeColor"); if(colorPage == 1) { if(openedMenu == 1) { hairColor = Num; Hair.tint = Colors[Num]; //Bangs.tint = Hair.tint; } else if(openedMenu == 2) { Hair_Hl.visible = true; //Bang_Hl.visible = true; Hair_Hl.tint = Colors[Num]; //Bang_Hl.tint = Hair_Hl.tint; } else if(openedMenu == 3){Eyes.tint = Colors[Num];} else if(openedMenu == 5) { Eye_Shadow.visible = true; Eye_Shadow.tint = Colors[Num]; } else if(openedMenu == 6){Lips.tint = Colors[Num];} else if(openedMenu == 8 || openedMenu == 10){Clothes.tint = Colors[Num];} else if(openedMenu == 9){Bottoms.tint = Colors[Num];} else if(openedMenu == 11){Shoes.tint = Colors[Num];} else if(openedMenu == 12){Socks.tint = Colors[Num];} else if(openedMenu == 13) { Extra.tint = Colors[Num]; Extra2.tint = Colors[Num]; Extra3.tint = Colors[Num]; Extra4.tint = Colors[Num]; Extra5.tint = Colors[Num]; Extra6.tint = Colors[Num]; } else if(openedMenu == 14){Cake.tint = Colors[Num];} } else if(colorPage == 2) { if(openedMenu == 1) { hairColor = HairColorNum2; Hair.tint = Colors2[Num]; //Bangs.tint = Hair.tint; } else if(openedMenu == 2) { Hair_Hl.visible = true; //Bang_Hl.visible = true; Hair_Hl.tint = Colors2[Num]; //Bang_Hl.tint = Hair_Hl.tint; } else if(openedMenu == 3){Eyes.tint = Colors2[Num];} else if(openedMenu == 5) { Eye_Shadow.visible = true; Eye_Shadow.tint = Colors2[Num]; } else if(openedMenu == 6){Lips.tint = Colors2[Num];} else if(openedMenu == 8 || openedMenu == 10){Clothes.tint = Colors2[Num];} else if(openedMenu == 9){Bottoms.tint = Colors2[Num];} else if(openedMenu == 11){Shoes.tint = Colors2[Num];} else if(openedMenu == 12){Socks.tint = Colors2[Num];} else if(openedMenu == 13) { Extra.tint = Colors2[Num]; Extra2.tint = Colors2[Num]; Extra3.tint = Colors2[Num]; Extra4.tint = Colors2[Num]; Extra5.tint = Colors2[Num]; Extra6.tint = Colors2[Num]; } else if(openedMenu == 14){Cake.tint = Colors2[Num];} } }, SkinColor_fnc: function(SkinColorNum) { console.log("SkinColor"); if(skinColorPage == 1) { Head.tint = BodyColor[SkinColorNum]; Body.tint = BodyColor[SkinColorNum]; } if(skinColorPage == 2) { Head.tint = BodyColor2[SkinColorNum]; Body.tint = BodyColor2[SkinColorNum]; } }, checkHairColor: function() { if(hairColor <= 39) { for(var i = 0; i < 40; i++) { if(hairColor == i){Hair.tint = Colors[i];} } } if(hairColor >= 40) { for(var j = 0; j < 40; j++) { if(hairColor == j){Hair.tint = Colors2[j];} } } }, checkBangsColor: function() { if(hairColor <= 39) { for(var i = 0; i < 40; i++) { if(hairColor == i){Bangs.tint = Colors[i];} } } if(hairColor >= 40) { for(var j = 0; j < 40; j++) { if(hairColor == j){Bangs.tint = Colors2[j];} } } }, Bang_fnc: function(BangKey,BangName,BangX,BangY) { if(Bangs.key != BangKey) { Bangs.destroy(); Bangs = this.add.sprite(0,0,BangKey); Bangs.anchor.setTo(0.5,0.5); Bangs.x = BangX; Bangs.y = BangY; Bangs.name = BangName; } /* ***EDIT THIS*** */ /*delete some code from the bottom of this if statement if there are few hair colors to choose from. OR if you add more hair colors, please add it at the bottom of the if statements. Example: if(Bang_Hl.visible && BangName == "Bang07") { if(hlColor == 1){this.Bang_Hl_fnc("bang_hl07_0001","BangHl07",BangHl07X,BangHl07Y);} . . . }*/ if(BangName == "Bang01") { /* ***EDIT THIS*** */ /*delete some code from the bottom of this if statement if there are few hair colors to choose from. OR if you add more hair colors, please add it at the bottom of the if statements. Example: if(hlColor == 18){this.Bang_Hl_fnc("bang_hl01_0018","BangHl01",BangHl01X,BangHl01Y);} */ this.Bang_Hl_fnc("bang_hl","BangHl01",Bang_HlX,Bang_HlY); if(hlColor == 0){Bang_Hl.frame = 0;} if(hlColor == 1){Bang_Hl.frame = 1;} if(hlColor == 2){Bang_Hl.frame = 2;} if(hlColor == 3){Bang_Hl.frame = 3;} if(hlColor == 4){Bang_Hl.frame = 4;} if(hlColor == 5){Bang_Hl.frame = 5;} if(hlColor == 6){Bang_Hl.frame = 6;} if(hlColor == 7){Bang_Hl.frame = 7;} if(hlColor == 8){Bang_Hl.frame = 8;} if(hlColor == 9){Bang_Hl.frame = 9;} if(hlColor == 10){Bang_Hl.frame = 10;} if(hlColor == 11){Bang_Hl.frame = 11;} } if(BangName == "Bang02") { this.Bang_Hl_fnc("bang_hl2","BangHl02",Bang_HlX2,Bang_HlY2); if(hlColor == 0){Bang_Hl.frame = 0;} if(hlColor == 1){Bang_Hl.frame = 1;} if(hlColor == 2){Bang_Hl.frame = 2;} if(hlColor == 3){Bang_Hl.frame = 3;} if(hlColor == 4){Bang_Hl.frame = 4;} if(hlColor == 5){Bang_Hl.frame = 5;} if(hlColor == 6){Bang_Hl.frame = 6;} if(hlColor == 7){Bang_Hl.frame = 7;} if(hlColor == 8){Bang_Hl.frame = 8;} if(hlColor == 9){Bang_Hl.frame = 9;} if(hlColor == 10){Bang_Hl.frame = 10;} if(hlColor == 11){Bang_Hl.frame = 11;} } if(BangName == "Bang03") { this.Bang_Hl_fnc("bang_hl3","BangHl03",Bang_HlX3,Bang_HlY3); if(hlColor == 0){Bang_Hl.frame = 0;} if(hlColor == 1){Bang_Hl.frame = 1;} if(hlColor == 2){Bang_Hl.frame = 2;} if(hlColor == 3){Bang_Hl.frame = 3;} if(hlColor == 4){Bang_Hl.frame = 4;} if(hlColor == 5){Bang_Hl.frame = 5;} if(hlColor == 6){Bang_Hl.frame = 6;} if(hlColor == 7){Bang_Hl.frame = 7;} if(hlColor == 8){Bang_Hl.frame = 8;} if(hlColor == 9){Bang_Hl.frame = 9;} if(hlColor == 10){Bang_Hl.frame = 10;} if(hlColor == 11){Bang_Hl.frame = 11;} } if(BangName == "Bang04") { this.Bang_Hl_fnc("bang_hl4","BangHl04",Bang_HlX4,Bang_HlY4); if(hlColor == 0){Bang_Hl.frame = 0;} if(hlColor == 1){Bang_Hl.frame = 1;} if(hlColor == 2){Bang_Hl.frame = 2;} if(hlColor == 3){Bang_Hl.frame = 3;} if(hlColor == 4){Bang_Hl.frame = 4;} if(hlColor == 5){Bang_Hl.frame = 5;} if(hlColor == 6){Bang_Hl.frame = 6;} if(hlColor == 7){Bang_Hl.frame = 7;} if(hlColor == 8){Bang_Hl.frame = 8;} if(hlColor == 9){Bang_Hl.frame = 9;} if(hlColor == 10){Bang_Hl.frame = 10;} if(hlColor == 11){Bang_Hl.frame = 11;} } if(BangName == "Bang05") { this.Bang_Hl_fnc("bang_hl5","BangHl05",Bang_HlX5,Bang_HlY5); if(hlColor == 0){Bang_Hl.frame = 0;} if(hlColor == 1){Bang_Hl.frame = 1;} if(hlColor == 2){Bang_Hl.frame = 2;} if(hlColor == 3){Bang_Hl.frame = 3;} if(hlColor == 4){Bang_Hl.frame = 4;} if(hlColor == 5){Bang_Hl.frame = 5;} if(hlColor == 6){Bang_Hl.frame = 6;} if(hlColor == 7){Bang_Hl.frame = 7;} if(hlColor == 8){Bang_Hl.frame = 8;} if(hlColor == 9){Bang_Hl.frame = 9;} if(hlColor == 10){Bang_Hl.frame = 10;} if(hlColor == 11){Bang_Hl.frame = 11;} } if(BangName == "Bang06") { this.Bang_Hl_fnc("bang_hl6","BangHl06",Bang_HlX6,Bang_HlY6); if(hlColor == 0){Bang_Hl.frame = 0;} if(hlColor == 1){Bang_Hl.frame = 1;} if(hlColor == 2){Bang_Hl.frame = 2;} if(hlColor == 3){Bang_Hl.frame = 3;} if(hlColor == 4){Bang_Hl.frame = 4;} if(hlColor == 5){Bang_Hl.frame = 5;} if(hlColor == 6){Bang_Hl.frame = 6;} if(hlColor == 7){Bang_Hl.frame = 7;} if(hlColor == 8){Bang_Hl.frame = 8;} if(hlColor == 9){Bang_Hl.frame = 9;} if(hlColor == 10){Bang_Hl.frame = 10;} if(hlColor == 11){Bang_Hl.frame = 11;} } /*this function will sort the Character_Group after creating the new sprite. We need to do this so that the z/depth of the new sprite will still be in the same place*/ this.SortMainGroup_fnc(); }, Bang_Hl_fnc: function(Bang_HlKey,Bang_HlName,Bang_HlX,Bang_HlY) { Bang_Hl.destroy(); Bang_Hl = this.add.sprite(0,0,Bang_HlKey); Bang_Hl.anchor.setTo(0.5,0.5); Bang_Hl.x = Bang_HlX; Bang_Hl.y = Bang_HlY; Bang_Hl.name = Bang_HlName; if(hlVisible){Bang_Hl.visible = true;} else{Bang_Hl.visible = false;} /*this function will sort the Character_Group after creating the new sprite. We need to do this so that the z/depth of the new sprite will still be in the same place*/ this.SortMainGroup_fnc(); }, Hair_fnc: function(HairKey,HairName,HairX,HairY) { /*if the Hair.key(image sprite that the Hair sprite is created, Example: "hair01_0010") is not equal to HairKey*/ if(Hair.key != HairKey) { /*destroy/erase the Hair and make a new Hair sprite using the HairKey that we passed in this Hair_fnc function.*/ Hair.destroy(); /*create a new button*/ Hair = this.add.button(0,0,HairKey); Hair.anchor.setTo(0.5,0.5); Hair.input.pixelPerfectClick = true; Hair.x = HairX; Hair.y = HairY; Hair.name = HairName; } /* ***EDIT THIS*** */ /*delete some code from the bottom of this if statement if there are few hair colors to choose from. OR if you add more hair colors, please add it at the bottom of the if statements. Example: if(Hair_Hl.visible && HairName == "Hair07") { if(hlColor == 1){this.Hair_Hl_fnc("hair_hl07_0001","HairHl07",HairHl07X,HairHl07Y);} . . . }*/ /*if(HairName == "Hair01") { this.Hair_Hl_fnc("hair_hl","HairHl01",Hair_HlX,Hair_HlY); if(hlColor == 0){Hair_Hl.frame = 0;} if(hlColor == 1){Hair_Hl.frame = 1;} if(hlColor == 2){Hair_Hl.frame = 2;} if(hlColor == 3){Hair_Hl.frame = 3;} if(hlColor == 4){Hair_Hl.frame = 4;} if(hlColor == 5){Hair_Hl.frame = 5;} if(hlColor == 6){Hair_Hl.frame = 6;} if(hlColor == 7){Hair_Hl.frame = 7;} if(hlColor == 8){Hair_Hl.frame = 8;} if(hlColor == 9){Hair_Hl.frame = 9;} if(hlColor == 10){Hair_Hl.frame = 10;} if(hlColor == 11){Hair_Hl.frame = 11;} } if(HairName == "Hair02") { this.Hair_Hl_fnc("hair_hl2","HairHl02",Hair_HlX2,Hair_HlY2); if(hlColor == 0){Hair_Hl.frame = 0;} if(hlColor == 1){Hair_Hl.frame = 1;} if(hlColor == 2){Hair_Hl.frame = 2;} if(hlColor == 3){Hair_Hl.frame = 3;} if(hlColor == 4){Hair_Hl.frame = 4;} if(hlColor == 5){Hair_Hl.frame = 5;} if(hlColor == 6){Hair_Hl.frame = 6;} if(hlColor == 7){Hair_Hl.frame = 7;} if(hlColor == 8){Hair_Hl.frame = 8;} if(hlColor == 9){Hair_Hl.frame = 9;} if(hlColor == 10){Hair_Hl.frame = 10;} if(hlColor == 11){Hair_Hl.frame = 11;} } if(HairName == "Hair03") { this.Hair_Hl_fnc("hair_hl3","HairHl03",Hair_HlX3,Hair_HlY3); if(hlColor == 0){Hair_Hl.frame = 0;} if(hlColor == 1){Hair_Hl.frame = 1;} if(hlColor == 2){Hair_Hl.frame = 2;} if(hlColor == 3){Hair_Hl.frame = 3;} if(hlColor == 4){Hair_Hl.frame = 4;} if(hlColor == 5){Hair_Hl.frame = 5;} if(hlColor == 6){Hair_Hl.frame = 6;} if(hlColor == 7){Hair_Hl.frame = 7;} if(hlColor == 8){Hair_Hl.frame = 8;} if(hlColor == 9){Hair_Hl.frame = 9;} if(hlColor == 10){Hair_Hl.frame = 10;} if(hlColor == 11){Hair_Hl.frame = 11;} } if(HairName == "Hair04") { this.Hair_Hl_fnc("hair_hl4","HairHl04",Hair_HlX4,Hair_HlY4); if(hlColor == 0){Hair_Hl.frame = 0;} if(hlColor == 1){Hair_Hl.frame = 1;} if(hlColor == 2){Hair_Hl.frame = 2;} if(hlColor == 3){Hair_Hl.frame = 3;} if(hlColor == 4){Hair_Hl.frame = 4;} if(hlColor == 5){Hair_Hl.frame = 5;} if(hlColor == 6){Hair_Hl.frame = 6;} if(hlColor == 7){Hair_Hl.frame = 7;} if(hlColor == 8){Hair_Hl.frame = 8;} if(hlColor == 9){Hair_Hl.frame = 9;} if(hlColor == 10){Hair_Hl.frame = 10;} if(hlColor == 11){Hair_Hl.frame = 11;} } if(HairName == "Hair05") { this.Hair_Hl_fnc("hair_hl5","HairHl05",Hair_HlX5,Hair_HlY5); if(hlColor == 0){Hair_Hl.frame = 0;} if(hlColor == 1){Hair_Hl.frame = 1;} if(hlColor == 2){Hair_Hl.frame = 2;} if(hlColor == 3){Hair_Hl.frame = 3;} if(hlColor == 4){Hair_Hl.frame = 4;} if(hlColor == 5){Hair_Hl.frame = 5;} if(hlColor == 6){Hair_Hl.frame = 6;} if(hlColor == 7){Hair_Hl.frame = 7;} if(hlColor == 8){Hair_Hl.frame = 8;} if(hlColor == 9){Hair_Hl.frame = 9;} if(hlColor == 10){Hair_Hl.frame = 10;} if(hlColor == 11){Hair_Hl.frame = 11;} } if(HairName == "Hair06") { this.Hair_Hl_fnc("hair_hl6","HairHl06",Hair_HlX6,Hair_HlY6); if(hlColor == 0){Hair_Hl.frame = 0;} if(hlColor == 1){Hair_Hl.frame = 1;} if(hlColor == 2){Hair_Hl.frame = 2;} if(hlColor == 3){Hair_Hl.frame = 3;} if(hlColor == 4){Hair_Hl.frame = 4;} if(hlColor == 5){Hair_Hl.frame = 5;} if(hlColor == 6){Hair_Hl.frame = 6;} if(hlColor == 7){Hair_Hl.frame = 7;} if(hlColor == 8){Hair_Hl.frame = 8;} if(hlColor == 9){Hair_Hl.frame = 9;} if(hlColor == 10){Hair_Hl.frame = 10;} if(hlColor == 11){Hair_Hl.frame = 11;} }*/ /*this function will sort the Character_Group after creating the new sprite. We need to do this so that the z/depth of the new sprite will still be in the same place*/ this.SortMainGroup_fnc(); }, Hair_Hl_fnc: function(Hair_HlKey,Hair_HlName,Hair_HlX,Hair_HlY) { Hair_Hl.destroy(); Hair_Hl = this.add.sprite(0,0,Hair_HlKey); Hair_Hl.anchor.setTo(0.5,0.5); Hair_Hl.x = Hair_HlX; Hair_Hl.y = Hair_HlY; Hair_Hl.name = Hair_HlName; if(hlVisible){Hair_Hl.visible = true;} else{Hair_Hl.visible = false;} /*this function will sort the Character_Group after creating the new sprite. We need to do this so that the z/depth of the new sprite will still be in the same place*/ this.SortMainGroup_fnc(); }, Lips_fnc: function(LipsKey,LipsName,LipsX,LipsY) { Lips.destroy(); Lips = this.add.button(0,0,LipsKey); Lips.anchor.setTo(0.5,0.5); Lips.input.pixelPerfectClick = true; Lips.x = LipsX; Lips.y = LipsY; Lips.name = LipsName; /*this function will sort the Character_Group after creating the new sprite. We need to do this so that the z/depth of the new sprite will still be in the same place*/ this.SortMainGroup_fnc(); }, Clothes_fnc: function(ClothesKey,ClothesName,ClothesX,ClothesY) { Clothes.destroy(); Clothes = this.add.button(0,0,ClothesKey); Clothes.anchor.setTo(0.5,0.5); Clothes.input.pixelPerfectClick = true; Clothes.x = ClothesX; Clothes.y = ClothesY; Clothes.name = ClothesName; //Bra.visible = false; /*this function will sort the Character_Group after creating the new sprite. We need to do this so that the z/depth of the new sprite will still be in the same place*/ this.SortMainGroup_fnc(); }, Bottoms_fnc: function(BottomsKey,BottomsName,BottomsX,BottomsY) { Bottoms.destroy(); Bottoms = this.add.button(0,0,BottomsKey); Bottoms.anchor.setTo(0.5,0.5); Bottoms.input.pixelPerfectClick = true; Bottoms.x = BottomsX; Bottoms.y = BottomsY; Bottoms.name = BottomsName; Panties.visible = false; if(Clothes.name == "Dress01" || Clothes.name == "Dress02" || Clothes.name == "Dress03" || Clothes.name == "Dress04" || Clothes.name == "Dress05" || Clothes.name == "Dress06") { Clothes.visible = false; } /*this function will sort the Character_Group after creating the new sprite. We need to do this so that the z/depth of the new sprite will still be in the same place*/ this.SortMainGroup_fnc(); }, Shoes_fnc: function(ShoesKey,ShoesName,ShoesX,ShoesY) { Shoes.destroy(); Shoes = this.add.button(0,0,ShoesKey,function() { Shoes.visible = false; },this); Shoes.anchor.setTo(0.5,0.5); Shoes.input.pixelPerfectClick = true; Shoes.x = ShoesX; Shoes.y = ShoesY; Shoes.name = ShoesName; /*this function will sort the Character_Group after creating the new sprite. We need to do this so that the z/depth of the new sprite will still be in the same place*/ this.SortMainGroup_fnc(); }, Socks_fnc: function(SocksKey,SocksName,SocksX,SocksY) { Socks.destroy(); Socks = this.add.button(0,0,SocksKey,function() { Socks.visible = false; },this); Socks.anchor.setTo(0.5,0.5); Socks.pixelPerfectClick = true; Socks.x = SocksX; Socks.y = SocksY; Socks.name = SocksName; /*this function will sort the Character_Group after creating the new sprite. We need to do this so that the z/depth of the new sprite will still be in the same place*/ this.SortMainGroup_fnc(); }, //Shuffle Shuffle_Items: function() { var HairRand = Math.floor(Math.random()*(6-1+1))+1; if(HairRand == 1) { Hair.frame = 0; Hair_Outline.frame = Hair.frame; Hair_Hl.frame = Hair.frame; } if(HairRand == 2) { Hair.frame = 1; Hair_Outline.frame = Hair.frame; Hair_Hl.frame = Hair.frame; } if(HairRand == 3) { Hair.frame = 2; Hair_Outline.frame = Hair.frame; Hair_Hl.frame = Hair.frame; } if(HairRand == 4) { Hair.frame = 3; Hair_Outline.frame = Hair.frame; Hair_Hl.frame = Hair.frame; } if(HairRand == 5) { Hair.frame = 4; Hair_Outline.frame = Hair.frame; Hair_Hl.frame = Hair.frame; } if(HairRand == 6) { Hair.frame = 5; Hair_Outline.frame = Hair.frame; Hair_Hl.frame = Hair.frame; } /*var BangsRand = Math.floor(Math.random()*(6-1+1))+1; if(BangsRand == 1) { Bangs.frame = 0; Bangs_Outline.frame = Bangs.frame; Bang_Hl.frame = Bangs.frame; } if(BangsRand == 2) { Bangs.frame = 1; Bangs_Outline.frame = Bangs.frame; Bang_Hl.frame = Bangs.frame; } if(BangsRand == 3) { Bangs.frame = 2; Bangs_Outline.frame = Bangs.frame; Bang_Hl.frame = Bangs.frame; } if(BangsRand == 4) { Bangs.frame = 3; Bangs_Outline.frame = Bangs.frame; Bang_Hl.frame = Bangs.frame; } if(BangsRand == 5) { Bangs.frame = 4; Bangs_Outline.frame = Bangs.frame; Bang_Hl.frame = Bangs.frame; } if(BangsRand == 6) { Bangs.frame = 5; Bangs_Outline.frame = Bangs.frame; Bang_Hl.frame = Bangs.frame; }*/ /*this.ColorShuffle_fnc(Hair,Bangs,true,true); this.ColorShuffle_fnc(Hair_Hl,Bang_Hl,true,false);*/ this.ColorShuffle_fnc(Hair,null,false,true); this.ColorShuffle_fnc(Hair_Hl,null,false,false); this.ColorShuffle_fnc(Eyes,null,false,false); var EyesRand = Math.floor(Math.random()*(3-1+1))+1; if(EyesRand == 1) { Eyes.frame = 0; Eyes_White.frame = Eyes.frame; Eye_Shadow.frame = Eyes.frame; } if(EyesRand == 2) { Eyes.frame = 1; Eyes_White.frame = Eyes.frame; Eye_Shadow.frame = Eyes.frame; } if(EyesRand == 3) { Eyes.frame = 2; Eyes_White.frame = Eyes.frame; Eye_Shadow.frame = Eyes.frame; } var EyebrowsRand = Math.floor(Math.random()*(3-1+1))+1; if(EyebrowsRand == 1){Eyebrows.frame = 0;} if(EyebrowsRand == 2){Eyebrows.frame = 1;} if(EyebrowsRand == 3){Eyebrows.frame = 2;} this.ColorShuffle_fnc(Eye_Shadow,null,false,false); var LipsRand = Math.floor(Math.random()*(6-1+1))+1; if(LipsRand == 1) { Lips.frame = 0; //Lips_Outline.frame = 0; } if(LipsRand == 2) { Lips.frame = 1; //Lips_Outline.frame = 1; } if(LipsRand == 3) { Lips.frame = 2; //Lips_Outline.frame = 2; } if(LipsRand == 4) { Lips.frame = 3; //Lips_Outline.frame = 3; } if(LipsRand == 5) { Lips.frame = 4; //Lips_Outline.frame = 4; } if(LipsRand == 6) { Lips.frame = 5; //Lips_Outline.frame = 5; } //this.ColorShuffle_fnc(Lips,null,false,false); /*var BodyRand = Math.floor(Math.random()*(15-1+1))+1; if(BodyRand == 1){Body.tint = BodyColor[0];} if(BodyRand == 2){Body.tint = BodyColor[1];} if(BodyRand == 3){Body.tint = BodyColor[2];} if(BodyRand == 4){Body.tint = BodyColor[3];} if(BodyRand == 5){Body.tint = BodyColor[4];} if(BodyRand == 6){Body.tint = BodyColor[5];} if(BodyRand == 7){Body.tint = BodyColor[6];} if(BodyRand == 8){Body.tint = BodyColor[7];} if(BodyRand == 9){Body.tint = BodyColor[8];} if(BodyRand == 10){Body.tint = BodyColor[9];} if(BodyRand == 11){Body.tint = BodyColor[10];} if(BodyRand == 12){Body.tint = BodyColor[11];} if(BodyRand == 13){Body.tint = BodyColor[12];} if(BodyRand == 14){Body.tint = BodyColor[13];} if(BodyRand == 15){Body.tint = BodyColor[14];}*/ var ClothesRand = Math.floor(Math.random()*(12-1+1))+1; Clothes.visible = true; Clothes_Outline.visible = true; if(ClothesRand == 1) { Clothes.frame = 0; Clothes_Outline.frame = 0; if(Bra.visible){Bra.visible = false;} } if(ClothesRand == 2) { Clothes.frame = 1; Clothes_Outline.frame = 1; if(Bra.visible){Bra.visible = false;} } if(ClothesRand == 3) { Clothes.frame = 2; Clothes_Outline.frame = 2; if(!Bra.visible){Bra.visible = true;} } if(ClothesRand == 4) { Clothes.frame = 3; Clothes_Outline.frame = 3; if(Bra.visible){Bra.visible = false;} } if(ClothesRand == 5) { Clothes.frame = 4; Clothes_Outline.frame = 4; if(!Bra.visible){Bra.visible = true;} } if(ClothesRand == 6) { Clothes.frame = 5; Clothes_Outline.frame = 5; if(!Bra.visible){Bra.visible = true;} } if(ClothesRand == 7) { Clothes.frame = 6; Clothes_Outline.frame = 6; if(Bra.visible){Bra.visible = false;} if(Panties.visible){Panties.visible = false;} } if(ClothesRand == 8) { Clothes.frame = 7; Clothes_Outline.frame = 7; if(Bra.visible){Bra.visible = false;} if(Panties.visible){Panties.visible = false;} } if(ClothesRand == 9) { Clothes.frame = 8; Clothes_Outline.frame = 8; if(Bra.visible){Bra.visible = false;} if(Panties.visible){Panties.visible = false;} } if(ClothesRand == 10) { Clothes.frame = 9; Clothes_Outline.frame = 9; if(Bra.visible){Bra.visible = false;} if(Panties.visible){Panties.visible = false;} } if(ClothesRand == 11) { Clothes.frame = 10; Clothes_Outline.frame = 10; if(!Bra.visible){Bra.visible = true;} if(Panties.visible){Panties.visible = false;} } if(ClothesRand == 12) { Clothes.frame = 11; Clothes_Outline.frame = 11; if(Bra.visible){Bra.visible = false;} if(Panties.visible){Panties.visible = false;} } this.ColorShuffle_fnc(Clothes,null,false,false); var BottomsRand = Math.floor(Math.random()*(6-1+1))+1; Bottoms.visible = true; Bottoms_Outline.visible = true; if(BottomsRand == 1) { Bottoms.frame = 0; Bottoms_Outline.frame = 0; } if(BottomsRand == 2) { Bottoms.frame = 1; Bottoms_Outline.frame = 1; } if(BottomsRand == 3) { Bottoms.frame = 2; Bottoms_Outline.frame = 2; } if(BottomsRand == 4) { Bottoms.frame = 3; Bottoms_Outline.frame = 3; } if(BottomsRand == 5) { Bottoms.frame = 4; Bottoms_Outline.frame = 4; } if(BottomsRand == 6) { Bottoms.frame = 5; Bottoms_Outline.frame = 5; } this.ColorShuffle_fnc(Bottoms,null,false,false); /*var JacketRand = Math.floor(Math.random()*(6-1+1))+1; Jacket.visible = true; Jacket_Outline.visible = true; if(JacketRand == 1) { Jacket.frame = 0; Jacket_Outline.frame = 0; } if(JacketRand == 2) { Jacket.frame = 1; Jacket_Outline.frame = 1; } if(JacketRand == 3) { Jacket.frame = 2; Jacket_Outline.frame = 2; } if(JacketRand == 4) { Jacket.frame = 3; Jacket_Outline.frame = 3; } if(JacketRand == 5) { Jacket.frame = 4; Jacket_Outline.frame = 4; } if(JacketRand == 6) { Jacket.frame = 5; Jacket_Outline.frame = 5; } this.ColorShuffle_fnc(Jacket,null,false,false);*/ var ShoesRand = Math.floor(Math.random()*(6-1+1))+1; Shoes.visible = true; Shoes_Outline.visible = true; if(ShoesRand == 1) { Shoes.frame = 0; Shoes_Outline.frame = 0; } if(ShoesRand == 2) { Shoes.frame = 1; Shoes_Outline.frame = 1; } if(ShoesRand == 3) { Shoes.frame = 2; Shoes_Outline.frame = 2; } if(ShoesRand == 4) { Shoes.frame = 3; Shoes_Outline.frame = 3; } if(ShoesRand == 5) { Shoes.frame = 4; Shoes_Outline.frame = 4; } if(ShoesRand == 6) { Shoes.frame = 5; Shoes_Outline.frame = 5; } this.ColorShuffle_fnc(Shoes,null,false,false); var SocksRand = Math.floor(Math.random()*(6-1+1))+1; Socks.visible = true; Socks_Outline.visible = true; if(SocksRand == 1) { Socks.frame = 0; Socks_Outline.frame = 0; } if(SocksRand == 2) { Socks.frame = 1; Socks_Outline.frame = 1; } if(SocksRand == 3) { Socks.frame = 2; Socks_Outline.frame = 2; } if(SocksRand == 4) { Socks.frame = 3; Socks_Outline.frame = 3; } if(SocksRand == 5) { Socks.frame = 4; Socks_Outline.frame = 4; } if(SocksRand == 6) { Socks.frame = 5; Socks_Outline.frame = 5; } this.ColorShuffle_fnc(Socks,null,false,false); var ExtraRand = Math.floor(Math.random()*(2-1+1))+1; if(ExtraRand == 1) { Extra.visible = true; Extra_Outline.visible = true; } if(ExtraRand == 2) { Extra.visible = false; Extra_Outline.visible = false; } var Extra2Rand = Math.floor(Math.random()*(2-1+1))+1; if(Extra2Rand == 1) { Extra2.visible = true; Extra2_Outline.visible = true; } if(Extra2Rand == 2) { Extra2.visible = false; Extra2_Outline.visible = false; } var Extra3Rand = Math.floor(Math.random()*(2-1+1))+1; if(Extra3Rand == 1) { Extra3.visible = true; Extra3_Outline.visible = true; } if(Extra3Rand == 2) { Extra3.visible = false; Extra3_Outline.visible = false; } var Extra4Rand = Math.floor(Math.random()*(2-1+1))+1; if(Extra4Rand == 1) { Extra4.visible = true; Extra4_Outline.visible = true; } if(Extra4Rand == 2) { Extra4.visible = false; Extra4_Outline.visible = false; } var Extra5Rand = Math.floor(Math.random()*(2-1+1))+1; if(Extra5Rand == 1) { Extra5.visible = true; Extra5_Outline.visible = true; } if(Extra5Rand == 2) { Extra5.visible = false; Extra5_Outline.visible = false; } var Extra6Rand = Math.floor(Math.random()*(2-1+1))+1; if(Extra6Rand == 1) { Extra6.visible = true; Extra6_Outline.visible = true; } if(Extra6Rand == 2) { Extra6.visible = false; Extra6_Outline.visible = false; } }, ColorShuffle_fnc: function(ItemObj,ItemObj2,doubleTint,colorNumBool) { var ColorRand = Math.floor(Math.random()*(80-1+1))+1; if(ColorRand == 1) { ItemObj.tint = Colors[0]; if(doubleTint){ItemObj2.tint = Colors[0];} if(colorNumBool){hairColor = 0;} } if(ColorRand == 2) { ItemObj.tint = Colors[1]; if(doubleTint){ItemObj2.tint = Colors[1];} if(colorNumBool){hairColor = 1;} } if(ColorRand == 3) { ItemObj.tint = Colors[2]; if(doubleTint){ItemObj2.tint = Colors[2];} if(colorNumBool){hairColor = 2;} } if(ColorRand == 4) { ItemObj.tint = Colors[3]; if(doubleTint){ItemObj2.tint = Colors[3];} if(colorNumBool){hairColor = 3;} } if(ColorRand == 5) { ItemObj.tint = Colors[4]; if(doubleTint){ItemObj2.tint = Colors[4];} if(colorNumBool){hairColor = 4;} } if(ColorRand == 6) { ItemObj.tint = Colors[5]; if(doubleTint){ItemObj2.tint = Colors[5];} if(colorNumBool){hairColor = 5;} } if(ColorRand == 7) { ItemObj.tint = Colors[6]; if(doubleTint){ItemObj2.tint = Colors[6];} if(colorNumBool){hairColor = 6;} } if(ColorRand == 8) { ItemObj.tint = Colors[7]; if(doubleTint){ItemObj2.tint = Colors[7];} if(colorNumBool){hairColor = 7;} } if(ColorRand == 9) { ItemObj.tint = Colors[8]; if(doubleTint){ItemObj2.tint = Colors[8];} if(colorNumBool){hairColor = 8;} } if(ColorRand == 10) { ItemObj.tint = Colors[9]; if(doubleTint){ItemObj2.tint = Colors[9];} if(colorNumBool){hairColor = 9;} } if(ColorRand == 11) { ItemObj.tint = Colors[10]; if(doubleTint){ItemObj2.tint = Colors[10];} if(colorNumBool){hairColor = 10;} } if(ColorRand == 12) { ItemObj.tint = Colors[11]; if(doubleTint){ItemObj2.tint = Colors[11];} if(colorNumBool){hairColor = 11;} } if(ColorRand == 13) { ItemObj.tint = Colors[12]; if(doubleTint){ItemObj2.tint = Colors[12];} if(colorNumBool){hairColor = 12;} } if(ColorRand == 14) { ItemObj.tint = Colors[13]; if(doubleTint){ItemObj2.tint = Colors[13];} if(colorNumBool){hairColor = 13;} } if(ColorRand == 15) { ItemObj.tint = Colors[14]; if(doubleTint){ItemObj2.tint = Colors[14];} if(colorNumBool){hairColor = 14;} } if(ColorRand == 16) { ItemObj.tint = Colors[15]; if(doubleTint){ItemObj2.tint = Colors[15];} if(colorNumBool){hairColor = 15;} } if(ColorRand == 17) { ItemObj.tint = Colors[16]; if(doubleTint){ItemObj2.tint = Colors[16];} if(colorNumBool){hairColor = 16;} } if(ColorRand == 18) { ItemObj.tint = Colors[17]; if(doubleTint){ItemObj2.tint = Colors[17];} if(colorNumBool){hairColor = 17;} } if(ColorRand == 19) { ItemObj.tint = Colors[18]; if(doubleTint){ItemObj2.tint = Colors[18];} if(colorNumBool){hairColor = 18;} } if(ColorRand == 20) { ItemObj.tint = Colors[19]; if(doubleTint){ItemObj2.tint = Colors[19];} if(colorNumBool){hairColor = 19;} } if(ColorRand == 21) { ItemObj.tint = Colors[20]; if(doubleTint){ItemObj2.tint = Colors[20];} if(colorNumBool){hairColor = 20;} } if(ColorRand == 22) { ItemObj.tint = Colors[21]; if(doubleTint){ItemObj2.tint = Colors[21];} if(colorNumBool){hairColor = 21;} } if(ColorRand == 23) { ItemObj.tint = Colors[22]; if(doubleTint){ItemObj2.tint = Colors[22];} if(colorNumBool){hairColor = 22;} } if(ColorRand == 24) { ItemObj.tint = Colors[23]; if(doubleTint){ItemObj2.tint = Colors[23];} if(colorNumBool){hairColor = 23;} } if(ColorRand == 25) { ItemObj.tint = Colors[24]; if(doubleTint){ItemObj2.tint = Colors[24];} if(colorNumBool){hairColor = 24;} } if(ColorRand == 26) { ItemObj.tint = Colors[25]; if(doubleTint){ItemObj2.tint = Colors[25];} if(colorNumBool){hairColor = 25;} } if(ColorRand == 27) { ItemObj.tint = Colors[26]; if(doubleTint){ItemObj2.tint = Colors[26];} if(colorNumBool){hairColor = 26;} } if(ColorRand == 28) { ItemObj.tint = Colors[27]; if(doubleTint){ItemObj2.tint = Colors[27];} if(colorNumBool){hairColor = 27;} } if(ColorRand == 29) { ItemObj.tint = Colors[28]; if(doubleTint){ItemObj2.tint = Colors[28];} if(colorNumBool){hairColor = 28;} } if(ColorRand == 30) { ItemObj.tint = Colors[29]; if(doubleTint){ItemObj2.tint = Colors[29];} if(colorNumBool){hairColor = 29;} } if(ColorRand == 31) { ItemObj.tint = Colors[30]; if(doubleTint){ItemObj2.tint = Colors[30];} if(colorNumBool){hairColor = 30;} } if(ColorRand == 32) { ItemObj.tint = Colors[31]; if(doubleTint){ItemObj2.tint = Colors[31];} if(colorNumBool){hairColor = 31;} } if(ColorRand == 33) { ItemObj.tint = Colors[32]; if(doubleTint){ItemObj2.tint = Colors[32];} if(colorNumBool){hairColor = 32;} } if(ColorRand == 34) { ItemObj.tint = Colors[33]; if(doubleTint){ItemObj2.tint = Colors[33];} if(colorNumBool){hairColor = 33;} } if(ColorRand == 35) { ItemObj.tint = Colors[34]; if(doubleTint){ItemObj2.tint = Colors[34];} if(colorNumBool){hairColor = 34;} } if(ColorRand == 36) { ItemObj.tint = Colors[35]; if(doubleTint){ItemObj2.tint = Colors[35];} if(colorNumBool){hairColor = 35;} } if(ColorRand == 37) { ItemObj.tint = Colors[36]; if(doubleTint){ItemObj2.tint = Colors[36];} if(colorNumBool){hairColor = 36;} } if(ColorRand == 38) { ItemObj.tint = Colors[37]; if(doubleTint){ItemObj2.tint = Colors[37];} if(colorNumBool){hairColor = 37;} } if(ColorRand == 39) { ItemObj.tint = Colors[38]; if(doubleTint){ItemObj2.tint = Colors[38];} if(colorNumBool){hairColor = 38;} } if(ColorRand == 40) { ItemObj.tint = Colors[39]; if(doubleTint){ItemObj2.tint = Colors[39];} if(colorNumBool){hairColor = 39;} } if(ColorRand == 41) { ItemObj.tint = Colors2[0]; if(doubleTint){ItemObj2.tint = Colors2[0];} if(colorNumBool){hairColor = 40;} } if(ColorRand == 42) { ItemObj.tint = Colors2[1]; if(doubleTint){ItemObj2.tint = Colors2[1];} if(colorNumBool){hairColor = 41;} } if(ColorRand == 43) { ItemObj.tint = Colors2[2]; if(doubleTint){ItemObj2.tint = Colors2[2];} if(colorNumBool){hairColor = 42;} } if(ColorRand == 44) { ItemObj.tint = Colors2[3]; if(doubleTint){ItemObj2.tint = Colors2[3];} if(colorNumBool){hairColor = 43;} } if(ColorRand == 45) { ItemObj.tint = Colors2[4]; if(doubleTint){ItemObj2.tint = Colors2[4];} if(colorNumBool){hairColor = 44;} } if(ColorRand == 46) { ItemObj.tint = Colors2[5]; if(doubleTint){ItemObj2.tint = Colors2[5];} if(colorNumBool){hairColor = 45;} } if(ColorRand == 47) { ItemObj.tint = Colors2[6]; if(doubleTint){ItemObj2.tint = Colors2[6];} if(colorNumBool){hairColor = 46;} } if(ColorRand == 48) { ItemObj.tint = Colors2[7]; if(doubleTint){ItemObj2.tint = Colors2[7];} if(colorNumBool){hairColor = 47;} } if(ColorRand == 49) { ItemObj.tint = Colors2[8]; if(doubleTint){ItemObj2.tint = Colors2[8];} if(colorNumBool){hairColor = 48;} } if(ColorRand == 50) { ItemObj.tint = Colors2[9]; if(doubleTint){ItemObj2.tint = Colors2[9];} if(colorNumBool){hairColor = 49;} } if(ColorRand == 51) { ItemObj.tint = Colors2[10]; if(doubleTint){ItemObj2.tint = Colors2[10];} if(colorNumBool){hairColor = 50;} } if(ColorRand == 52) { ItemObj.tint = Colors2[11]; if(doubleTint){ItemObj2.tint = Colors2[11];} if(colorNumBool){hairColor = 51;} } if(ColorRand == 53) { ItemObj.tint = Colors2[12]; if(doubleTint){ItemObj2.tint = Colors2[12];} if(colorNumBool){hairColor = 52;} } if(ColorRand == 54) { ItemObj.tint = Colors2[13]; if(doubleTint){ItemObj2.tint = Colors2[13];} if(colorNumBool){hairColor = 53;} } if(ColorRand == 55) { ItemObj.tint = Colors2[14]; if(doubleTint){ItemObj2.tint = Colors2[14];} if(colorNumBool){hairColor = 54;} } if(ColorRand == 56) { ItemObj.tint = Colors2[15]; if(doubleTint){ItemObj2.tint = Colors2[15];} if(colorNumBool){hairColor = 55;} } if(ColorRand == 57) { ItemObj.tint = Colors2[16]; if(doubleTint){ItemObj2.tint = Colors2[16];} if(colorNumBool){hairColor = 56;} } if(ColorRand == 58) { ItemObj.tint = Colors2[17]; if(doubleTint){ItemObj2.tint = Colors2[17];} if(colorNumBool){hairColor = 57;} } if(ColorRand == 59) { ItemObj.tint = Colors2[18]; if(doubleTint){ItemObj2.tint = Colors2[18];} if(colorNumBool){hairColor = 58;} } if(ColorRand == 60) { ItemObj.tint = Colors2[19]; if(doubleTint){ItemObj2.tint = Colors2[19];} if(colorNumBool){hairColor = 59;} } if(ColorRand == 61) { ItemObj.tint = Colors2[20]; if(doubleTint){ItemObj2.tint = Colors2[20];} if(colorNumBool){hairColor = 60;} } if(ColorRand == 62) { ItemObj.tint = Colors2[21]; if(doubleTint){ItemObj2.tint = Colors2[21];} if(colorNumBool){hairColor = 61;} } if(ColorRand == 63) { ItemObj.tint = Colors2[22]; if(doubleTint){ItemObj2.tint = Colors2[22];} if(colorNumBool){hairColor = 62;} } if(ColorRand == 64) { ItemObj.tint = Colors2[23]; if(doubleTint){ItemObj2.tint = Colors2[23];} if(colorNumBool){hairColor = 63;} } if(ColorRand == 65) { ItemObj.tint = Colors2[24]; if(doubleTint){ItemObj2.tint = Colors2[24];} if(colorNumBool){hairColor = 64;} } if(ColorRand == 66) { ItemObj.tint = Colors2[25]; if(doubleTint){ItemObj2.tint = Colors2[25];} if(colorNumBool){hairColor = 65;} } if(ColorRand == 67) { ItemObj.tint = Colors2[26]; if(doubleTint){ItemObj2.tint = Colors2[26];} if(colorNumBool){hairColor = 66;} } if(ColorRand == 68) { ItemObj.tint = Colors2[27]; if(doubleTint){ItemObj2.tint = Colors2[27];} if(colorNumBool){hairColor = 67;} } if(ColorRand == 69) { ItemObj.tint = Colors2[28]; if(doubleTint){ItemObj2.tint = Colors2[28];} if(colorNumBool){hairColor = 68;} } if(ColorRand == 70) { ItemObj.tint = Colors2[29]; if(doubleTint){ItemObj2.tint = Colors2[29];} if(colorNumBool){hairColor = 69;} } if(ColorRand == 71) { ItemObj.tint = Colors2[30]; if(doubleTint){ItemObj2.tint = Colors2[30];} if(colorNumBool){hairColor = 70;} } if(ColorRand == 72) { ItemObj.tint = Colors2[31]; if(doubleTint){ItemObj2.tint = Colors2[31];} if(colorNumBool){hairColor = 71;} } if(ColorRand == 73) { ItemObj.tint = Colors2[32]; if(doubleTint){ItemObj2.tint = Colors2[32];} if(colorNumBool){hairColor = 72;} } if(ColorRand == 74) { ItemObj.tint = Colors2[33]; if(doubleTint){ItemObj2.tint = Colors2[33];} if(colorNumBool){hairColor = 73;} } if(ColorRand == 75) { ItemObj.tint = Colors2[34]; if(doubleTint){ItemObj2.tint = Colors2[34];} if(colorNumBool){hairColor = 74;} } if(ColorRand == 76) { ItemObj.tint = Colors2[35]; if(doubleTint){ItemObj2.tint = Colors2[35];} if(colorNumBool){hairColor = 75;} } if(ColorRand == 77) { ItemObj.tint = Colors2[36]; if(doubleTint){ItemObj2.tint = Colors2[36];} if(colorNumBool){hairColor = 76;} } if(ColorRand == 78) { ItemObj.tint = Colors2[37]; if(doubleTint){ItemObj2.tint = Colors2[37];} if(colorNumBool){hairColor = 77;} } if(ColorRand == 79) { ItemObj.tint = Colors2[38]; if(doubleTint){ItemObj2.tint = Colors2[38];} if(colorNumBool){hairColor = 78;} } if(ColorRand == 80) { ItemObj.tint = Colors2[39]; if(doubleTint){ItemObj2.tint = Colors2[39];} if(colorNumBool){hairColor = 79;} } //console.log(colorNum) }, SortMainGroup_fnc: function() { /*this will remove all the Doll's assets in the Character_Group to make it ready for adding it in again in the Character_Group.*/ Doll_Group.remove(Shadow); Doll_Group.remove(Body); Doll_Group.remove(Body_Outline); Doll_Group.remove(Bra); Doll_Group.remove(Panties); Doll_Group.remove(Socks); Doll_Group.remove(Socks_Outline); Doll_Group.remove(Bottoms); Doll_Group.remove(Bottoms_Outline); Doll_Group.remove(Shoes); Doll_Group.remove(Shoes_Outline); Doll_Group.remove(Head); Doll_Group.remove(Head_Outline); Doll_Group.remove(Eye_Shadow); Doll_Group.remove(Eyes_White); Doll_Group.remove(Eyes); Doll_Group.remove(Face_Details); Doll_Group.remove(Eyebrows); Doll_Group.remove(Lips); Doll_Group.remove(Hair); Doll_Group.remove(Hair_Hl); Doll_Group.remove(Hair_Outline); Doll_Group.remove(Clothes); Doll_Group.remove(Clothes_Outline); //Doll_Group.remove(Lips_Outline); //Doll_Group.remove(Teeth); /*Doll_Group.remove(Bangs); Doll_Group.remove(Bang_Hl); Doll_Group.remove(Bangs_Outline);*/ Doll_Group.remove(Extra2); Doll_Group.remove(Extra2_Outline); Doll_Group.remove(Extra3); Doll_Group.remove(Extra3_Outline); Doll_Group.remove(Extra4); Doll_Group.remove(Extra4_Outline); Doll_Group.remove(Extra5); Doll_Group.remove(Extra5_Outline); Doll_Group.remove(Extra); Doll_Group.remove(Extra_Outline); Doll_Group.remove(Extra6); Doll_Group.remove(Extra6_Outline); /*Doll_Group.remove(Cake); Doll_Group.remove(Cake_Outline);*/ /*this function will add all the doll's assets again in the Character_Group*/ this.AddToGroup(); }, AddToGroup: function() { /*add all the doll's assets again in the Character_Group so that all the assets are going to be sorted out*/ Doll_Group.add(Shadow); Doll_Group.add(Body); Doll_Group.add(Body_Outline); Doll_Group.add(Bra); Doll_Group.add(Panties); Doll_Group.add(Socks); Doll_Group.add(Socks_Outline); Doll_Group.add(Bottoms); Doll_Group.add(Bottoms_Outline); Doll_Group.add(Shoes); Doll_Group.add(Shoes_Outline); Doll_Group.add(Head); Doll_Group.add(Head_Outline); Doll_Group.add(Eye_Shadow); Doll_Group.add(Eyes_White); Doll_Group.add(Eyes); Doll_Group.add(Face_Details); Doll_Group.add(Eyebrows); Doll_Group.add(Lips); Doll_Group.add(Hair); Doll_Group.add(Hair_Hl); Doll_Group.add(Hair_Outline); Doll_Group.add(Clothes); Doll_Group.add(Clothes_Outline); //Doll_Group.add(Lips_Outline); //Doll_Group.add(Teeth); /*Doll_Group.add(Bangs); Doll_Group.add(Bang_Hl); Doll_Group.add(Bangs_Outline);*/ Doll_Group.add(Extra2); Doll_Group.add(Extra2_Outline); Doll_Group.add(Extra3); Doll_Group.add(Extra3_Outline); Doll_Group.add(Extra4); Doll_Group.add(Extra4_Outline); Doll_Group.add(Extra5); Doll_Group.add(Extra5_Outline); Doll_Group.add(Extra); Doll_Group.add(Extra_Outline); Doll_Group.add(Extra6); Doll_Group.add(Extra6_Outline); /*Doll_Group.add(Cake); Doll_Group.add(Cake_Outline);*/ }, update: function() { }, }