override public void create() { FlxG.backColor = Color.White; base.create(); FlxTileblock t = new FlxTileblock(8, 8, 256 - 16, 224 - 16); t.auto = FlxTileblock.HUDELEMENT; t.loadTiles("_sheet_window_06", 16, 16, 0); add(t); FlxG.playMp3("putt/music/March", 1.0f); text = new FlxText(16, 16, 200); text.setFormat(FlxG.Content.Load <SpriteFont>("flixel/initials/SMALL_PIXEL"), 1, Color.Black, FlxJustification.Left, Color.White); add(text); text.text = "Scorecard:\n"; int total = 0; for (int i = 0; i < 18; i++) { try { Console.WriteLine("Score for hole {0}: {1}", i + 1, Globals.scoreCard[i]); text.text += string.Format("{0}: {1}, ", i + 1, Globals.scoreCard[i]); total += Globals.scoreCard[i]; if (i % 3 == 2) { text.text += "\n"; } } catch { } } text.text += string.Format("\nTotal: {0} / Par: 18 \n", total);; if (total <= 18 && Globals.hasPlayedHoleAgain == false) { text.text += "\nBonestorm.rom unlocked."; } else if (total >= 48) { text.text += "\nSix time national champion\nCarvello urges\nyou to keep practicing\nand improve your\nputting game."; } else if (total >= 32) { text.text += "\nYour putting game is improving\nrapidly.\nKeep it up, kid. "; } else if (total >= 24) { text.text += "\nYou're a real sharp shooter."; } }
override public void create() { base.create(); menu = new FlxSprite(0, 0); menu.loadGraphic(Globals.ContentFolder + "/menu", true, false, 256, 224); add(menu); toPlay = false; FlxG.playMp3("putt/music/GreenlandIsAlive", 1.0f); toStart = false; FlxGlobal.cheatString = ""; }
/// <summary> /// Play a song based on the location. /// </summary> public void playSong() { if (Lemonade_Globals.restartMusic == false) { FlxG.resumeMp3(); } else { if (Lemonade_Globals.location == "sydney") { FlxG.playMp3("Lemonade/music/Coffee", 0.5f); } else if (Lemonade_Globals.location == "newyork") { FlxG.playMp3("Lemonade/music/January", 0.5f); } else if (Lemonade_Globals.location == "military") { FlxG.playMp3("Lemonade/music/Graveyard", 0.5f); } else if (Lemonade_Globals.location == "warehouse") { FlxG.playMp3("Lemonade/music/February", 0.5f); } else if (Lemonade_Globals.location == "factory") { FlxG.playMp3("Lemonade/music/April", 0.5f); } else if (Lemonade_Globals.location == "management") { FlxG.playMp3("Lemonade/music/GreenlandFuneral", 0.5f); } else { FlxG.playMp3("Lemonade/music/GreenlandFuneral", 0.5f); } } }
override public void create() { base.create(); Lemonade_Globals.totalCoins = Lemonade_Globals.calculateTotalCoins(); FlxTilemap bgMap = new FlxTilemap(); bgMap.auto = FlxTilemap.STRING; bgMap.indexOffset = -1; bgMap.loadTMXMap("Lemonade/levels/slf2/newyork/newyork_intro.tmx", "map", "bg", FlxXMLReader.TILES, FlxG.Content.Load <Texture2D>("Lemonade/bgtiles_newyork"), 20, 20); bgMap.boundingBoxOverride = false; bgMap.setScrollFactors(1, 1); add(bgMap); bgMap = new FlxTilemap(); bgMap.auto = FlxTilemap.STRING; bgMap.indexOffset = -1; bgMap.loadTMXMap("Lemonade/levels/slf2/newyork/newyork_intro.tmx", "map", "bg2", FlxXMLReader.TILES, FlxG.Content.Load <Texture2D>("Lemonade/bgtiles_newyork"), 20, 20); bgMap.boundingBoxOverride = false; bgMap.setScrollFactors(1, 1); add(bgMap); FlxTilemap bgMap3 = new FlxTilemap(); bgMap3.auto = FlxTilemap.STRING; bgMap3.indexOffset = -1; bgMap3.loadTMXMap("Lemonade/levels/slf2/newyork/newyork_intro.tmx", "map", "stars", FlxXMLReader.TILES, FlxG.Content.Load <Texture2D>("Lemonade/bgtiles_newyork"), 20, 20); bgMap3.boundingBoxOverride = false; bgMap3.setScrollFactors(0.5f, 0.5f); add(bgMap3); FlxTilemap bgMap4 = new FlxTilemap(); bgMap4.auto = FlxTilemap.STRING; bgMap4.indexOffset = -1; bgMap4.loadTMXMap("Lemonade/levels/slf2/newyork/newyork_intro.tmx", "map", "city", FlxXMLReader.TILES, FlxG.Content.Load <Texture2D>("Lemonade/bgtiles_newyork"), 20, 20); bgMap4.boundingBoxOverride = false; bgMap4.setScrollFactors(1, 1); add(bgMap4); follower = new FlxSprite(400, 1500); follower.visible = false; add(follower); follower.velocity.Y = this.speed; FlxG.follow(follower, 20.0f); FlxG.followBounds(0, 0, int.MaxValue, 2000); int textSize = 2; #if __ANDROID__ textSize = 4; #endif heading = new FlxText(0, 50, FlxG.width, "Collection Incomplete"); heading.setFormat(FlxG.Content.Load <SpriteFont>("Lemonade/SMALL_PIXEL"), textSize, Lemonade_Globals.GAMEBOY_COLOR_4, FlxJustification.Center, Lemonade_Globals.GAMEBOY_COLOR_1); heading.setScrollFactors(0, 0); add(heading); string howWellDidYouGo = "Collected " + Lemonade_Globals.coins.ToString() + "\nfrom " + Lemonade_Globals.totalCoins.ToString() + " Coins "; credits = new FlxText(0, FlxG.height / 1.75f, FlxG.width, howWellDidYouGo); credits.setFormat(FlxG.Content.Load <SpriteFont>("Lemonade/SMALL_PIXEL"), textSize, Lemonade_Globals.GAMEBOY_COLOR_4, FlxJustification.Center, Lemonade_Globals.GAMEBOY_COLOR_1); credits.setScrollFactors(0, 0); credits.visible = false; add(credits); string ins = "Press X to Continue"; #if __ANDROID__ ins = "Press O to Continue"; #endif instruction = new FlxText(0, FlxG.height / 1.3f, FlxG.width, ins); instruction.setFormat(FlxG.Content.Load <SpriteFont>("Lemonade/SMALL_PIXEL"), textSize, Lemonade_Globals.GAMEBOY_COLOR_4, FlxJustification.Center, Lemonade_Globals.GAMEBOY_COLOR_1); instruction.setScrollFactors(0, 0); instruction.visible = false; add(instruction); if (Lemonade_Globals.coins == Lemonade_Globals.totalCoins) { heading.setFormat(FlxG.Content.Load <SpriteFont>("Lemonade/SMALL_PIXEL"), textSize, Lemonade_Globals.GAMEBOY_COLOR_4, FlxJustification.Center, Lemonade_Globals.GAMEBOY_COLOR_1); heading.text = "Complete Collection!!\nThe Lemonade Factory is saved."; instruction.setFormat(FlxG.Content.Load <SpriteFont>("Lemonade/SMALL_PIXEL"), textSize, Lemonade_Globals.GAMEBOY_COLOR_4, FlxJustification.Center, Lemonade_Globals.GAMEBOY_COLOR_1); string ins2 = "Press X to Continue"; #if __ANDROID__ ins2 = "Press O to Continue"; #endif instruction.text = ins2; //FlxU.openURL("http://initials.itch.io/slf2/download/Y9wdBOHe7a92Qpo9t5UJdz05HhZR5p10F0L6wfdP"); } tween = new Tweener(FlxG.height / 1.3f, FlxG.height / 1.2f, TimeSpan.FromSeconds(0.67f), XNATweener.Cubic.EaseInOut); tween.PingPong = true; tween.Start(); // play some music FlxG.playMp3("Lemonade/music/March", 0.75f); rain = new FlxGroup(); for (int i = 0; i < 150; i++) { FlxSprite rainDrop = new FlxSprite((FlxU.random() * FlxG.width * 2), -200 + (FlxU.random() * 1000)); rainDrop.loadGraphic("Lemonade/rain", true, false, 2, 2); rainDrop.frame = (int)FlxU.random(0, 6); rainDrop.velocity.Y = FlxU.random(350, 400); rain.add(rainDrop); } add(rain); splashes = new FlxEmitter(); splashes.createSprites("Lemonade/rain", 150, true, 0.0f, 0.0f); splashes.setXSpeed(-25, 25); splashes.setYSpeed(-30, 0); splashes.gravity = 1.0f; add(splashes); }
override public void create() { base.create(); Lemonade_Globals.totalCoins = Lemonade_Globals.calculateTotalCoins(); Console.WriteLine("Total coins = {0}", Lemonade_Globals.totalCoins); #if __ANDROID__ FlxG.BUILD_TYPE = FlxG.BUILD_TYPE_OUYA; #endif FlxTilemap bgMap = new FlxTilemap(); bgMap.auto = FlxTilemap.STRING; bgMap.indexOffset = -1; bgMap.loadTMXMap("Lemonade/levels/slf2/newyork/newyork_intro.tmx", "map", "bg", FlxXMLReader.TILES, FlxG.Content.Load <Texture2D>("Lemonade/bgtiles_newyork"), 20, 20); bgMap.boundingBoxOverride = false; bgMap.setScrollFactors(1, 1); add(bgMap); bgMap = new FlxTilemap(); bgMap.auto = FlxTilemap.STRING; bgMap.indexOffset = -1; bgMap.loadTMXMap("Lemonade/levels/slf2/newyork/newyork_intro.tmx", "map", "bg2", FlxXMLReader.TILES, FlxG.Content.Load <Texture2D>("Lemonade/bgtiles_newyork"), 20, 20); bgMap.boundingBoxOverride = false; bgMap.setScrollFactors(1, 1); add(bgMap); FlxTilemap bgMap3 = new FlxTilemap(); bgMap3.auto = FlxTilemap.STRING; bgMap3.indexOffset = -1; bgMap3.loadTMXMap("Lemonade/levels/slf2/newyork/newyork_intro.tmx", "map", "stars", FlxXMLReader.TILES, FlxG.Content.Load <Texture2D>("Lemonade/bgtiles_newyork"), 20, 20); bgMap3.boundingBoxOverride = false; bgMap3.setScrollFactors(0.5f, 0.5f); add(bgMap3); FlxTilemap bgMap4 = new FlxTilemap(); bgMap4.auto = FlxTilemap.STRING; bgMap4.indexOffset = -1; bgMap4.loadTMXMap("Lemonade/levels/slf2/newyork/newyork_intro.tmx", "map", "city", FlxXMLReader.TILES, FlxG.Content.Load <Texture2D>("Lemonade/bgtiles_newyork"), 20, 20); bgMap4.boundingBoxOverride = false; bgMap4.setScrollFactors(1, 1); add(bgMap4); follower = new FlxSprite(0, -100); follower.visible = false; add(follower); follower.velocity.Y = 450; FlxG.follow(follower, 20.0f); FlxG.followBounds(0, 0, int.MaxValue, 2000); FlxText text1 = new FlxText(0, FlxG.height / 2 - 50, FlxG.width, "Initials\nVideo\nGames\nPresents"); text1.setFormat(FlxG.Content.Load <SpriteFont>("Lemonade/SMALL_PIXEL"), 2, Lemonade_Globals.GAMEBOY_COLOR_4, FlxJustification.Center, Lemonade_Globals.GAMEBOY_COLOR_1); text1.setScrollFactors(1.5f, 1.5f); add(text1); credits = new FlxText(0, FlxG.height / 2 - 100, FlxG.width, "A Game by\nShane Brouwer"); credits.setFormat(FlxG.Content.Load <SpriteFont>("Lemonade/SMALL_PIXEL"), 2, Lemonade_Globals.GAMEBOY_COLOR_4, FlxJustification.Center, Lemonade_Globals.GAMEBOY_COLOR_1); credits.setScrollFactors(0, 0); credits.visible = false; add(credits); string ins = "Press X to Continue"; #if __ANDROID__ ins = "Press O to Continue"; #endif instruction = new FlxText(0, FlxG.height / 1.3f, FlxG.width, ins); instruction.setFormat(FlxG.Content.Load <SpriteFont>("Lemonade/SMALL_PIXEL"), 2, Lemonade_Globals.GAMEBOY_COLOR_4, FlxJustification.Center, Lemonade_Globals.GAMEBOY_COLOR_1); instruction.setScrollFactors(0, 0); instruction.visible = false; add(instruction); tween = new Tweener(FlxG.height / 1.3f, FlxG.height / 1.2f, TimeSpan.FromSeconds(0.67f), XNATweener.Cubic.EaseInOut); tween.PingPong = true; tween.Start(); // play some music FlxG.playMp3("Lemonade/music/Beyond", 0.75f); rain = new FlxGroup(); for (int i = 0; i < 150; i++) { FlxSprite rainDrop = new FlxSprite((FlxU.random() * FlxG.width), -200 + (FlxU.random() * 1000)); rainDrop.loadGraphic("Lemonade/rain", true, false, 2, 2); rainDrop.frame = (int)FlxU.random(0, 6); rainDrop.velocity.Y = FlxU.random(350, 400); rain.add(rainDrop); } add(rain); splashes = new FlxEmitter(); splashes.createSprites("Lemonade/rain", 150, true, 0.0f, 0.0f); splashes.setXSpeed(-25, 25); splashes.setYSpeed(-30, 0); splashes.gravity = 1.0f; add(splashes); }
override public void create() { base.create(); FlxG.playMp3("Lemonade/music/AmbulanceCalls", 0.5f); block = new FlxTileblock(0, 0, FlxG.width + 20, FlxG.height + 20); block.auto = FlxTileblock.FRAMENUMBER; block.frameNumber = 6; block.setScrollFactors(0, 0); block.loadTiles(FlxG.Content.Load <Texture2D>("Lemonade/fade"), 20, 20, 0); add(block); icons = new FlxGroup(); tweeners = new List <Vector3Tweener>(); for (int i = 0; i < 6; i++) { int offsetX = 75; int offsetY = 0; int offsetY2 = 0; #if __ANDROID__ offsetX = 400; offsetY = 100; offsetY2 = 120; #endif FlxSprite p1 = new FlxSprite(0 + (i * 36) + offsetX, 12); p1.loadGraphic("Lemonade/illustration/people", true, false, 302, 640); p1.frame = i; icons.add(p1); tweeners.Add(new Vector3Tweener(new Vector3(-100 + (i * 36) + offsetX, -290 + offsetY2, 0.1f), new Vector3(12 + offsetY + offsetX, 100, 1), 0.45f, Bounce.EaseOut)); } foreach (var item in tweeners) { item.Pause(); } add(icons); switch (Lemonade_Globals.location) { case "warehouse": selected = 0; break; case "military": selected = 1; break; case "newyork": selected = 2; break; case "sydney": selected = 3; break; case "management": selected = 4; break; case "factory": selected = 5; break; default: selected = 0; break; } tweeners[selected].Play(); timer = 5.0f; t1 = new FlxText(0, FlxG.height - 72, FlxG.width); t1.setFormat(null, 2, Lemonade_Globals.GAMEBOY_COLOR_1, FlxJustification.Center, Lemonade_Globals.GAMEBOY_COLOR_4); add(t1); t2 = new FlxText(0, 3, FlxG.width); t2.setFormat(null, 2, Lemonade_Globals.GAMEBOY_COLOR_1, FlxJustification.Center, Lemonade_Globals.GAMEBOY_COLOR_4); add(t2); }
override public void create() { base.create(); // play some music FlxG.playMp3("Lemonade/music/music_menu_1", 0.75f); // load some tile maps List <Dictionary <string, string> > bgString = FlxXMLReader.readNodesFromTmxFile("Lemonade/levels/slf2/newyork/bgnewyork.tmx", "map", "bg", FlxXMLReader.TILES); ny = new FlxTilemap(); ny.auto = FlxTilemap.STRING; ny.indexOffset = -1; ny.loadMap(bgString[0]["csvData"], FlxG.Content.Load <Texture2D>("Lemonade/bgtiles_newyork"), 20, 20); ny.boundingBoxOverride = true; ny.setScrollFactors(0, 0); ny.visible = false; add(ny); bgString = FlxXMLReader.readNodesFromTmxFile("Lemonade/levels/slf2/sydney/bgsydney.tmx", "map", "bg", FlxXMLReader.TILES); sydney = new FlxTilemap(); sydney.auto = FlxTilemap.STRING; sydney.indexOffset = -1; sydney.loadMap(bgString[0]["csvData"], FlxG.Content.Load <Texture2D>("Lemonade/bgtiles_sydney"), 20, 20); sydney.boundingBoxOverride = true; sydney.setScrollFactors(0, 0); sydney.visible = false; add(sydney); bgString = FlxXMLReader.readNodesFromTmxFile("Lemonade/levels/slf2/military/bgmilitary.tmx", "map", "bg", FlxXMLReader.TILES); miltary = new FlxTilemap(); miltary.auto = FlxTilemap.STRING; miltary.indexOffset = -1; miltary.loadMap(bgString[0]["csvData"], FlxG.Content.Load <Texture2D>("Lemonade/bgtiles_military"), 20, 20); miltary.boundingBoxOverride = true; miltary.setScrollFactors(0, 0); miltary.visible = false; add(miltary); //FlxG.mouse.show(FlxG.Content.Load<Texture2D>("Mode/cursor")); FlxButton b = new FlxButton((FlxG.width / 2) - 100, 150, startGame); b.loadGraphic(new FlxSprite().loadGraphic(FlxG.Content.Load <Texture2D>("Lemonade/button_ny")), new FlxSprite().loadGraphic(FlxG.Content.Load <Texture2D>("Lemonade/buttonPressed_ny"))); b.loadText(new FlxText(-20, 10, 100, "Sydney"), new FlxText(-20, 10, 100, "Sydney!")); buttons.add(b); b = new FlxButton(FlxG.width / 2, 150, startGame); b.loadGraphic(new FlxSprite().loadGraphic(FlxG.Content.Load <Texture2D>("Lemonade/button_ny")), new FlxSprite().loadGraphic(FlxG.Content.Load <Texture2D>("Lemonade/buttonPressed_ny"))); b.loadText(new FlxText(-20, 10, 100, "New York"), new FlxText(-20, 10, 100, "New York!")); buttons.add(b); b = new FlxButton((FlxG.width / 2) + 100, 150, startGame); b.loadGraphic(new FlxSprite().loadGraphic(FlxG.Content.Load <Texture2D>("Lemonade/button_ny")), new FlxSprite().loadGraphic(FlxG.Content.Load <Texture2D>("Lemonade/buttonPressed_ny"))); b.loadText(new FlxText(-20, 10, 100, "Military"), new FlxText(-20, 10, 100, "Military!")); buttons.add(b); for (int i = 1; i < 13; i++) { FlxButton a = new FlxButton(175 + (i * 45), 225, startGame); a.loadGraphic(new FlxSprite().loadGraphic(FlxG.Content.Load <Texture2D>("Lemonade/button_ny")), new FlxSprite().loadGraphic(FlxG.Content.Load <Texture2D>("Lemonade/buttonPressed_ny"))); a.loadText(new FlxText(-40, 10, 100, i.ToString()), new FlxText(-40, 10, 100, i.ToString() + "!")); buttons.add(a); } b = new FlxButton((FlxG.width / 2) - 100, 275, startMultiplayerGame); b.loadGraphic(new FlxSprite().loadGraphic(FlxG.Content.Load <Texture2D>("Lemonade/button_ny")), new FlxSprite().loadGraphic(FlxG.Content.Load <Texture2D>("Lemonade/buttonPressed_ny"))); b.loadText(new FlxText(-20, 10, 100, "Multiplayer"), new FlxText(-20, 10, 100, "Multiplayer!")); buttons.add(b); location = new FlxText(0, 50, FlxG.width); location.setFormat(FlxG.Content.Load <SpriteFont>("Lemonade/SMALL_PIXEL"), 3, Color.White, FlxJustification.Center, Color.Black); location.text = ""; add(location); addButtons(); FlxText badges = new FlxText(0, 330, 0, "Badges"); badges.setFormat(FlxG.Content.Load <SpriteFont>("Lemonade/SMALL_PIXEL"), 3, Color.White, FlxJustification.Left, Color.Black); add(badges); Color notDone = new Color(0.1f, 0.1f, 0.1f); badge1 = new FlxSprite((FlxG.width / 2) - 150, 330); badge1.loadGraphic(FlxG.Content.Load <Texture2D>("Lemonade/offscreenIcons"), true, false, 12, 12); badge1.frame = 2; badge1.color = notDone; add(badge1); badge2 = new FlxSprite((FlxG.width / 2) - 50, 330); badge2.loadGraphic(FlxG.Content.Load <Texture2D>("Lemonade/offscreenIcons"), true, false, 12, 12); badge2.frame = 3; badge2.color = notDone; add(badge2); badge3 = new FlxSprite((FlxG.width / 2) + 50, 330); badge3.loadGraphic(FlxG.Content.Load <Texture2D>("Lemonade/offscreenIcons"), true, false, 12, 12); badge3.frame = 4; badge3.color = notDone; add(badge3); badge4 = new FlxSprite((FlxG.width / 2) + 150, 330); badge4.loadGraphic(FlxG.Content.Load <Texture2D>("Lemonade/offscreenIcons"), true, false, 12, 12); badge4.frame = 5; badge4.color = notDone; add(badge4); tweenBounce = new Tweener(5.0f, 8.0f, TimeSpan.FromSeconds(1.12f), Elastic.EaseOut); tweenBounce.PingPong = true; try { FlxG.username = LoadFromDevice(); } catch { Console.WriteLine("Cannot load name from file"); } if (FlxG.username != "") { //_nameEntry.text = FlxG.username; FlxG.setHudText(3, "Username:\n" + FlxG.username); FlxG.setHudTextPosition(3, 50, FlxG.height - 30); FlxG.setHudTextScale(3, 2); } }
override public void create() { base.create(); #if __ANDROID__ FlxG.BUILD_TYPE = FlxG.BUILD_TYPE_OUYA; #endif FlxTilemap bgMap = new FlxTilemap(); bgMap.auto = FlxTilemap.STRING; bgMap.indexOffset = -1; bgMap.loadTMXMap("Lemonade/levels/slf2/newyork/newyork_intro.tmx", "map", "bg", FlxXMLReader.TILES, FlxG.Content.Load <Texture2D>("Lemonade/bgtiles_newyork"), 20, 20); bgMap.boundingBoxOverride = false; bgMap.setScrollFactors(1, 1); add(bgMap); bgMap = new FlxTilemap(); bgMap.auto = FlxTilemap.STRING; bgMap.indexOffset = -1; bgMap.loadTMXMap("Lemonade/levels/slf2/newyork/newyork_intro.tmx", "map", "bg2", FlxXMLReader.TILES, FlxG.Content.Load <Texture2D>("Lemonade/bgtiles_newyork"), 20, 20); bgMap.boundingBoxOverride = false; bgMap.setScrollFactors(1, 1); add(bgMap); FlxTilemap bgMap3 = new FlxTilemap(); bgMap3.auto = FlxTilemap.STRING; bgMap3.indexOffset = -1; bgMap3.loadTMXMap("Lemonade/levels/slf2/newyork/newyork_intro.tmx", "map", "stars", FlxXMLReader.TILES, FlxG.Content.Load <Texture2D>("Lemonade/bgtiles_newyork"), 20, 20); bgMap3.boundingBoxOverride = false; bgMap3.setScrollFactors(0.5f, 0.5f); add(bgMap3); FlxTilemap bgMap4 = new FlxTilemap(); bgMap4.auto = FlxTilemap.STRING; bgMap4.indexOffset = -1; bgMap4.loadTMXMap("Lemonade/levels/slf2/newyork/newyork_intro.tmx", "map", "city", FlxXMLReader.TILES, FlxG.Content.Load <Texture2D>("Lemonade/bgtiles_newyork"), 20, 20); bgMap4.boundingBoxOverride = false; bgMap4.setScrollFactors(1, 1); add(bgMap4); follower = new FlxSprite(0, -100); follower.visible = false; add(follower); follower.velocity.Y = 1450; follower.drag.Y = 10; FlxG.follow(follower, 20.0f); FlxG.followBounds(0, 0, int.MaxValue, 2000); FlxText text1 = new FlxText(0, FlxG.height / 2 - 50, FlxG.width, "GAME OVER"); text1.setFormat(FlxG.Content.Load <SpriteFont>("Lemonade/SMALL_PIXEL"), 2, Lemonade_Globals.GAMEBOY_COLOR_4, FlxJustification.Center, Lemonade_Globals.GAMEBOY_COLOR_1); text1.setScrollFactors(1.5f, 1.5f); add(text1); string howWellDidYouGo = "Collected " + Lemonade_Globals.coins.ToString() + " from " + Lemonade_Globals.totalCoins.ToString() + " Coins "; credits = new FlxText(0, FlxG.height / 2 - 100, FlxG.width, ""); credits.setFormat(FlxG.Content.Load <SpriteFont>("Lemonade/SMALL_PIXEL"), 2, Lemonade_Globals.GAMEBOY_COLOR_4, FlxJustification.Center, Lemonade_Globals.GAMEBOY_COLOR_1); credits.setScrollFactors(0, 0); credits.visible = true; add(credits); string ins = "Press X to Continue"; #if __ANDROID__ ins = "Press O to Continue"; #endif instruction = new FlxText(0, FlxG.height / 1.3f, FlxG.width, ins); instruction.setFormat(FlxG.Content.Load <SpriteFont>("Lemonade/SMALL_PIXEL"), 2, Lemonade_Globals.GAMEBOY_COLOR_4, FlxJustification.Center, Lemonade_Globals.GAMEBOY_COLOR_1); instruction.setScrollFactors(0, 0); instruction.visible = true; add(instruction); //rgb(237, 0, 142) tween = new Tweener(FlxG.height / 1.3f, FlxG.height / 1.2f, TimeSpan.FromSeconds(1.0f), XNATweener.Cubic.EaseInOut); tween.PingPong = true; tween.Start(); // play some music FlxG.playMp3("Lemonade/music/Lemonade1989Theme", 0.75f); FlxG.play("Lemonade/sfx/cw_sound15", 0.5f, false); }