public Loby(int x, int y, int width, int height) : base(x, y, width, height, false) { this.background = SeasideScramble.self.textureUtils.getExtendedTexture("SSCMaps", "TitleScreenBackground"); this.menuText = "The Loby" + System.Environment.NewLine + System.Environment.NewLine + "Choose a game mode"; this.shootingGalleryButton = new Button(new Rectangle(100, 300, 64 * 4, 32 * 4), SeasideScramble.self.textureUtils.getExtendedTexture("SSCUI", "ShootingGalleryButton"), new Rectangle(0, 0, 64, 32), 4f); this.backButton = new Button(new Rectangle(100, 100, 64, 64), SeasideScramble.self.textureUtils.getExtendedTexture("SSCUI", "BackButton"), new Rectangle(0, 0, 16, 16), 4f); }
private void processFoundTexture(string file, string relativePath, IModHelper Helper, IManifest Manifest) { Texture2DExtended textureExtended = new Texture2DExtended(Helper, Manifest, Path.Combine(relativePath, Path.GetFileName(file))); //ModCore.log("Found texture: " + textureExtended.Name); textureExtended.texture.Name = Manifest.UniqueID + "_" + this.name + "_" + textureExtended.Name; this.addTexture(textureExtended.Name, textureExtended); }
public void addTexture(string name, Texture2DExtended texture) { this.textures.Add(name, texture); }
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~// // Static Functions // //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~// public static void addTexture(IManifest ModManifest, string managerName, string textureName, Texture2DExtended Texture) { Texture.texture.Name = managerName + "." + textureName; TextureManagers[ModManifest.UniqueID][managerName].addTexture(textureName, Texture); }
/// <summary>Draws the dialogue box background. Takes in a color.</summary> /// <param name="texture">A custom menu texture to use.</param> public virtual void drawDialogueBoxBackground(Texture2DExtended texture, int x, int y, int width, int height, bool speaker, bool drawOnlyBox, Color color, string message = null, bool objectDialogueWithPortrait = false) { if (!drawOnlyBox) { return; } int height1 = Game1.graphics.GraphicsDevice.Viewport.TitleSafeArea.Height; int width1 = Game1.graphics.GraphicsDevice.Viewport.TitleSafeArea.Width; int dialogueX = 0; int num1 = y > Game1.graphics.GraphicsDevice.Viewport.TitleSafeArea.Y ? 0 : Game1.graphics.GraphicsDevice.Viewport.TitleSafeArea.Y; int num2 = 0; width = Math.Min(Game1.graphics.GraphicsDevice.Viewport.TitleSafeArea.Width, width); if (!Game1.isQuestion && Game1.currentSpeaker == null && (Game1.currentObjectDialogue.Count > 0 && !drawOnlyBox)) { width = (int)Game1.dialogueFont.MeasureString(Game1.currentObjectDialogue.Peek()).X + Game1.tileSize * 2; height = (int)Game1.dialogueFont.MeasureString(Game1.currentObjectDialogue.Peek()).Y + Game1.tileSize; x = width1 / 2 - width / 2; num2 = height > Game1.tileSize * 4 ? -(height - Game1.tileSize * 4) : 0; } Rectangle rectangle1 = new Rectangle(0, 0, Game1.tileSize, Game1.tileSize); int addedTileHeightForQuestions = -1; if (Game1.questionChoices.Count >= 3) { addedTileHeightForQuestions = Game1.questionChoices.Count - 3; } if (!drawOnlyBox && Game1.currentObjectDialogue.Count > 0) { if ((double)Game1.dialogueFont.MeasureString(Game1.currentObjectDialogue.Peek()).Y >= (double)(height - Game1.tileSize * 2)) { addedTileHeightForQuestions -= (int)(((double)(height - Game1.tileSize * 2) - (double)Game1.dialogueFont.MeasureString(Game1.currentObjectDialogue.Peek()).Y) / (double)Game1.tileSize) - 1; } else { height += (int)Game1.dialogueFont.MeasureString(Game1.currentObjectDialogue.Peek()).Y / 2; num2 -= (int)Game1.dialogueFont.MeasureString(Game1.currentObjectDialogue.Peek()).Y / 2; if ((int)Game1.dialogueFont.MeasureString(Game1.currentObjectDialogue.Peek()).Y / 2 > Game1.tileSize) { addedTileHeightForQuestions = 0; } } } if (Game1.currentSpeaker != null && Game1.isQuestion && Game1.currentSpeaker.CurrentDialogue.Peek().getCurrentDialogue().Substring(0, Game1.currentDialogueCharacterIndex).Contains(Environment.NewLine)) { ++addedTileHeightForQuestions; } rectangle1.Width = Game1.tileSize; rectangle1.Height = Game1.tileSize; rectangle1.X = Game1.tileSize; rectangle1.Y = Game1.tileSize * 2; Game1.spriteBatch.Draw(texture.getTexture(), new Rectangle(28 + x + dialogueX, 28 + y - Game1.tileSize * addedTileHeightForQuestions + num1 + num2, width - Game1.tileSize, height - Game1.tileSize + addedTileHeightForQuestions * Game1.tileSize), rectangle1, color); rectangle1.Y = 0; rectangle1.X = 0; Game1.spriteBatch.Draw(texture.getTexture(), new Vector2((float)(x + dialogueX), (float)(y - Game1.tileSize * addedTileHeightForQuestions + num1 + num2)), rectangle1, color); rectangle1.X = Game1.tileSize * 3; Game1.spriteBatch.Draw(texture.getTexture(), new Vector2((float)(x + width + dialogueX - Game1.tileSize), (float)(y - Game1.tileSize * addedTileHeightForQuestions + num1 + num2)), rectangle1, color); rectangle1.Y = Game1.tileSize * 3; Game1.spriteBatch.Draw(texture.getTexture(), new Vector2((float)(x + width + dialogueX - Game1.tileSize), (float)(y + height + num1 - Game1.tileSize + num2)), rectangle1, color); rectangle1.X = 0; Game1.spriteBatch.Draw(texture.getTexture(), new Vector2((float)(x + dialogueX), (float)(y + height + num1 - Game1.tileSize + num2)), rectangle1, color); rectangle1.X = Game1.tileSize * 2; rectangle1.Y = 0; Game1.spriteBatch.Draw(texture.getTexture(), new Rectangle(Game1.tileSize + x + dialogueX, y - Game1.tileSize * addedTileHeightForQuestions + num1 + num2, width - Game1.tileSize * 2, Game1.tileSize), rectangle1, color); rectangle1.Y = 3 * Game1.tileSize; Game1.spriteBatch.Draw(texture.getTexture(), new Rectangle(Game1.tileSize + x + dialogueX, y + height + num1 - Game1.tileSize + num2, width - Game1.tileSize * 2, Game1.tileSize), rectangle1, color); rectangle1.Y = Game1.tileSize * 2; rectangle1.X = 0; Game1.spriteBatch.Draw(texture.getTexture(), new Rectangle(x + dialogueX, y - Game1.tileSize * addedTileHeightForQuestions + num1 + Game1.tileSize + num2, Game1.tileSize, height - Game1.tileSize * 2 + addedTileHeightForQuestions * Game1.tileSize), rectangle1, color); rectangle1.X = 3 * Game1.tileSize; Game1.spriteBatch.Draw(texture.getTexture(), new Rectangle(x + width + dialogueX - Game1.tileSize, y - Game1.tileSize * addedTileHeightForQuestions + num1 + Game1.tileSize + num2, Game1.tileSize, height - Game1.tileSize * 2 + addedTileHeightForQuestions * Game1.tileSize), rectangle1, color); if (objectDialogueWithPortrait && Game1.objectDialoguePortraitPerson != null || speaker && Game1.currentSpeaker != null && (Game1.currentSpeaker.CurrentDialogue.Count > 0 && Game1.currentSpeaker.CurrentDialogue.Peek().showPortrait)) { Rectangle rectangle2 = new Rectangle(0, 0, 64, 64); NPC npc = objectDialogueWithPortrait ? Game1.objectDialoguePortraitPerson : Game1.currentSpeaker; string s = objectDialogueWithPortrait ? (Game1.objectDialoguePortraitPerson.Name.Equals(Game1.player.spouse) ? "$l" : "$neutral") : npc.CurrentDialogue.Peek().CurrentEmotion; switch (s) { case "$a": rectangle2 = new Rectangle(64, 128, 64, 64); break; case "$u": rectangle2 = new Rectangle(64, 64, 64, 64); break; case "$s": rectangle2 = new Rectangle(0, 64, 64, 64); break; case "$h": rectangle2 = new Rectangle(64, 0, 64, 64); break; case "$l": rectangle2 = new Rectangle(0, 128, 64, 64); break; default: rectangle2 = (s == "$k" || s == "$neutral" ? new Rectangle(0, 0, 64, 64) : Game1.getSourceRectForStandardTileSheet(npc.Portrait, Convert.ToInt32(npc.CurrentDialogue.Peek().CurrentEmotion.Substring(1)), -1, -1)); break; } Game1.spriteBatch.End(); Game1.spriteBatch.Begin(SpriteSortMode.Deferred, BlendState.NonPremultiplied, SamplerState.PointClamp, (DepthStencilState)null, (RasterizerState)null); if (npc.Portrait != null) { Game1.spriteBatch.Draw(Game1.mouseCursors, new Vector2((float)(dialogueX + x + Game1.tileSize * 12), (float)(height1 - 5 * Game1.tileSize - Game1.tileSize * addedTileHeightForQuestions - 256 + num1 + Game1.tileSize / 4 - 60 + num2)), new Rectangle(333, 305, 80, 87), Color.White, 0.0f, Vector2.Zero, 4f, SpriteEffects.None, 0.98f); Game1.spriteBatch.Draw(npc.Portrait, new Vector2((float)(dialogueX + x + Game1.tileSize * 12 + 32), (float)(height1 - 5 * Game1.tileSize - Game1.tileSize * addedTileHeightForQuestions - 256 + num1 + Game1.tileSize / 4 - 60 + num2)), rectangle2, Color.White, 0.0f, Vector2.Zero, 4f, SpriteEffects.None, 0.99f); } Game1.spriteBatch.End(); Game1.spriteBatch.Begin(); if (Game1.isQuestion) { Game1.spriteBatch.DrawString(Game1.dialogueFont, npc.displayName, new Vector2((float)(Game1.tileSize * 14 + Game1.tileSize / 2) - Game1.dialogueFont.MeasureString(npc.displayName).X / 2f + (float)dialogueX + (float)x, (float)(height1 - 5 * Game1.tileSize - Game1.tileSize * addedTileHeightForQuestions) - Game1.dialogueFont.MeasureString(npc.displayName).Y + (float)num1 + (float)(Game1.tileSize / 3) + (float)num2) + new Vector2(2f, 2f), new Color(150, 150, 150)); } Game1.spriteBatch.DrawString(Game1.dialogueFont, npc.Name.Equals("DwarfKing") ? Game1.content.LoadString("Strings\\StringsFromCSFiles:Game1.cs.3754") : (npc.Name.Equals("Lewis") ? Game1.content.LoadString("Strings\\StringsFromCSFiles:Game1.cs.3756") : npc.displayName), new Vector2((float)(dialogueX + x + Game1.tileSize * 14 + Game1.tileSize / 2) - Game1.dialogueFont.MeasureString(npc.Name.Equals("Lewis") ? Game1.content.LoadString("Strings\\StringsFromCSFiles:Game1.cs.3756") : npc.displayName).X / 2f, (float)(height1 - 5 * Game1.tileSize - Game1.tileSize * addedTileHeightForQuestions) - Game1.dialogueFont.MeasureString(npc.Name.Equals("Lewis") ? Game1.content.LoadString("Strings\\StringsFromCSFiles:Game1.cs.3756") : npc.displayName).Y + (float)num1 + (float)(Game1.tileSize / 3) + (float)(Game1.tileSize / 8) + (float)num2), Game1.textColor); } if (drawOnlyBox || Game1.nameSelectUp && (!Game1.messagePause || Game1.currentObjectDialogue == null)) { return; } string text = ""; if (Game1.currentSpeaker != null && Game1.currentSpeaker.CurrentDialogue.Count > 0) { if (Game1.currentSpeaker.CurrentDialogue.Peek() == null || Game1.currentSpeaker.CurrentDialogue.Peek().getCurrentDialogue().Length < Game1.currentDialogueCharacterIndex - 1) { Game1.dialogueUp = false; Game1.currentDialogueCharacterIndex = 0; Game1.playSound("dialogueCharacterClose"); Game1.player.forceCanMove(); return; } text = Game1.currentSpeaker.CurrentDialogue.Peek().getCurrentDialogue().Substring(0, Game1.currentDialogueCharacterIndex); } else if (message != null) { text = message; } else if (Game1.currentObjectDialogue.Count > 0) { text = Game1.currentObjectDialogue.Peek().Length <= 1 ? "" : Game1.currentObjectDialogue.Peek().Substring(0, Game1.currentDialogueCharacterIndex); } Vector2 position = (double)Game1.dialogueFont.MeasureString(text).X <= (double)(width1 - Game1.tileSize * 4 - dialogueX) ? (Game1.currentSpeaker == null || Game1.currentSpeaker.CurrentDialogue.Count <= 0 ? (message == null ? (!Game1.isQuestion ? new Vector2((float)(width1 / 2) - Game1.dialogueFont.MeasureString(Game1.currentObjectDialogue.Count == 0 ? "" : Game1.currentObjectDialogue.Peek()).X / 2f + (float)dialogueX, (float)(y + Game1.pixelZoom + num2)) : new Vector2((float)(width1 / 2) - Game1.dialogueFont.MeasureString(Game1.currentObjectDialogue.Count == 0 ? "" : Game1.currentObjectDialogue.Peek()).X / 2f + (float)dialogueX, (float)(height1 - Game1.tileSize * addedTileHeightForQuestions - 4 * Game1.tileSize - (Game1.tileSize / 4 + (Game1.questionChoices.Count - 2) * Game1.tileSize) + num1 + num2))) : new Vector2((float)(width1 / 2) - Game1.dialogueFont.MeasureString(text).X / 2f + (float)dialogueX, (float)(y + Game1.tileSize * 3 / 2 + Game1.pixelZoom))) : new Vector2((float)(width1 / 2) - Game1.dialogueFont.MeasureString(Game1.currentSpeaker.CurrentDialogue.Peek().getCurrentDialogue()).X / 2f + (float)dialogueX, (float)(height1 - Game1.tileSize * addedTileHeightForQuestions - 4 * Game1.tileSize - Game1.tileSize / 4 + num1 + num2))) : new Vector2((float)(Game1.tileSize * 2 + dialogueX), (float)(height1 - Game1.tileSize * addedTileHeightForQuestions - 4 * Game1.tileSize - Game1.tileSize / 4 + num1 + num2)); if (!drawOnlyBox) { Game1.spriteBatch.DrawString(Game1.dialogueFont, text, position + new Vector2(3f, 0.0f), Game1.textShadowColor); Game1.spriteBatch.DrawString(Game1.dialogueFont, text, position + new Vector2(3f, 3f), Game1.textShadowColor); Game1.spriteBatch.DrawString(Game1.dialogueFont, text, position + new Vector2(0.0f, 3f), Game1.textShadowColor); Game1.spriteBatch.DrawString(Game1.dialogueFont, text, position, Game1.textColor); } if ((double)Game1.dialogueFont.MeasureString(text).Y <= (double)Game1.tileSize) { num1 += Game1.tileSize; } if (Game1.isQuestion && !Game1.dialogueTyping) { for (int index = 0; index < Game1.questionChoices.Count; ++index) { if (Game1.currentQuestionChoice == index) { position.X = (float)(Game1.tileSize * 5 / 4 + dialogueX + x); position.Y = (float)(height1 - (5 + addedTileHeightForQuestions + 1) * Game1.tileSize) + (text.Trim().Length > 0 ? Game1.dialogueFont.MeasureString(text).Y : 0.0f) + (float)(Game1.tileSize * 2) + (float)((Game1.tileSize / 2 + Game1.tileSize / 4) * index) - (float)(Game1.tileSize / 4 + (Game1.questionChoices.Count - 2) * Game1.tileSize) + (float)num1 + (float)num2; Game1.spriteBatch.End(); Game1.spriteBatch.Begin(SpriteSortMode.Deferred, BlendState.NonPremultiplied, SamplerState.PointClamp, (DepthStencilState)null, (RasterizerState)null); Game1.spriteBatch.Draw(Game1.objectSpriteSheet, position + new Vector2((float)Math.Cos((double)Game1.currentGameTime.TotalGameTime.Milliseconds * Math.PI / 512.0) * 3f, 0.0f), GameLocation.getSourceRectForObject(26), Color.White, 0.0f, Vector2.Zero, (float)Game1.pixelZoom, SpriteEffects.None, 1f); Game1.spriteBatch.End(); Game1.spriteBatch.Begin(); position.X = (float)(Game1.tileSize * 5 / 2 + dialogueX + x); position.Y = (float)(height1 - (5 + addedTileHeightForQuestions + 1) * Game1.tileSize) + (text.Trim().Length > 1 ? Game1.dialogueFont.MeasureString(text).Y : 0.0f) + (float)(Game1.tileSize * 3 / 2 + Game1.tileSize / 2) - (float)((Game1.questionChoices.Count - 2) * Game1.tileSize) + (float)((Game1.tileSize / 2 + Game1.tileSize / 4) * index) + (float)num1 + (float)num2; Game1.spriteBatch.DrawString(Game1.dialogueFont, Game1.questionChoices[index].responseText, position, Game1.textColor); } else { position.X = (float)(Game1.tileSize * 2 + dialogueX + x); position.Y = (float)(height1 - (5 + addedTileHeightForQuestions + 1) * Game1.tileSize) + (text.Trim().Length > 1 ? Game1.dialogueFont.MeasureString(text).Y : 0.0f) + (float)(Game1.tileSize * 3 / 2 + Game1.tileSize / 2) - (float)((Game1.questionChoices.Count - 2) * Game1.tileSize) + (float)((Game1.tileSize / 2 + Game1.tileSize / 4) * index) + (float)num1 + (float)num2; Game1.spriteBatch.DrawString(Game1.dialogueFont, Game1.questionChoices[index].responseText, position, Game1.unselectedOptionColor); } } } else if (Game1.numberOfSelectedItems != -1 && !Game1.dialogueTyping) { this.drawItemSelectDialogue(x, y, dialogueX, num1 + num2, height1, addedTileHeightForQuestions, text); } if (drawOnlyBox || Game1.dialogueTyping || message != null) { return; } Game1.spriteBatch.Draw(Game1.mouseCursors, new Vector2((float)(x + dialogueX + width - Game1.tileSize * 3 / 2), (float)(y + height + num1 + num2 - Game1.tileSize * 3 / 2) - Game1.dialogueButtonScale), Game1.getSourceRectForStandardTileSheet(Game1.mouseCursors, Game1.dialogueButtonShrinking || (double)Game1.dialogueButtonScale >= (double)(Game1.tileSize / 8) ? 2 : 3, -1, -1), color, 0.0f, Vector2.Zero, 1f, SpriteEffects.None, 0.9999999f); }
/// <summary> /// Adds a new texture at a specific layer depth. /// </summary> /// <param name="texture"></param> /// <param name="index"></param> public void addTexture(Texture2DExtended texture, int index) { this.textureLayers.Insert(index, texture); }
/// <summary> /// Adds a new texture as the top layer. /// </summary> /// <param name="texture"></param> public void addTexture(Texture2DExtended texture) { this.textureLayers.Add(texture); }
public CharacterSelectScreen(int x, int y, int width, int height) : base(x, y, width, height, false) { this.background = SeasideScramble.self.textureUtils.getExtendedTexture("SSCMaps", "TitleScreenBackground"); this.menuTitle = "Character Selection"; this.playerDisplayLocations = new Dictionary <SSCEnums.PlayerID, Vector2>() { { SSCEnums.PlayerID.One, new Vector2(SeasideScramble.self.camera.viewport.Width * .2f, SeasideScramble.self.camera.viewport.Height * .5f) }, { SSCEnums.PlayerID.Two, new Vector2(SeasideScramble.self.camera.viewport.Width * .4f, SeasideScramble.self.camera.viewport.Height * .5f) }, { SSCEnums.PlayerID.Three, new Vector2(SeasideScramble.self.camera.viewport.Width * .6f, SeasideScramble.self.camera.viewport.Height * .5f) }, { SSCEnums.PlayerID.Four, new Vector2(SeasideScramble.self.camera.viewport.Width * .8f, SeasideScramble.self.camera.viewport.Height * .5f) }, }; this.possibleColors = new List <Color>() { Color.PaleVioletRed, Color.LightSkyBlue, Color.LawnGreen, Color.LightGoldenrodYellow, Color.HotPink, Color.Red, Color.Purple }; this.playerColorIndex = new Dictionary <SSCEnums.PlayerID, int>() { { SSCEnums.PlayerID.One, -1 }, { SSCEnums.PlayerID.Two, -1 }, { SSCEnums.PlayerID.Three, -1 }, { SSCEnums.PlayerID.Four, -1 }, }; this.inputDelays = new Dictionary <SSCEnums.PlayerID, int>() { { SSCEnums.PlayerID.One, 0 }, { SSCEnums.PlayerID.Two, 0 }, { SSCEnums.PlayerID.Three, 0 }, { SSCEnums.PlayerID.Four, 0 }, }; SeasideScramble.self.camera.snapToPosition(new Vector2(0, 0)); this.animatedSprites = new Dictionary <string, StardustCore.Animations.AnimatedSprite>(); this.animatedSprites.Add("P1AButton", new StardustCore.Animations.AnimatedSprite("P1AButton", this.playerDisplayLocations[SSCEnums.PlayerID.One] + new Vector2(0, 100), new AnimationManager(SeasideScramble.self.textureUtils.getExtendedTexture("SSCUI", "AButton"), new Animation(0, 0, 28, 27)), Color.White)); this.animatedSprites.Add("P2AButton", new StardustCore.Animations.AnimatedSprite("P2AButton", this.playerDisplayLocations[SSCEnums.PlayerID.Two] + new Vector2(0, 100), new AnimationManager(SeasideScramble.self.textureUtils.getExtendedTexture("SSCUI", "AButton"), new Animation(0, 0, 28, 27)), Color.White)); this.animatedSprites.Add("P3AButton", new StardustCore.Animations.AnimatedSprite("P3AButton", this.playerDisplayLocations[SSCEnums.PlayerID.Three] + new Vector2(0, 100), new AnimationManager(SeasideScramble.self.textureUtils.getExtendedTexture("SSCUI", "AButton"), new Animation(0, 0, 28, 27)), Color.White)); this.animatedSprites.Add("P4AButton", new StardustCore.Animations.AnimatedSprite("P4AButton", this.playerDisplayLocations[SSCEnums.PlayerID.Four] + new Vector2(0, 100), new AnimationManager(SeasideScramble.self.textureUtils.getExtendedTexture("SSCUI", "AButton"), new Animation(0, 0, 28, 27)), Color.White)); this.animatedSprites.Add("P1Click", new StardustCore.Animations.AnimatedSprite("P1Click", this.playerDisplayLocations[SSCEnums.PlayerID.One] + new Vector2(0, 150), new AnimationManager(SeasideScramble.self.textureUtils.getExtendedTexture("SSCUI", "MouseClick"), new Animation(0, 0, 31, 32), new Dictionary <string, List <Animation> >() { { "Click1", new List <Animation>() { new Animation(0, 0, 31, 32, 60), new Animation(31, 0, 31, 32, 60) } } }, "Click1"), Color.White)); this.animatedSprites.Add("P1Color", new StardustCore.Animations.AnimatedSprite("P1Color", new Vector2(this.playerDisplayLocations[SSCEnums.PlayerID.One].X, this.playerDisplayLocations[SSCEnums.PlayerID.One].Y + 250), new AnimationManager(SeasideScramble.self.textureUtils.getExtendedTexture("SSCUI", "BlankTexture"), new Animation(0, 0, 32, 32)), Color.White)); this.animatedSprites.Add("P2Color", new StardustCore.Animations.AnimatedSprite("P2Color", new Vector2(this.playerDisplayLocations[SSCEnums.PlayerID.Two].X, this.playerDisplayLocations[SSCEnums.PlayerID.One].Y + 250), new AnimationManager(SeasideScramble.self.textureUtils.getExtendedTexture("SSCUI", "BlankTexture"), new Animation(0, 0, 32, 32)), Color.White)); this.animatedSprites.Add("P3Color", new StardustCore.Animations.AnimatedSprite("P3Color", new Vector2(this.playerDisplayLocations[SSCEnums.PlayerID.Three].X, this.playerDisplayLocations[SSCEnums.PlayerID.One].Y + 250), new AnimationManager(SeasideScramble.self.textureUtils.getExtendedTexture("SSCUI", "BlankTexture"), new Animation(0, 0, 32, 32)), Color.White)); this.animatedSprites.Add("P4Color", new StardustCore.Animations.AnimatedSprite("P4Color", new Vector2(this.playerDisplayLocations[SSCEnums.PlayerID.Four].X, this.playerDisplayLocations[SSCEnums.PlayerID.One].Y + 250), new AnimationManager(SeasideScramble.self.textureUtils.getExtendedTexture("SSCUI", "BlankTexture"), new Animation(0, 0, 32, 32)), Color.White)); this.buttons = new Dictionary <string, Button>(); this.buttons.Add("P1PrevButton", new Button("P1PrevButton", new Rectangle((int)this.playerDisplayLocations[SSCEnums.PlayerID.One].X - 64, (int)this.playerDisplayLocations[SSCEnums.PlayerID.One].Y + 250, 64, 64), SeasideScramble.self.textureUtils.getExtendedTexture("SSCUI", "lastPageButton"), new Rectangle(0, 0, 32, 32), 2f)); this.buttons.Add("P1NextButton", new Button("P1NextButton", new Rectangle((int)this.playerDisplayLocations[SSCEnums.PlayerID.One].X + 64, (int)this.playerDisplayLocations[SSCEnums.PlayerID.One].Y + 250, 64, 64), SeasideScramble.self.textureUtils.getExtendedTexture("SSCUI", "nextPageButton"), new Rectangle(0, 0, 32, 32), 2f)); this.buttons.Add("P2PrevButton", new Button("P2PrevButton", new Rectangle((int)this.playerDisplayLocations[SSCEnums.PlayerID.Two].X - 64, (int)this.playerDisplayLocations[SSCEnums.PlayerID.Two].Y + 250, 64, 64), SeasideScramble.self.textureUtils.getExtendedTexture("SSCUI", "lastPageButton"), new Rectangle(0, 0, 32, 32), 2f)); this.buttons.Add("P2NextButton", new Button("P2NextButton", new Rectangle((int)this.playerDisplayLocations[SSCEnums.PlayerID.Two].X + 64, (int)this.playerDisplayLocations[SSCEnums.PlayerID.Two].Y + 250, 64, 64), SeasideScramble.self.textureUtils.getExtendedTexture("SSCUI", "nextPageButton"), new Rectangle(0, 0, 32, 32), 2f)); this.buttons.Add("P3PrevButton", new Button("P3PrevButton", new Rectangle((int)this.playerDisplayLocations[SSCEnums.PlayerID.Three].X - 64, (int)this.playerDisplayLocations[SSCEnums.PlayerID.Three].Y + 250, 64, 64), SeasideScramble.self.textureUtils.getExtendedTexture("SSCUI", "lastPageButton"), new Rectangle(0, 0, 32, 32), 2f)); this.buttons.Add("P3NextButton", new Button("P3NextButton", new Rectangle((int)this.playerDisplayLocations[SSCEnums.PlayerID.Three].X + 64, (int)this.playerDisplayLocations[SSCEnums.PlayerID.Three].Y + 250, 64, 64), SeasideScramble.self.textureUtils.getExtendedTexture("SSCUI", "nextPageButton"), new Rectangle(0, 0, 32, 32), 2f)); this.buttons.Add("P4PrevButton", new Button("P4PrevButton", new Rectangle((int)this.playerDisplayLocations[SSCEnums.PlayerID.Four].X - 64, (int)this.playerDisplayLocations[SSCEnums.PlayerID.Four].Y + 250, 64, 64), SeasideScramble.self.textureUtils.getExtendedTexture("SSCUI", "lastPageButton"), new Rectangle(0, 0, 32, 32), 2f)); this.buttons.Add("P4NextButton", new Button("P4NextButton", new Rectangle((int)this.playerDisplayLocations[SSCEnums.PlayerID.Four].X + 64, (int)this.playerDisplayLocations[SSCEnums.PlayerID.Four].Y + 250, 64, 64), SeasideScramble.self.textureUtils.getExtendedTexture("SSCUI", "nextPageButton"), new Rectangle(0, 0, 32, 32), 2f)); //this.animatedSprites.Add("P1PrevColor", new StardustCore.Animations.AnimatedSprite("P1PrevColor", this.playerDisplayLocations[SSCEnums.PlayerID.One] + new Vector2(0, 200), new AnimationManager(SeasideScramble.self.textureUtils.getExtendedTexture("SSCUI", "lastPageButton"), new Animation(0, 0, 32, 32)), Color.White)); //this.animatedSprites.Add("P1NextColor", new StardustCore.Animations.AnimatedSprite("P1NextColor", this.playerDisplayLocations[SSCEnums.PlayerID.One] + new Vector2(64, 200), new AnimationManager(SeasideScramble.self.textureUtils.getExtendedTexture("SSCUI", "nextPageButton"), new Animation(0, 0, 32, 32)), Color.White)); this.oldMousePos = new Vector2(Game1.getMousePosition().X, Game1.getMousePosition().Y); }