so im trying out coding and i have no clue how to solve this one. usually im good at fixing this but it wont fix bc its at a line i did nothing too.
its at (9,12) and its an unexpected symbol ‘void’ in class, struct, or interface member declaration.
using UnityEngine;
using System.Collections;
public class BulletG : MonoBehaviour {
float lifespan = 3.0f
// Use this for initialization
void Start () {
}
// Update is called once per frame
void Update () {
lifespan -= Time.deltaTime;
if(lifespan <= 0){
Explode();
}
}
void OnCollisionEnter() {
//Destroy(gameObject);
}
void Explode() {
Destroy(gameObject);
}
}