TO SQUASH: Shark notifications.
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
using UnityEngine;
|
||||
using System.Collections;
|
||||
|
||||
public class Shark : MonoBehaviour
|
||||
public class Shark : NotifierBase
|
||||
{
|
||||
public AudioClip spawnSound;
|
||||
|
||||
@@ -37,7 +37,7 @@ public class Shark : MonoBehaviour
|
||||
|
||||
private float angryProbability = 0.1f;
|
||||
|
||||
private static int sharkKillPoints = 100;
|
||||
private static int sharkKillPoints = 1000;
|
||||
|
||||
private bool spawnFinished = false;
|
||||
|
||||
@@ -167,7 +167,17 @@ public class Shark : MonoBehaviour
|
||||
}
|
||||
|
||||
audioSource.PlayOneShot(deathSound);
|
||||
player.score += sharkKillPoints;
|
||||
player.score += sharkKillPoints + (isAngry ? 500 : 0);
|
||||
|
||||
if (isAngry)
|
||||
{
|
||||
ShowNotification("1500");
|
||||
}
|
||||
else
|
||||
{
|
||||
ShowNotification("1000");
|
||||
}
|
||||
|
||||
StartCoroutine(DestroyShark());
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user