private void SpawnSparkles(PickedUpArgs e) { for (int i = 0; i < 2; i++) { float randY = (float)(TMBAW_Game.Random.Next(-1, 0) * TMBAW_Game.Random.NextDouble()); float randX = (float)(TMBAW_Game.Random.Next(-1, 2) * TMBAW_Game.Random.NextDouble()); ParticleSystem.Add(ParticleType.Tiny, CalcHelper.GetRandXAndY(CollRectangle), new Vector2(randX, randY), Color.Yellow); } }
private void Food_OnPlayerPickUp(PickedUpArgs e) { e.Player.Heal(_healAmount); _pickUpSound.Play(); }