diff options
| author | aldrikboy <aldrikboy@gmail.com> | 2017-12-29 17:27:49 +0100 |
|---|---|---|
| committer | aldrikboy <aldrikboy@gmail.com> | 2017-12-29 17:27:49 +0100 |
| commit | da38e93e55b6ff46a53dcd9d2be393149089d329 (patch) | |
| tree | c19fdb964ee6f8dd8dd3102b22de541828850983 /Penguloon/Scenes/CreditsScene.cs | |
| parent | 5373e919a0d9e389fc2076963f610d044c21ccb5 (diff) | |
obejct info, new level selector, credits haHA
Diffstat (limited to 'Penguloon/Scenes/CreditsScene.cs')
| -rw-r--r-- | Penguloon/Scenes/CreditsScene.cs | 182 |
1 files changed, 182 insertions, 0 deletions
diff --git a/Penguloon/Scenes/CreditsScene.cs b/Penguloon/Scenes/CreditsScene.cs new file mode 100644 index 0000000..f07e5e1 --- /dev/null +++ b/Penguloon/Scenes/CreditsScene.cs @@ -0,0 +1,182 @@ +using Microsoft.Xna.Framework; +using Microsoft.Xna.Framework.Audio; +using Microsoft.Xna.Framework.Graphics; +using Microsoft.Xna.Framework.Input.Touch; +using Penguloon.Scenes; +using System; +using System.Collections.Generic; + +namespace Penguloon.Scenes +{ + class CreditsScene : SceneBase + { + public float PosY { get; set; } + + public SpriteFont Font { get; set; } + public int TextHeight { get; set; } + + public DateTime ViewDate { get; set; } + + public CreditsScene(Main main) : base(main) + { + Font = ContentManager.GetFont(StaticUIValues.StatsFont); + TextHeight = (int)Font.MeasureString("zulul").Y * 2; + + ViewDate = DateTime.Now; + } + + public override void CreateControls() + { + + } + + public override void Draw(float deltaTime) + { + base.Draw(deltaTime); + + // background + Main.SpriteBatch.Draw(ContentManager.GetTexture("UI/background"), + destinationRectangle: new Rectangle(0, 0, (int)StaticUIValues.ScreenViewport.X, (int)StaticUIValues.ScreenViewport.Y)); + + DrawSnowflakes(); + + DrawCredits(); + } + + public List<string> CreditList { get; set; } = new List<string>() + { + "Executive Producer", + "Team Lead", + "Art Director", + "Creative Director", + "Lead Animator", + "Lead Artist", + "Lead Character Artist", + "Lead Designer", + "Load Programmer", + "Lead Technical Artist", + "Producer", + "Additional Production", + "Programming", + "Additional Programming", + "Level Designer", + "Sound Producer", + "Audio Supervisor", + "lead Composer", + "Lead Sound Designer", + "Music", + "Sound Design", + "Sound Editor", + "Quality Assurance Manager", + "Test Coordinator", + "Test Leads", + "Lead Game Testers", + "Game Testers", + "Senior Lead Testers", + "Additional Game Testing", + "In-Game Support Team", + "Marketing Team", + "Legal Manager", + "President", + "CEO", + "Commercial Director", + "Sales Manager", + "Marketing Manager", + "PR Manager", + "Logistics", + "Sales Director", + "Product Manager", + "Managing Director", + "Community Manager", + "Vice President", + "Trade Marketing", + "Social Media Executive", + "Publishing", + "Associate Tools Engineer", + "Digital Coordinator", + "IP Strategy", + "Digital Business Manager", + "Digital Coordinator", + "Adinistration", + "Administrative Assistant", + "Operations Analyst", + "Applications Support Specialist", + "Travel Adinistrator", + "Senior Vice President", + "Director of Retail Marketing", + "E-Commerce Specialist", + "Brand Marketing", + "Brand Manager", + "Event Manager", + "Event Planner", + "Community Specialist", + "Interactive Designer", + "Senior Associate Attorney", + "QA Manager", + "QA Project Leads", + "CQC Manager", + "Senior CQC Coordinator", + "CQC Coordinators", + "CQC Testers", + "Digital Content Manager", + "Finaince Manager", + "Accountant", + "Sales Representative", + "Business Administrator", + "Marketing Assistant", + "Localization Manager", + "Product Support", + "Business Development", + "Special Thanks", + }; + + private void DrawCredits() + { + int marginTop = (int)(StaticUIValues.ScreenViewport.Y / 2) + (int)PosY; + string name = "Aldrik Ramaekers"; + + Color headerForeColor = Color.FromNonPremultiplied(111, 138, 183, 255); + Color headerBackColor = Color.Black; + + Color nameForeColor = Color.White; + Color nameBackColor = Color.Black; + + // game design + DrawText(Font, "Game Design", new Vector2(0, marginTop + TextHeight), new Vector2(StaticUIValues.ScreenViewport.X, 0), TextAllignment.CenterTop, headerForeColor, headerBackColor, 2); + DrawText(Font, name, new Vector2(0, marginTop + TextHeight + (TextHeight / 2)), new Vector2(StaticUIValues.ScreenViewport.X, 0), TextAllignment.CenterTop, nameForeColor, nameBackColor, 2); + + for (int i = 0; i < CreditList.Count; i++) + { + int posX = i % 2 == 0 ? 100 : (int)StaticUIValues.ScreenViewport.X - 100; + TextAllignment align = i % 2 == 0 ? TextAllignment.LeftTop : TextAllignment.RightTop; + + int index = i + 2; + + int posY = marginTop + ((int)(TextHeight * 0.7) * (index * 2)); + + if (posY < -200) continue; + if (posY > StaticUIValues.ScreenViewport.Y) break; + + if (i == CreditList.Count - 1) + name = "My cat"; + else + name = "Aldrik Ramaekers"; + + // executive producer + DrawText(Font, CreditList[i], new Vector2(posX, posY), new Vector2(0, 0), align, headerForeColor, headerBackColor, 2); + DrawText(Font, name, new Vector2(posX, posY + (TextHeight / 2)), new Vector2(0, 0), align, nameForeColor, nameBackColor, 2); + } + } + + public override void Update(float deltaTime, TouchLocation[] touchLocations) + { + base.Update(deltaTime, touchLocations); + + if (touchLocations.Length != 0) + if ((DateTime.Now - ViewDate).TotalMilliseconds > 200) + SceneManager.SelectedScene = SelectedScene.Menu; + + PosY -= 100 * deltaTime; + } + } +}
\ No newline at end of file |
