mirror of
https://github.com/opensim/opensim.git
synced 2026-08-07 09:45:47 +08:00
Partially fix autopilot/go here
This now works again except that it requires a click or avatar mvmt to get going This is because the ScenePresence.HandleAgentUpdate() method doesn't trigger until the client does something significant, at which point autopilot takes over. Even clicking is enough to trigger. This will be improved presently.
This commit is contained in:
@@ -140,7 +140,16 @@ namespace OpenSim.Region.OptionalModules.World.NPC
|
||||
{
|
||||
ScenePresence sp;
|
||||
scene.TryGetScenePresence(agentID, out sp);
|
||||
sp.DoAutoPilot(0, pos, m_avatars[agentID]);
|
||||
|
||||
// m_log.DebugFormat(
|
||||
// "[NPC MODULE]: Moving {0} to {1} in {2}", sp.Name, pos, scene.RegionInfo.RegionName);
|
||||
//
|
||||
// List<string> targetArgs = new List<string>();
|
||||
// targetArgs.Add(pos.X);
|
||||
// targetArgs.Add(pos.Y);
|
||||
// targetArgs.Add(pos.Z);
|
||||
// sp.DoMoveToPosition(null, "NPC", targetArgs);
|
||||
// sp.DoMoveToPosition(0, pos, m_avatars[agentID]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user