User Tools

Site Tools


crpl:docs:createeffect

This is an old revision of the document!


~~DISCUSSION~~ <- CRPL reference <- Unit Commands

CreateEffect

Arguments Result Notation
Effect_Num,X,Y,Z,ScaleX,ScaleY,SpeedNonen1 x1 y1 z1 f1 f2 f3 -

Description

CreateEffect allows you to play one of (currently) 17 in-game animations (explosions, the smoke that flies out when something lands, etc.).

Effects are numbered 0-16. The X,Y,Z coordinates are where to play the effect. They are in world pixel coordinates where (0,0,0) is the lower left of the map. ScaleX and ScaleY can be used to change the size of the effect, with 1 being the normal scale. And Speed is how fast to play the effect 1/30 will play most effects at their normal rate.

Effects are useful for visual flare. For instance when a unit blows up you might want to make a custom explosion.

# Play an effect at the current coords, in front of the current unit.
CreateEffect(14 CellToPixel(CurrentCoords) -1 1.5 1.5 0.05)
crpl/docs/createeffect.1377046334.txt.gz · Last modified: 2014/10/01 15:02 (external edit)