Preset Switcher

Objects that fire shots in games often don’t fire the exact same pattern or shot; players switch weapons, bosses change their attack patterns and so on. VariaBULLET2D employs an easy and convenient way to store entire controller/emitter/shot states as a single preset and load them on the fly while in-game.


Simply [A] attach a FullPresetSwitch script to the gamebject parented to the controller’s Origin. Here you can [B] set the Button Switch, or Trigger Switch from outside code, resulting in the switching behavior.

Set [C] Preset Prefabs into the slots in the order that you want them to occur when switching. Optionally, you can enable loading the first prefab on Start with [D] Auto Switch On Start, and also you can set the [E] Delay Frames to create a buffer time between switches.


Creating a Preset Prefab is very easy. Simply set up the entire controller structure as you normally would and then drag and drop its Origin into a folder for later use. You can even create prefabs in this way when experimenting in play mode; great for producing new presets without messing up your settings in edit mode.