public PlayerScreen() : base() { this.scene = new Scene(); compass = new UICompass(); compass.Scale = new Vector2(0.35f, 0.05f); compass.Position = new Vector2(0, -0.85f); crosshair = new UIButton(ResourceManager.Inst.GetTexture("UI/Game/crossHair.dds"), Vector4.One, string.Empty); crosshair.Position = Vector2.Zero; crosshair.Scale = Vector2.One * 0.035f; scoreLabel = new UIButton(null, Vector4.One, "Score:"); scoreLabel.Position = new Vector2(0.7f, 0.85f); journalStatus = new UIButton(null, Vector4.One, "Journal Updated!"); journalStatus.Position = new Vector2(-0.7f, 0.85f); journalStatus.SetVisible(false); interactStatus = new UIButton(null, Vector4.One, "Examine Object"); interactStatus.Position = new Vector2(-0.7f, -0.85f); interactStatus.SetVisible(false); interactButton = new UIButton(ResourceManager.Inst.GetTexture("UI/Game/interact.dds"), Vector4.One, string.Empty); interactButton.Position = crosshair.Position; interactButton.Scale = crosshair.Scale * 1.15f; interactButton.SetVisible(false); list = new UIList(); list.ItemColor = new Vector4(0.15f, 0.15f, 0.15f, 1.0f); list.Position = new Vector2(0.5f, 0); list.Scale = new Vector2(0.25f, 0.5f); string[] testStrings = new string[] { "Hello", "A Carton of Cigarettes", "Oh boy", "I hope this works", "25 or 6 to 4", "Rawr", "Christ", "El Captain", "John Wayne", "Walter White", "Stanford Cow", "Dr. Evil", "Tom Hanks", "Lindsey Lohan", "Raptor Jesus", "Timothy Leary", "Bauldur", "Frank Lloyd Wright", "Pink Floyd", "The Beatles", "JoCo", "Is this twenty yet??", }; list.Items.AddRange(testStrings); list.SetColor(new Vector4(0.15f, 0.15f, 0.15f, 1.0f)); //this.controls.Add(list); this.controls.Add(crosshair); this.controls.Add(journalStatus); this.controls.Add(compass); this.controls.Add(interactStatus); this.controls.Add(interactButton); this.controls.Add(scoreLabel); }
public PlayerScreen() : base() { inst = this; compass = new UICompass(); compass.Scale = new Vector2(0.35f, 0.05f); compass.Position = new Vector2(0, -0.85f); crosshair = new UIButton(ResourceManager.Inst.GetTexture("UI/Game/crossHair.dds"), Vector4.One, string.Empty); crosshair.Position = Vector2.Zero; crosshair.Scale = Vector2.One * 0.035f; journalStatus = new UIButton(null, Vector4.One, "Journal Updated!"); journalStatus.Position = new Vector2(0, 0.15f);// new Vector2(-0.7f, 0.85f); journalStatus.SetVisible(false); interactStatus = new UIButton(null, Vector4.One, "Examine Object"); interactStatus.Position = new Vector2(-0.7f, -0.85f); interactStatus.SetVisible(false); interactButton = new UIButton(ResourceManager.Inst.GetTexture("UI/Game/interact.dds"), Vector4.One, string.Empty); interactButton.Position = Vector2.Zero; interactButton.Scale = Vector2.One * 0.035f * 1.15f; interactButton.SetVisible(false); blackFade = new UIButton(null, Vector4.Zero, string.Empty); blackFade.Position = Vector2.Zero; blackFade.Scale = Vector2.One; blackFade.SetVisible(false); creditsLabel = new UIButton(null, Vector4.One, "Created by Matt Vitelli - Summer 2012"); creditsLabel.Position = Vector2.Zero; creditsLabel.Scale = Vector2.One; creditsLabel.SetVisible(false); list = new UIList(); list.ItemColor = new Vector4(0.15f, 0.15f, 0.15f, 1.0f); list.Position = new Vector2(0.5f, 0); list.Scale = new Vector2(0.25f, 0.5f); string[] testStrings = new string[] { "Hello", "A Carton of Cigarettes", "Oh boy", "I hope this works", "25 or 6 to 4", "Rawr", "Christ", "El Captain", "John Wayne", "Walter White", "Stanford Cow", "Dr. Evil", "Tom Hanks", "Lindsey Lohan", "Raptor Jesus", "Timothy Leary", "Bauldur", "Frank Lloyd Wright", "Pink Floyd", "The Beatles", "JoCo", "Is this twenty yet??", }; list.Items.AddRange(testStrings); list.SetColor(new Vector4(0.15f, 0.15f, 0.15f, 1.0f)); //this.controls.Add(list); healthBarTexture = (Texture2D)ResourceManager.Inst.GetTexture("UI/Game/healthBar.dds").GetTexture(); healthBarTexture2 = (Texture2D)ResourceManager.Inst.GetTexture("UI/Game/healthBar2.dds").GetTexture(); this.controls.Add(crosshair); this.controls.Add(journalStatus); this.controls.Add(compass); this.controls.Add(interactStatus); this.controls.Add(interactButton); this.controls.Add(blackFade); this.controls.Add(creditsLabel); this.scene = new Scene(); compass.AddCustomMarker(scene.FindEntity("Tent").Transformation, ResourceManager.Inst.GetTexture("UI/Game/Home.dds")); bgSound = new Sound2D("Crickets", true, false); bgSound.Paused = false; }