1. Home
  2. Docs
  3. Magio
  4. Tutorials
  5. Create a splash effect

Create a splash effect

Example 1: Your main character does lots of magic attacks. You do not want to go through all the trouble to convert everything to magio objects, but want just a crude effect where your magic lands.

Example 2: Your player can throw molotovs. You want a flame effect wherever the molotov lands, but do not want it to spread.

Limitations: 

  • Effects which rely on VFX and not material animation such as flame and plantify works fine as splash effects out-of-the-box with any shader. For material animation effects (petrify/melt/etc..) all the objects would need to be converted to Magio shader. You can convert only shader by Right-click->Magio Convert-> Only Materials. There can be only one material animation effect enabled per object.
  • Effects can look small or too big depending on the object, since there is no way to customize the effect per object

Steps to use splash effects:

  1. There are default splash effects for you to use in the demo directory.
  2. Create empty gameobject.
  3. Add Sphere Ignite Script to the game object.
  4. Add Arctibyte/Magio/Demo/Common/ExampleSplashEffectPrefabs/…._Splash to Sphere Ignite ”Splash effect prefab”.
  1. Play the scene and move the “sphere ignite” sphere close to some object with a default layer mask. Sphere ignite adds the effect to the first object it touches. You can refresh this by disabling and enabling it.
  2. You can also use Particle Ignite and Raycast Ignite the same way. You can also add splash effects yourself from code like this:

Steps to create splash effects prefab from any effect:

  1. Create an empty prefab.
  2. Add MagioObjectEffect script.
  3. Enable Advanced-> Deleting the object after fadeout and IsSplashEffect
  1. Customize Advanced->Max Spread and System->Fade out
Was this article helpful to you? Yes No

Leave a Reply

Your email address will not be published.