I'm working on a boss fight for a 2D platformer/shooter game in the vein of the Megaman franchise. I expect part of the fight to include this boss causing large boulders to fall from certain points on the ceiling to possibly crush the player, which serve both as an attempt to harm the player and a possible means by which the player may harm the boss. I am having some difficulty, however, with conceptualizing how to tie these randomly-falling rocks to an action on the boss's part. I can make spawner objects to drop the boulders when prompted, my issue mainly lies in how to give the boss object the ability to trigger this action, especially given there will be several such spawners in the level, which may be selected at random.
Are there any functions or techniques that may be useful in allowing a single "boss" object to trigger one or more of a set of other "spawner" objects as a part of an action the "boss" takes, rather than simply automating the spawners to work on their own timing?