Click or drag to resize
PlanBaseIsSpriteActive Method
Determines if the specified sprite instace is active.

Namespace: (Default Namespace)
Assembly: Default (in Default.exe) Version: 1.0.0.0
Syntax
C#
public virtual bool IsSpriteActive(
	SpriteBase Sprite
)

Parameters

Sprite
Type: (Default Namespace)SpriteBase
Sprite instance to test

Return Value

Type: Boolean
True if the sprite is active, false otherwise.
Remarks
The main differences between an active sprite and an inactive sprite are than only active sprites are drawn when they are in the visible part of the map, and only active sprites' rules are processed. Using IsSpriteActive is a good way to determine if a sprite is currently valid for use because inactive sprites should not have any functions running on them except to activate them. Most functions will trigger an error message in debug mode if they find that they are operating on an inactive sprite.
Examples
See StopSprite(SpriteBase) for an example of IsSpriteActive.
See Also