Example #1
0
func InitEffect()
{
    Sound("Fire::Fireball", false, 100, nil, nil, nil, 200);
    Sound("Fire::FuseLoop", false, 20, nil, 1, nil, 200);
    SetLightRange(30, 70);
    SetLightColor(RGB(100, 100, 255));

    var snow =
    {
        R = 200,
        G = 200,
        B = 255,
        Alpha = PV_Linear(255, 0),
        Size = PV_Random(0, 2),
        CollisionVertex = 0,
        OnCollision = PC_Stop(),
        ForceX = PV_Random(-5, 5, 10),
        ForceY = PV_Gravity(100),
        DampingX = 900, DampingY = 900
    };

    trail_particles =
    {
        R = PV_Random(200, 255), G = PV_Random(200, 255), B = 255,
        Prototype = Particles_FireTrail(),
        Size = PV_Linear(10, 0),
        BlitMode = nil,
        Rotation = PV_Random(0, 360),
        BlitMode = GFX_BLIT_Additive
    };

    CreateParticle("StarFlash", 0, 0, PV_Random(-30, 30), PV_Random(-30, 30), 100, snow, 100);
}
Example #2
0
global func Particles_Leaves()
{
	return
	{
		Size = PV_Random(3, 6),
	    Phase = PV_Linear(0, 7*5),
		Alpha = PV_KeyFrames(0, 0, 255, 900, 255, 1000, 0),
		CollisionVertex = 500,
		OnCollision = PC_Stop(),
		ForceX = PV_Wind(100),
		ForceY = PV_Gravity(40),
		DampingX = 975, DampingY = 975,
		Rotation = PV_Direction(PV_Random(750, 1250)),
		Attach = nil
	};
}