repetitive code in MossGiant.cs, Skeleton.cs and Spider.cs

  • Most of the code in the Damage() Method is common to ALL the scripts. Would it not be better coding practice and also a more efficient way to move the common code to a method in the Enemy.cs script which is the parent script, and then add what ever extra we need as override code?

    Isn't this what we should be doing in all coding? I am asking cause I would like this confirmed by a code Guru. I am still learning.:)