public void Intro4() { m_boss.PlayAnimation(); m_bossShadow.ChangeSprite("EnemyFairyGhostBossIdle_Character"); m_bossShadow.PlayAnimation(); Tween.To(m_boss, 0.5f, Tween.EaseNone, "delay", "0.5", "Opacity", "1"); Tween.To(m_bossShadow, 0.5f, Tween.EaseNone, "delay", "0.5", "Opacity", "0"); Tween.AddEndHandlerToLastTween(this, "DisplayBossTitle", "The Forgotten", m_boss.Name, "Intro5"); }
public void RunFountainCutscene2() { StartShake(); SoundManager.PlaySound("Cutsc_StatueCrumble"); m_fountain.ChangeSprite("FountainOfYouthShatter_Character"); m_fountain.PlayAnimation(false); Player.AttachedLevel.ImpactEffectPool.DisplayFountainShatterSmoke(m_fountain); Tween.RunFunction(2f, this, "DisplaySecondBoss"); Tween.RunFunction(2f, this, "RunFountainCutscene3"); }
protected override bool OnCast(Entity source) { var obj = source.GameObject; if (_shadowSprite == null) { _shadowSprite = new ObjContainer(obj.SpriteName) { OutlineColour = Color.Blue, OutlineWidth = 2, TextureColor = Color.Black } } ; else { _shadowSprite.ChangeSprite(obj.SpriteName); } _shadowSprite.Position = obj.Position; _shadowSprite.Flip = obj.Flip; _shadowSprite.Scale = Vector2.Zero; _shadowSprite.Visible = true; _shadowSprite.GoToFrame(obj.CurrentFrame); for (var i = 0; i < obj.NumChildren; i++) { var src = obj.GetChildAt(i) as SpriteObj; var dst = _shadowSprite.GetChildAt(i) as SpriteObj; var show = src.Visible; if (source is Player && ( i == 16 || ( Player.Class is Classes.Spellthief && (i == 10 || i == 11) ))) { show = false; } dst.ChangeSprite(src.SpriteName); dst.Visible = show; } Tween.To(_shadowSprite, 0.4f, Linear.EaseNone, "ScaleX", obj.ScaleX.ToString(), "ScaleY", obj.ScaleY.ToString()); Effects.InverseEmitEffect.Display(_shadowSprite.Position); return(true); }
public void ActivateArchitect() { Player.LockControls(); Player.CurrentSpeed = 0f; m_architectIcon.Visible = false; m_architectRenovating = true; m_architect.ChangeSprite("ArchitectPull_Character"); (m_architect.GetChildAt(1) as SpriteObj).PlayAnimation(false); m_screw.AnimationDelay = 0.0333333351f; Tween.RunFunction(0.5f, m_architect.GetChildAt(0), "PlayAnimation", true); Tween.RunFunction(0.5f, typeof(SoundManager), "PlaySound", "Architect_Lever"); Tween.RunFunction(1f, typeof(SoundManager), "PlaySound", "Architect_Screw"); Tween.RunFunction(1f, m_screw, "PlayAnimation", false); Tween.By(m_architectBlock, 0.8f, Tween.EaseNone, "delay", "1.1", "Y", "135"); Tween.RunFunction(1f, this, "ShakeScreen", 2, true, false); Tween.RunFunction(1.5f, this, "StopScreenShake"); Tween.RunFunction(1.5f, Player.AttachedLevel.ImpactEffectPool, "SkillTreeDustEffect", new Vector2(m_screw.X - m_screw.Width / 2f, m_screw.Y - 40f), true, m_screw.Width); Tween.RunFunction(3f, this, "StopArchitectActivation"); }
private void EquipmentSelectionInput() { var categoryIndex = m_currentCategoryIndex - 6; int oldIndex = m_currentEquipmentIndex; if (InputManager.IsNewlyPressed(InputFlags.PlayerUp1 | InputFlags.PlayerUp2)) { oldIndex = (oldIndex + 10) % 15; } else if (InputManager.IsNewlyPressed(InputFlags.PlayerDown1 | InputFlags.PlayerDown2)) { oldIndex = (oldIndex + 5) % 15; } if (InputManager.IsNewlyPressed(InputFlags.PlayerLeft1 | InputFlags.PlayerLeft2)) { oldIndex += oldIndex % 5 == 0 ? 4 : -1; } if (InputManager.IsNewlyPressed(InputFlags.PlayerRight1 | InputFlags.PlayerRight2)) { oldIndex += oldIndex % 5 == 4 ? -4 : 1; } var bpArr = Game.PlayerStats.GetBlueprintArray[categoryIndex]; if (oldIndex != m_currentEquipmentIndex) { m_currentEquipmentIndex = oldIndex; if (bpArr[oldIndex] == 1) { bpArr[oldIndex] = 2; } UpdateNewIcons(); UpdateIconSelectionText(); m_selectionIcon.Position = m_activeIconArray[oldIndex].AbsPosition; SoundManager.PlaySound("ShopBSMenuMove"); } if (InputManager.IsNewlyPressed(InputFlags.MenuCancel1 | InputFlags.MenuCancel2)) { SoundManager.PlaySound("ShopMenuCancel"); m_inCategoryMenu = true; m_selectionIcon.Position = m_blacksmithUI.GetChildAt(m_currentCategoryIndex).AbsPosition; UpdateIconSelectionText(); } if (InputManager.IsNewlyPressed(InputFlags.MenuConfirm1 | InputFlags.MenuConfirm2)) { var player = this.Player; int item = bpArr[oldIndex]; var equipArray = Game.PlayerStats.GetEquippedArray; var currentEquipped = equipArray[categoryIndex]; if (item < 3 && item > 0) { EquipmentBase equipmentData = Game.EquipmentSystem.GetEquipmentData(categoryIndex, oldIndex); if (Game.PlayerStats.Gold < equipmentData.Cost) { SoundManager.PlaySound("ShopMenuUnlockFail"); } else { SoundManager.PlaySound("ShopMenuUnlock"); Game.PlayerStats.Gold -= equipmentData.Cost; bpArr[oldIndex] = 3; ObjContainer firstColour = this.m_masterIconArray[categoryIndex][oldIndex]; firstColour.ChangeSprite("BlacksmithUI_" + EquipmentCategoryType.ToString(categoryIndex) + (oldIndex % 5 + 1) + "Icon_Character"); for (int i = 1; i < firstColour.NumChildren; i++) { firstColour.GetChildAt(i).Opacity = 1f; } int num1 = categoryIndex == 0 ? 2 : 1; firstColour.GetChildAt(num1).TextureColor = equipmentData.FirstColour; if (categoryIndex != 4) { firstColour.GetChildAt(num1 + 1).TextureColor = equipmentData.SecondColour; } item = 3; this.UpdateIconSelectionText(); } } if (currentEquipped != oldIndex && item == 3) { EquipmentBase equipmentDatum = Game.EquipmentSystem.GetEquipmentData(categoryIndex, oldIndex); //int getEquippedArray1 = Game.PlayerStats.GetEquippedArray[categoryIndex]; int weight = 0; if (currentEquipped != -1) { weight = Game.EquipmentSystem.GetEquipmentData(categoryIndex, currentEquipped).Weight; } if (equipmentDatum.Weight + player.CurrentWeight - weight > player.MaxWeight) { Console.WriteLine(string.Concat("cannot equip. too heavy. Weight:", equipmentDatum.Weight + player.CurrentWeight - weight)); return; } SoundManager.PlaySound("ShopBSEquip"); equipArray[categoryIndex] = (sbyte)oldIndex; this.UpdateIconSelectionText(); Vector3 partIndices = PlayerPart.GetPartIndices(categoryIndex); if (partIndices.X != -1f) { player.GetChildAt((int)partIndices.X).TextureColor = equipmentDatum.FirstColour; } if (partIndices.Y != -1f) { player.GetChildAt((int)partIndices.Y).TextureColor = equipmentDatum.SecondColour; } if (partIndices.Z != -1f) { player.GetChildAt((int)partIndices.Z).TextureColor = equipmentDatum.SecondColour; } if (categoryIndex == 2 && partIndices.X != -1f) { player.GetChildAt(5).TextureColor = equipmentDatum.FirstColour; } this.UpdateNewIcons(); return; } if (currentEquipped == oldIndex) { equipArray[categoryIndex] = -1; player.UpdateEquipmentColours(); this.UpdateIconSelectionText(); this.UpdateNewIcons(); } } }
private void ChangeParts(PlayerObj player) { string[] strArrays = (m_playerInAir = CDGMath.RandomInt(0, 1) == 0) ? new[] { "Jumping", "Falling", "AirAttack" } : new[] { "Idle", "Walking", "LevelUp", "Dash", "FrontDash", "Attacking3" }; int max = strArrays.Length - 1; if (Game.PlayerStats.Class == 16) { max--; } string animationType = strArrays[CDGMath.RandomInt(0, max)]; //SetPlayerStyle(strArrays[CDGMath.RandomInt(0, strArrays.Length - 1)]); m_playerSprite.ChangeSprite("Player" + animationType + "_Character"); m_playerSprite.Scale = player.Scale; m_playerSprite.OutlineColour = player.OutlineColour; for (int i = 0; i < m_playerSprite.NumChildren; i++) { var src = player.GetChildAt(i); var dst = m_playerSprite.GetChildAt(i); dst.TextureColor = src.TextureColor; dst.Visible = src.Visible; } m_playerSprite.CalculateBounds(); m_playerSprite.Y = 435f - (m_playerSprite.Bounds.Bottom - m_playerSprite.Y); //for (int i = 0; i < player.NumChildren; i++) //{ // SpriteObj childAt = player.GetChildAt(i) as SpriteObj; // SpriteObj textureColor = m_playerSprite.GetChildAt(i) as SpriteObj; // textureColor.TextureColor = childAt.TextureColor; //} //string spriteName = (m_playerSprite.GetChildAt(12) as IAnimateableObj).SpriteName; //int num = spriteName.IndexOf("_") - 1; //spriteName = spriteName.Remove(num, 1); //if (Game.PlayerStats.Class != 16) //{ // spriteName = (Game.PlayerStats.Class != 17 ? spriteName.Replace("_", string.Concat(Game.PlayerStats.HeadPiece, "_")) : spriteName.Replace("_", string.Concat(7, "_"))); //} //else //{ // spriteName = spriteName.Replace("_", string.Concat(6, "_")); //} //m_playerSprite.GetChildAt(12).ChangeSprite(spriteName); //string str = (m_playerSprite.GetChildAt(4) as IAnimateableObj).SpriteName; //num = str.IndexOf("_") - 1; //str = str.Remove(num, 1); //str = str.Replace("_", string.Concat(Game.PlayerStats.ChestPiece, "_")); //m_playerSprite.GetChildAt(4).ChangeSprite(str); //string spriteName1 = (m_playerSprite.GetChildAt(9) as IAnimateableObj).SpriteName; //num = spriteName1.IndexOf("_") - 1; //spriteName1 = spriteName1.Remove(num, 1); //spriteName1 = spriteName1.Replace("_", string.Concat(Game.PlayerStats.ShoulderPiece, "_")); //m_playerSprite.GetChildAt(9).ChangeSprite(spriteName1); //string str1 = (m_playerSprite.GetChildAt(3) as IAnimateableObj).SpriteName; //num = str1.IndexOf("_") - 1; //str1 = str1.Remove(num, 1); //str1 = str1.Replace("_", string.Concat(Game.PlayerStats.ShoulderPiece, "_")); //m_playerSprite.GetChildAt(3).ChangeSprite(str1); }
public override void OnEnter() { m_bossDoorOpening = false; if (Game.PlayerStats.ReadLastDiary && LinkedRoom.LinkedRoom != null) { LinkedRoom = LinkedRoom.LinkedRoom; } Game.PlayerStats.LoadStartingRoom = false; if (Game.PlayerStats.DiaryEntry < 1) { m_speechBubble.Visible = true; } else { m_speechBubble.Visible = false; } if (InputManager.GamePadIsConnected(PlayerIndex.One)) { m_mapIcon.SetButton(Game.GlobalInput.ButtonList[9]); m_mapIcon.Scale = new Vector2(1f, 1f); } else { m_mapIcon.SetKey(Game.GlobalInput.KeyList[9]); m_mapIcon.Scale = new Vector2(0.5f, 0.5f); } if (!m_allFilesSaved) { Player.Game.SaveManager.SaveAllFileTypes(false); m_allFilesSaved = true; } if (Game.PlayerStats.EyeballBossBeaten) { RevealSymbol(GameTypes.LevelType.CASTLE, false); } if (Game.PlayerStats.FairyBossBeaten) { RevealSymbol(GameTypes.LevelType.GARDEN, false); } if (Game.PlayerStats.BlobBossBeaten) { RevealSymbol(GameTypes.LevelType.DUNGEON, false); } if (Game.PlayerStats.FireballBossBeaten) { RevealSymbol(GameTypes.LevelType.TOWER, false); } if (Game.PlayerStats.EyeballBossBeaten && Game.PlayerStats.FairyBossBeaten && Game.PlayerStats.BlobBossBeaten && Game.PlayerStats.FireballBossBeaten && !Game.PlayerStats.FinalDoorOpened && Player.ScaleX > 0.1f) { PlayBossDoorAnimation(); } else if (Game.PlayerStats.FinalDoorOpened) { m_bossDoor.Locked = false; m_bossDoorSprite.ChangeSprite("LastDoorOpen_Character"); m_bossDoorSprite.GoToFrame(m_bossDoorSprite.TotalFrames); } if (!m_gateClosed) { CloseGate(true); } if (Game.PlayerStats.EyeballBossBeaten && Game.PlayerStats.FairyBossBeaten && Game.PlayerStats.BlobBossBeaten && Game.PlayerStats.FireballBossBeaten && !Game.PlayerStats.FinalDoorOpened && Player.ScaleX > 0.1f) { Game.PlayerStats.FinalDoorOpened = true; Player.AttachedLevel.RunCinematicBorders(6f); } base.OnEnter(); }
public void SetPlayerStyle(string animationType) { m_playerSprite.ChangeSprite("Player" + animationType + "_Character"); PlayerObj player = (ScreenManager as RCScreenManager).Player; for (int i = 0; i < m_playerSprite.NumChildren; i++) { var src = player.GetChildAt(i); var dst = m_playerSprite.GetChildAt(i); dst.TextureColor = src.TextureColor; dst.Visible = src.Visible; } m_playerSprite.Scale = player.Scale; m_playerSprite.OutlineColour = player.OutlineColour; //m_playerSprite.ChangeSprite("Player" + animationType + "_Character"); //PlayerObj player = (base.ScreenManager as RCScreenManager).Player; //for (int i = 0; i < m_playerSprite.NumChildren; i++) //{ // m_playerSprite.GetChildAt(i).TextureColor = player.GetChildAt(i).TextureColor; // m_playerSprite.GetChildAt(i).Visible = player.GetChildAt(i).Visible; //} //m_playerSprite.GetChildAt(16).Visible = false; //m_playerSprite.Scale = player.Scale; //if (Game.PlayerStats.Traits.X == 8f || Game.PlayerStats.Traits.Y == 8f) //{ // m_playerSprite.GetChildAt(7).Visible = false; //} //m_playerSprite.GetChildAt(14).Visible = false; //if (Game.PlayerStats.SpecialItem == 8) //{ // m_playerSprite.GetChildAt(14).Visible = true; //} //if (Game.PlayerStats.Class == 0 || Game.PlayerStats.Class == 8) //{ // m_playerSprite.GetChildAt(15).Visible = true; // m_playerSprite.GetChildAt(15).ChangeSprite(string.Concat("Player", animationType, "Shield_Sprite")); //} //else if (Game.PlayerStats.Class == 5 || Game.PlayerStats.Class == 13) //{ // m_playerSprite.GetChildAt(15).Visible = true; // m_playerSprite.GetChildAt(15).ChangeSprite(string.Concat("Player", animationType, "Lamp_Sprite")); //} //else if (Game.PlayerStats.Class == 1 || Game.PlayerStats.Class == 9) //{ // m_playerSprite.GetChildAt(15).Visible = true; // m_playerSprite.GetChildAt(15).ChangeSprite(string.Concat("Player", animationType, "Beard_Sprite")); //} //else if (Game.PlayerStats.Class == 4 || Game.PlayerStats.Class == 12) //{ // m_playerSprite.GetChildAt(15).Visible = true; // m_playerSprite.GetChildAt(15).ChangeSprite(string.Concat("Player", animationType, "Headband_Sprite")); //} //else if (Game.PlayerStats.Class == 2 || Game.PlayerStats.Class == 10) //{ // m_playerSprite.GetChildAt(15).Visible = true; // m_playerSprite.GetChildAt(15).ChangeSprite(string.Concat("Player", animationType, "Horns_Sprite")); //} //else //{ // m_playerSprite.GetChildAt(15).Visible = false; //} //m_playerSprite.GetChildAt(0).Visible = false; //if (Game.PlayerStats.Class == 16) //{ // m_playerSprite.GetChildAt(0).Visible = true; // GameObj childAt = m_playerSprite.GetChildAt(12); // object[] objArray = new object[] { "Player", animationType, "Head", 6, "_Sprite" }; // childAt.ChangeSprite(string.Concat(objArray)); //} //if (Game.PlayerStats.Class == 17) //{ // GameObj gameObj = m_playerSprite.GetChildAt(12); // object[] objArray1 = new object[] { "Player", animationType, "Head", 7, "_Sprite" }; // gameObj.ChangeSprite(string.Concat(objArray1)); //} //if (Game.PlayerStats.IsFemale) //{ // m_playerSprite.GetChildAt(5).Visible = true; // m_playerSprite.GetChildAt(13).Visible = true; //} //else //{ // m_playerSprite.GetChildAt(5).Visible = false; // m_playerSprite.GetChildAt(13).Visible = false; //} //if (Game.PlayerStats.Traits.X == 6f || Game.PlayerStats.Traits.Y == 6f) //{ // m_playerSprite.Scale = new Vector2(3f, 3f); //} //if (Game.PlayerStats.Traits.X == 7f || Game.PlayerStats.Traits.Y == 7f) //{ // m_playerSprite.Scale = new Vector2(1.35f, 1.35f); //} //if (Game.PlayerStats.Traits.X == 10f || Game.PlayerStats.Traits.Y == 10f) //{ // ObjContainer mPlayerSprite = m_playerSprite; // mPlayerSprite.ScaleX = mPlayerSprite.ScaleX * 0.825f; // ObjContainer scaleY = m_playerSprite; // scaleY.ScaleY = scaleY.ScaleY * 1.25f; //} //if (Game.PlayerStats.Traits.X == 9f || Game.PlayerStats.Traits.Y == 9f) //{ // ObjContainer scaleX = m_playerSprite; // scaleX.ScaleX = scaleX.ScaleX * 1.25f; // ObjContainer objContainer = m_playerSprite; // objContainer.ScaleY = objContainer.ScaleY * 1.175f; //} //if (Game.PlayerStats.Class == 6 || Game.PlayerStats.Class == 14) //{ // m_playerSprite.OutlineColour = Color.White; // m_playerSprite.GetChildAt(10).Visible = false; // m_playerSprite.GetChildAt(11).Visible = false; //} //else //{ // m_playerSprite.OutlineColour = Color.Black; // m_playerSprite.GetChildAt(10).Visible = true; // m_playerSprite.GetChildAt(11).Visible = true; //} //string spriteName = (m_playerSprite.GetChildAt(12) as IAnimateableObj).SpriteName; //int num = spriteName.IndexOf("_") - 1; //spriteName = spriteName.Remove(num, 1); //if (Game.PlayerStats.Class != 16) //{ // spriteName = (Game.PlayerStats.Class != 17 ? spriteName.Replace("_", string.Concat(Game.PlayerStats.HeadPiece, "_")) : spriteName.Replace("_", string.Concat(7, "_"))); //} //else //{ // spriteName = spriteName.Replace("_", string.Concat(6, "_")); //} //m_playerSprite.GetChildAt(12).ChangeSprite(spriteName); //string str = (m_playerSprite.GetChildAt(4) as IAnimateableObj).SpriteName; //num = str.IndexOf("_") - 1; //str = str.Remove(num, 1); //str = str.Replace("_", string.Concat(Game.PlayerStats.ChestPiece, "_")); //m_playerSprite.GetChildAt(4).ChangeSprite(str); //string spriteName1 = (m_playerSprite.GetChildAt(9) as IAnimateableObj).SpriteName; //num = spriteName1.IndexOf("_") - 1; //spriteName1 = spriteName1.Remove(num, 1); //spriteName1 = spriteName1.Replace("_", string.Concat(Game.PlayerStats.ShoulderPiece, "_")); //m_playerSprite.GetChildAt(9).ChangeSprite(spriteName1); //string str1 = (m_playerSprite.GetChildAt(3) as IAnimateableObj).SpriteName; //num = str1.IndexOf("_") - 1; //str1 = str1.Remove(num, 1); //str1 = str1.Replace("_", string.Concat(Game.PlayerStats.ShoulderPiece, "_")); //m_playerSprite.GetChildAt(3).ChangeSprite(str1); m_playerSprite.PlayAnimation(true); m_playerSprite.CalculateBounds(); m_playerSprite.Y = 435f - (m_playerSprite.Bounds.Bottom - m_playerSprite.Y); }
public void SetPlayerStyle(string animationType) { m_playerSprite.ChangeSprite("Player" + animationType + "_Character"); var player = (ScreenManager as RCScreenManager).Player; for (var i = 0; i < m_playerSprite.NumChildren; i++) { m_playerSprite.GetChildAt(i).TextureColor = player.GetChildAt(i).TextureColor; m_playerSprite.GetChildAt(i).Visible = player.GetChildAt(i).Visible; } m_playerSprite.GetChildAt(16).Visible = false; m_playerSprite.Scale = player.Scale; if (Game.PlayerStats.Traits.X == 8f || Game.PlayerStats.Traits.Y == 8f) { m_playerSprite.GetChildAt(7).Visible = false; } m_playerSprite.GetChildAt(14).Visible = false; if (Game.PlayerStats.SpecialItem == 8) { m_playerSprite.GetChildAt(14).Visible = true; } if (Game.PlayerStats.Class == 0 || Game.PlayerStats.Class == 8) { m_playerSprite.GetChildAt(15).Visible = true; m_playerSprite.GetChildAt(15).ChangeSprite("Player" + animationType + "Shield_Sprite"); } else if (Game.PlayerStats.Class == 5 || Game.PlayerStats.Class == 13) { m_playerSprite.GetChildAt(15).Visible = true; m_playerSprite.GetChildAt(15).ChangeSprite("Player" + animationType + "Lamp_Sprite"); } else if (Game.PlayerStats.Class == 1 || Game.PlayerStats.Class == 9) { m_playerSprite.GetChildAt(15).Visible = true; m_playerSprite.GetChildAt(15).ChangeSprite("Player" + animationType + "Beard_Sprite"); } else if (Game.PlayerStats.Class == 4 || Game.PlayerStats.Class == 12) { m_playerSprite.GetChildAt(15).Visible = true; m_playerSprite.GetChildAt(15).ChangeSprite("Player" + animationType + "Headband_Sprite"); } else if (Game.PlayerStats.Class == 2 || Game.PlayerStats.Class == 10) { m_playerSprite.GetChildAt(15).Visible = true; m_playerSprite.GetChildAt(15).ChangeSprite("Player" + animationType + "Horns_Sprite"); } else { m_playerSprite.GetChildAt(15).Visible = false; } m_playerSprite.GetChildAt(0).Visible = false; if (Game.PlayerStats.Class == 16) { m_playerSprite.GetChildAt(0).Visible = true; m_playerSprite.GetChildAt(12).ChangeSprite(string.Concat("Player", animationType, "Head", 6, "_Sprite")); } if (!Game.PlayerStats.IsFemale) { m_playerSprite.GetChildAt(5).Visible = false; m_playerSprite.GetChildAt(13).Visible = false; } else { m_playerSprite.GetChildAt(5).Visible = true; m_playerSprite.GetChildAt(13).Visible = true; } if (Game.PlayerStats.Traits.X == 6f || Game.PlayerStats.Traits.Y == 6f) { m_playerSprite.Scale = new Vector2(3f, 3f); } if (Game.PlayerStats.Traits.X == 7f || Game.PlayerStats.Traits.Y == 7f) { m_playerSprite.Scale = new Vector2(1.35f, 1.35f); } if (Game.PlayerStats.Traits.X == 10f || Game.PlayerStats.Traits.Y == 10f) { m_playerSprite.ScaleX *= 0.825f; m_playerSprite.ScaleY *= 1.25f; } if (Game.PlayerStats.Traits.X == 9f || Game.PlayerStats.Traits.Y == 9f) { m_playerSprite.ScaleX *= 1.25f; m_playerSprite.ScaleY *= 1.175f; } if (Game.PlayerStats.Class == 6 || Game.PlayerStats.Class == 14) { m_playerSprite.OutlineColour = Color.White; } else { m_playerSprite.OutlineColour = Color.Black; } m_playerSprite.CalculateBounds(); m_playerSprite.Y = 435f - (m_playerSprite.Bounds.Bottom - m_playerSprite.Y); }