C# Class OpenMetaverse.AgentManager.AgentMovement

Agent movement and camera control Agent movement is controlled by setting specific T:AgentManager.ControlFlags After the control flags are set, An AgentUpdate is required to update the simulator of the specified flags This is most easily accomplished by setting one or more of the AgentMovement properties Movement of an avatar is always based on a compass direction, for example AtPos will move the agent from West to East or forward on the X Axis, AtNeg will of course move agent from East to West or backward on the X Axis, LeftPos will be South to North or forward on the Y Axis The Z axis is Up, finer grained control of movements can be done using the Nudge properties
Afficher le fichier Open project: 3di/3di-viewer-rei-libs

Méthodes publiques

Свойство Type Description
BodyRotation Quaternion
Camera AgentCamera
Flags AgentFlags
HeadRotation Quaternion
State AgentState

Méthodes publiques

Méthode Description
AgentMovement ( GridClient client ) : System

Default constructor

SendManualUpdate ( AgentManager controlFlags, System.Vector3 position, System.Vector3 forwardAxis, System.Vector3 leftAxis, System.Vector3 upAxis, Quaternion bodyRotation, Quaternion headRotation, float farClip, AgentFlags flags, AgentState state, bool reliable ) : void

Builds an AgentUpdate packet entirely from parameters. This will not touch the state of Self.Movement or Self.Movement.Camera in any way

SendUpdate ( ) : void

Send new AgentUpdate packet to update our current camera position and rotation

SendUpdate ( bool reliable ) : void

Send new AgentUpdate packet to update our current camera position and rotation

SendUpdate ( bool reliable, Simulator simulator ) : void

Send new AgentUpdate packet to update our current camera position and rotation

TurnToward ( System.Vector3 target ) : bool

Rotates the avatar body and camera toward a target position. This will also anchor the camera position on the avatar

UpdateFromHeading ( double heading, bool reliable ) : void

Send an AgentUpdate with the camera set at the current agent position and pointing towards the heading specified

Private Methods

Méthode Description
GetControlFlag ( ControlFlags flag ) : bool
ResetControlFlags ( ) : void
SetControlFlag ( ControlFlags flag, bool value ) : void
UpdateTimer_Elapsed ( object obj ) : void

Method Details

AgentMovement() public méthode

Default constructor
public AgentMovement ( GridClient client ) : System
client GridClient
Résultat System

SendManualUpdate() public méthode

Builds an AgentUpdate packet entirely from parameters. This will not touch the state of Self.Movement or Self.Movement.Camera in any way
public SendManualUpdate ( AgentManager controlFlags, System.Vector3 position, System.Vector3 forwardAxis, System.Vector3 leftAxis, System.Vector3 upAxis, Quaternion bodyRotation, Quaternion headRotation, float farClip, AgentFlags flags, AgentState state, bool reliable ) : void
controlFlags AgentManager
position System.Vector3
forwardAxis System.Vector3
leftAxis System.Vector3
upAxis System.Vector3
bodyRotation Quaternion
headRotation Quaternion
farClip float
flags AgentFlags
state AgentState
reliable bool
Résultat void

SendUpdate() public méthode

Send new AgentUpdate packet to update our current camera position and rotation
public SendUpdate ( ) : void
Résultat void

SendUpdate() public méthode

Send new AgentUpdate packet to update our current camera position and rotation
public SendUpdate ( bool reliable ) : void
reliable bool Whether to require server acknowledgement /// of this packet
Résultat void

SendUpdate() public méthode

Send new AgentUpdate packet to update our current camera position and rotation
public SendUpdate ( bool reliable, Simulator simulator ) : void
reliable bool Whether to require server acknowledgement /// of this packet
simulator Simulator Simulator to send the update to
Résultat void

TurnToward() public méthode

Rotates the avatar body and camera toward a target position. This will also anchor the camera position on the avatar
public TurnToward ( System.Vector3 target ) : bool
target System.Vector3 Region coordinates to turn toward
Résultat bool

UpdateFromHeading() public méthode

Send an AgentUpdate with the camera set at the current agent position and pointing towards the heading specified
public UpdateFromHeading ( double heading, bool reliable ) : void
heading double Camera rotation in radians
reliable bool Whether to send the AgentUpdate reliable /// or not
Résultat void

Property Details

BodyRotation public_oe property

public Quaternion BodyRotation
Résultat Quaternion

Camera public_oe property

Agent camera controls
public AgentCamera Camera
Résultat AgentCamera

Flags public_oe property

Currently only used for hiding your group title
public AgentFlags Flags
Résultat AgentFlags

HeadRotation public_oe property

public Quaternion HeadRotation
Résultat Quaternion

State public_oe property

Action state of the avatar, which can currently be typing and editing
public AgentState State
Résultat AgentState