PlanBasePushSpriteTowardPoint Method |
Alter the velocity of the specified sprite to go toward a specified location.
Namespace: (Default Namespace)Assembly: Default (in Default.exe) Version: 1.0.0.0
Syntax public virtual void PushSpriteTowardPoint(
SpriteBase Sprite,
Point Target,
int Force
)
Parameters
- Sprite
- Type: (Default Namespace)SpriteBase
The sprite whose velocity will be affected - Target
- Type: System.DrawingPoint
Specifies a point toward which the sprite will be pushed - Force
- Type: SystemInt32
How hard to push the sprite in tenths of a pixel per frame per frame
Remarks Examples
This example pushes the sprite toward the mouse location.
PushSpriteTowardPoint(m_ParentLayer.m_Plasma_1, ParentLayer.GetMousePosition(), 40);
See Also