OpenMetaverse.AgentManager.AutoPilot C# (CSharp) Method

AutoPilot() public method

Use the autopilot sim function to move the avatar to a new position. Uses double precision to get precise movements
The z value is currently not handled properly by the simulator
public AutoPilot ( double globalX, double globalY, double z ) : void
globalX double Global X coordinate to move to
globalY double Global Y coordinate to move to
z double Z coordinate to move to
return void
        public void AutoPilot(double globalX, double globalY, double z)
        {
            GenericMessagePacket autopilot = new GenericMessagePacket();

            autopilot.AgentData.AgentID = Client.Self.AgentID;
            autopilot.AgentData.SessionID = Client.Self.SessionID;
            autopilot.AgentData.TransactionID = UUID.Zero;
            autopilot.MethodData.Invoice = UUID.Zero;
            autopilot.MethodData.Method = Utils.StringToBytes("autopilot");
            autopilot.ParamList = new GenericMessagePacket.ParamListBlock[3];
            autopilot.ParamList[0] = new GenericMessagePacket.ParamListBlock();
            autopilot.ParamList[0].Parameter = Utils.StringToBytes(globalX.ToString());
            autopilot.ParamList[1] = new GenericMessagePacket.ParamListBlock();
            autopilot.ParamList[1].Parameter = Utils.StringToBytes(globalY.ToString());
            autopilot.ParamList[2] = new GenericMessagePacket.ParamListBlock();
            autopilot.ParamList[2].Parameter = Utils.StringToBytes(z.ToString());

            Client.Network.SendPacket(autopilot);
        }

Same methods

AgentManager::AutoPilot ( ulong globalX, ulong globalY, float z ) : void