Hello,
I’ve run into a bit of a problem… I’m trying to do an “information display on enemy stats” (which will later be turned into a spawn manager script, where I’ve to scale the health, damage and score of the enemy for each wave) but I’ve made 2 different scripts: one for their projectile with their damage output and one script for their health and AI.
But the new script I’m making needs to inheritance from both of these scripts inside my new script, but Unity/C# can’t do multiple inheritance… so what can I do in order to make this work?
My update script is not done (obviously) but it looks like this so far:
using UnityEngine;
using UnityEngine.UI;
using System.Collections;
public class InfiniteSpawnManager : EnemyHealth {
public Text CurrentEnemyHealthText;
public Text CurrentEnemyDamageText;
public Text CurrentEnemyScoreText;
void Start () {
CurrentEnemyHealthText.text = "Enemy Health : " + hitPoints.ToString();
//CurrentEnemyDamageText.text = "Enemy Damage : " + ?.ToString();
CurrentEnemyScoreText.text = "Enemy Score : " + scorePoints.ToString();
}
}
I’ve commented out the current enemy damage because that one is supposed to inherititance from another script called “EnemyLaserProjectile”.
Any suggestions on what I can do to fix this mess? Hopefully without having to combine my other 2 scripts into one, which would create some other issues >_>