Details

Add LightningBolt effect to your Sprite Renderer and Unity UI Canvas Image.

Add it to the Sprite Renderer or Unity UI Canvas Image GameObject via the Components menu2DxFX > Standard > LightningBolt

4 Gradients is available in Advanced Lightning Mode. Via the Components menu2DxFX > Advanced Lightning > LightningBolt

Note : Advanced Lightning is not working with the Unity UI Canvas (UI Canvas don't use lightning)

*without and with 2DxFX LightningBolt


Property

Range

Default

_Alpha 0 to 1 1f
_Value1 16 to 256 64
_Value2 0 to 2 1
_Value3 0 to 1 1
Stabilisation 1f to 8f 4.0f
Speed 0 to 10 1.0f
AutoPlaySpeedY 0f to 50f 5f
AutoRandomRange 0f to 50f 10f

Manipulate LightningBolt by script

Example:

// Drag and Drop your Sprite GameObject 
// with the LightningBolt component 
// to your current script on the FX_Standard_LightningBolt field 

public _2dxFX_LightningBolt_Editor FX_LightningBolt; 

void Update() 
{
	FX_LightningBolt._Alpha =  1f;
}