↔️useing exports

Cr-effects let's you call the effects from a completely different script with exports. On this page you will learn how these work and how to use them.

How the exports work

To call an effect from a script of your choice you need to use what's called an export.

Below is an example of an export. The export can hold up to 4 variables depending of what effect you need.

exports['cr-effects']:StartEffect("RagDoll", 10)

The first variable (in this case "RagDoll") is the type of effect you want to call. Below is a table of all the effects and what variables it needs.

Effect name
number of variables
what variables

"RagDoll"

1

Time

"HealthRegen"

2

Time, Amount

"RelieveStress"

1

Amount

"Speed"

1

Time

"AlienEffect"

1

Time

"Drunk"

1

Time

"relieveThirst"

1

Amount

"relieveHunger"

1

Amount

"Stamina"

1

Time

"CameraShake"

3

Time, CameraShakeType, intensity

"ScreenFlash"

1

Time

"stumble"

1

Time

"custom"

4

EffectName, time, Transition, strength

"status

2

StatusName, time

Below there is a table of that the variables mean from above table.

Variable name
what it means

Time

This is how long the effect should last in seconds Besides the "custom" effect where it is counted in MS.

Amount

Means by how much.

CameraShakeType

This is the type of camera shake you want to use (DEATH_FAIL_IN_EFFECT_SHAKE, DRUNK_SHAKE, FAMILY5_DRUG_TRIP_SHAKE, HAND_SHAKE, JOLT_SHAKE, LARGE_EXPLOSION_SHAKE, MEDIUM_EXPLOSION_SHAKE, SMALL_EXPLOSION_SHAKE, ROAD_VIBRATION_SHAKE, SKY_DIVING_SHAKE, VIBRATE_SHAKE)

intensity

How intense it should be.

EffectName

This is the name of the custom effect see custom effects.

Transition

This is how long the transition should take to get the full strength.

Strength

How strong the effect should be.

Last updated