Spoiler
Scriptname ExtendedUtility extends UtilityInt Function GetCurrentMoonphase() GlobalFloat GameTimeFloat GameDaysPassedFloat GameHoursPassedFloat GameMinutesPassedInt PhaseTestGameTime = Parent.GetCurrentGameTime()GameDaysPassed = Math.Floor(GameTime)GameHoursPassed = (GameTime - GameDaysPassed) * 24.0If (GameHoursPassed >= 12.0) GameDaysPassed += 1EndIfPhaseTest = (GameDaysPassed As Int) % 24If (PhaseTest >= 1 && PhaseTest <= 3) return 0EndIfIf (PhaseTest >= 4 && PhaseTest <= 6) return 1EndIfIf (PhaseTest >= 7 && PhaseTest <= 9) return 2EndIfIf (PhaseTest >= 10 && PhaseTest <= 12) return 3EndIfIf (PhaseTest >= 13 && PhaseTest <= 15) return 4EndIfIf (PhaseTest >= 16 && PhaseTest <= 18) return 5EndIfIf (PhaseTest >= 19 && PhaseTest <= 21) return 6EndIfIf (PhaseTest >= 22 || PhaseTest == 0) return 7EndIfEndFunction
The above script though fails to compile because of the call to Parent.GetCurrentGameTime(), telling me the Vriable "Parent" was not declared. If I replace it with Utility.GetCurrentGameTime() it compiles but if I then in another script make a call to ExtendedUtility.GetCurrentGameTime() that other script fails to compile (calling ExtendedUtility.GetCurrentMoonphase() works like a charm though).
My question is why is this? Well quite obviously my script does not inherit the functions from Utility or the extends keyword itself seems to be not working but why?
This is really a shame. I'll do a lot more scripting in future projects I've planned and being able to extend the Utility script would be extremely helpful. Also creating a "Community Utility Script" could be a helpful resource for all of us so we don't need to copy paste or even worse reinvent the wheel all the time.
So I am thankful for any insight on this.

