creative-jam-20/Assets/Scripts/PlayerController.cs
Soulaha Balde 197674fc1b Fix warping on cannon
WIP Ammo types skeleton
2022-05-14 01:41:55 -04:00

41 lines
753 B
C#

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class PlayerController : MonoBehaviour
{
[SerializeField] private float points;
[SerializeField] private CannonScript cannon;
// Start is called before the first frame update
void Start()
{
points = 0;
}
// Update is called once per frame
void Update()
{
}
public float getPoints(){
return points;
}
public void setPoints(float nPoints){
points = nPoints;
}
public void spendPoints(float amount){
if(amount <= points){
points = points - amount;
}
}
public void gainPoints(float amount){
points += amount;
}
}