Add FlipH to the death screen
This commit is contained in:
parent
591dd26372
commit
6f68068d16
1 changed files with 2 additions and 0 deletions
|
@ -41,6 +41,7 @@ public partial class DeathScreen : TextureRect
|
||||||
_playerSprite.Texture =
|
_playerSprite.Texture =
|
||||||
animatedSprite2D.SpriteFrames.GetFrameTexture(animatedSprite2D.Animation, animatedSprite2D.Frame);
|
animatedSprite2D.SpriteFrames.GetFrameTexture(animatedSprite2D.Animation, animatedSprite2D.Frame);
|
||||||
_playerSprite.Position -= _playerSprite.Texture.GetSize() / 2;
|
_playerSprite.Position -= _playerSprite.Texture.GetSize() / 2;
|
||||||
|
_playerSprite.FlipH = animatedSprite2D.FlipH;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (killer.FindChild("AnimatedSprite2D") is AnimatedSprite2D killerAnimatedSprite2D)
|
if (killer.FindChild("AnimatedSprite2D") is AnimatedSprite2D killerAnimatedSprite2D)
|
||||||
|
@ -49,6 +50,7 @@ public partial class DeathScreen : TextureRect
|
||||||
_monsterSprite.Texture =
|
_monsterSprite.Texture =
|
||||||
killerAnimatedSprite2D.SpriteFrames.GetFrameTexture(killerAnimatedSprite2D.Animation, killerAnimatedSprite2D.Frame);
|
killerAnimatedSprite2D.SpriteFrames.GetFrameTexture(killerAnimatedSprite2D.Animation, killerAnimatedSprite2D.Frame);
|
||||||
_monsterSprite.Position -= _monsterSprite.Texture.GetSize() / 2;
|
_monsterSprite.Position -= _monsterSprite.Texture.GetSize() / 2;
|
||||||
|
_monsterSprite.FlipH = killerAnimatedSprite2D.FlipH;
|
||||||
}
|
}
|
||||||
|
|
||||||
Visible = true;
|
Visible = true;
|
||||||
|
|
Loading…
Add table
Reference in a new issue