SpriteScaleFactor

Top  Previous  Next

Syntax

SpriteScaleFactor(sprite as POINTER,scale as float)

Description

Sets the scaling value for the sprite drawing modes @SCALED, @TRANSSCALED, @ROTOZOOM and @TRANSROTOZOOM.

Parameters

sprite - Sprite pointer returned by LoadSprite.

scale - The scale factor to use.

Return value

None

Remarks

The scaling factor is 1.0 by default. Use 2.0 for a double sized sprite, 0.5 for a half sized, etc.  If your just scaling the sprite use the modes @SCALED and @TRANSSCALED as they are much faster than the ROTOZOOM routines which work by software texture mapping.

See Also: LoadSprite, SpriteAngle

Example usage

SpriteScaleFactor goodguy, 2.5