Merged multi-resource code from Stupid_Chris
Converted AdvGenerator.OnStart and OnUpdate to make use of it