aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework/Scenes/ScenePresence.cs (unfollow)
Commit message (Collapse)AuthorFilesLines
2013-03-29Check viewer 2/3 attachment calls against avatar appearance attachment data ↵Justin Clark-Casey (justincc)1-5/+2
rather than actually attached objects By checking against the grid's Avatar data, we can ignore viewer side attachments but still initiate these calls simulator-side. Initiating simulator-side is always necessary for version 1 viewers. This is a further commit to resolve http://opensimulator.org/mantis/view.php?id=6581
2013-03-29Fix bug where CHANGED_REGION and/or CHANGED_TELEPORT weren't firing for ↵Justin Clark-Casey (justincc)1-0/+22
scripts in attachments. This was because the script resumption in AttachmentsModule was firing the attach event instead. Had to reinstate the code in 285bd3a do we can resume the scripts there instead, though the bug existed before its removal. This is to resolve http://opensimulator.org/mantis/view.php?id=6578
2013-03-29Eliminate code which tries to restart attachment scripts in ↵Justin Clark-Casey (justincc)1-18/+0
ScenePresence.MakeRootAgent(), since this is already done in AttachmentsModule
2013-03-28If the viewer has already rezzed any attachments itself, then ignore the ↵Justin Clark-Casey (justincc)1-7/+5
simulator-side rez attachments call. This is a further effort to reduce v3 viewer race conditions where this call may clash with the viewer signalling attachment wearing from its current outfit folder.
2013-03-28Fix regression tests by making a new NPC always trigger simulator side ↵Justin Clark-Casey (justincc)1-2/+2
attachment code when created. Regression from previous commit c2093ccc. Failed because NPCs don't set the ViaLogin flag
2013-03-28Move the simulator-side RezAttachments call on login to SP.MakeRootAgent ↵Justin Clark-Casey (justincc)1-10/+31
with the other attachments code, using TeleportFlags.ViaLogin check to fire if necessary. This is to simplify the code (no tricky 'wasChild' signalling required) and to reduce the risk of a thread clash between simulator-side attaching (necessary for v1 viewers) and the viewer-side attaching the v3 viewers perform.
2013-03-23Fix teleporting into the non-SW 256x256 corner of a megaregion, though ↵Justin Clark-Casey (justincc)1-0/+7
currently with a 10 second delay before auto-reteleport to the correct location. This now does a check for border crossing (required to trigger the teleport) immediately in SP.MakeRootAgent(). If left any later, it looks like the physics scene changes the position and stops the cross happening. If done any earlier, nothing happens because the cross-code currently requires a PhysicsActor to be in place, thuogh it's probably not necessary for this case.
2013-03-23Add "show borders" command to show the borders of a region.Justin Clark-Casey (justincc)1-3/+11
This is relevant to mega-regions where the borders are very different to a regular region. Also adds some method doc and other code comments.
2013-03-20Force a viewer object update for attachments at the end of the final ↵Justin Clark-Casey (justincc)1-0/+9
Scene.CompleteMovement() in order to make all multi-attachments appear on the destination region. For some reason, sending updates before this will not have this effect. This may be something related to some viewers (e.g. LL 3.3.4) or something OpenSimulator isn't getting quite right.
2013-03-14Make llGetObjectDetails() return the correct world rotation for a sitting avatarJustin Clark-Casey (justincc)1-5/+35
This addresses http://opensimulator.org/mantis/view.php?id=6567 This creates a ScenePresence.GetWorldRotation() with the same semantics as SOP.GetWorldRotation() SP.Rotation can't be used since it's relative to the sat upon prim if the avatar is sitting.
2013-03-06Add regression test for presence crossing between regions on the same simulator.Justin Clark-Casey (justincc)1-18/+19
Unlike a much earlier commented out version of this test, this is done in synchronous mode.
2013-02-22minor: Add doc to ScenePresence.IsInTransit to make it clear that this is ↵Justin Clark-Casey (justincc)1-0/+6
set only for region crossing and not teleport, etc.
2013-02-16* Fix walking to <NaN, NaN, NaN> via autopilot.teravus1-1/+5
2013-02-10Fix code to check for no spawn points. Possibly a merge artefact?Melanie1-2/+4
2013-02-10Fix teleport/telehub issue:BlueWall1-1/+10
Fix bug that allowed only login access to regions with mis-configured telehubs. Administrators now have teleport access when there exists a mis-configured telehub in the region. Estate owners are now placed at region center in the absence of spawnpoints instead of being denied access. Grid Gods are unrestricted. All others are denied access to the region until spawnpoints are assigned to the telehub object.
2013-02-01Sit and Spin reduction. If sitting, slam avatar angular velocity to zero.teravus1-2/+3
2013-01-30* This adds a bit more to the previous flying roll effect by adding ↵teravus1-10/+50
additional roll when pressing page down, and reducing your roll when pressing page up to make it feel more responsive and give the user more visual feedback.
2013-01-30* Adds a satisfying angular roll when an avatar is flying and turning. ↵teravus1-0/+81
(General, not physics). Makes flying not feel as stiff.
2013-01-19Check the existing ScenePresence.ParentPart to make sure we're not trying to ↵Justin Clark-Casey (justincc)1-2/+1
sit on a prim we're already sat upon, rather than looking up the part from scratch. An adaptation of commit 055b8a2 Having both ParentID and ParentPart references now is redundant. ParentID should probably be eliminated.
2013-01-18Restore previous client AO behaviour by not allowing them to remove the ↵Justin Clark-Casey (justincc)1-1/+1
default animation but continue to allow scripts to do so. This keeps the fix from http://opensimulator.org/mantis/view.php?id=6327 and fixes the behaviour regression in http://opensimulator.org/mantis/view.php?id=6483 Animations may still exhibit different behaviour if both scripts and clients are adjusting animations. A change in the behaviour of client AO to not remove all animations may be a better long term approach.
2013-01-14move resit fix to ScenePresence.cs and allow for requesting sit on objects ↵dahlia1-0/+4
other than the object currently sat on
2012-12-28ScenePresence passes the avatar rotation down to the physics engine. This ↵Robert Adams1-0/+4
will be a no-op for ODE but enables asymmetrical avatars for BulletSim.
2012-12-27Add check to always push terse updates for presences that have new ↵Robert Adams1-3/+8
velocities of zero.
2012-12-13Simplify sit code a bit by determining correct animation in HandleSit ↵Dan Lake1-30/+6
instead of HandleSitRequest. This eliminates m_nextSitAnimation, an unneeded state-saving variable in ScenePresence
2012-11-20Minor formatting for 0962a35d and a few one-line comments as to why that ↵Justin Clark-Casey (justincc)1-8/+7
code is there
2012-11-20Fix movetotarget on mega regions.Iain Oliver1-3/+21
2012-11-02Change to earlier commit for TargetVelocity to support distributed physics.Dan Lake1-3/+3
2012-10-31Add TargetVelocity to PhysicsActor interface to support distributed physics. ↵Dan Lake1-1/+1
No change to existing functions.
2012-10-30Store and send the current movement animation state to a new sim on crossingMelanie1-0/+6
2012-10-29Add "force gc" region console command which manually invokes garbage collection.Justin Clark-Casey (justincc)1-1/+2
For debugging purposes.
2012-10-25Changed "course" to "coarse" in several placesOren Hurvitz1-7/+7
2012-09-04formattingSignpostMarv1-6/+6
2012-09-04although the attachmentPoint argument is a uint, zero is not a valid ↵SignpostMarv1-1/+4
attachment point
2012-08-24Extend "Restarting scripts in attachments" debug log message to show actual ↵Justin Clark-Casey (justincc)1-1/+3
name of user and the region they are in
2012-08-17BulletSim: Properly regenerate hulls when objects made physical.Robert Adams1-8/+8
This fixes the problem of non-base shapes (cubes and spheres) falling through the terrain.
2012-08-17Modify order of code so SOP doesn't set the physics actor flyingRobert Adams1-7/+12
property multiple times every time Update is called. This eliminates zillions of settings which is better for BulletSim. The should be no functionality change.
2012-07-19Stop explicitly closing and nulling out Animator in order to prevent NREs in ↵Justin Clark-Casey (justincc)1-16/+6
various places due to race conditions. Even where checks are being made they aren't enough since they all assume that the Animator they just checked is still there in the next line, which is not necessarily the case without locking. The memory used is small and these should be GC'd anyway when the SP is released. If this is not happening then the wider problem of old SPs being retained needs to be resolved.
2012-07-10If a part has a sit target and an avatar is already sitting, allow another ↵Justin Clark-Casey (justincc)1-7/+4
avatar to sit in the position given if no sit target was set. Previous behave was that the second avatar could not sit. This matches behaviour observed on the LL grid.
2012-07-10refactor: move management of SOP.SitTargetAvatar into SOP.AddSittingAvatar() ↵Justin Clark-Casey (justincc)1-5/+0
and SOP.RemoveSittingAvatar()
2012-07-10Revert "refactor: Add SOP.IsSitTargetOccupied to improve readability"Justin Clark-Casey (justincc)1-2/+2
This reverts commit c8f0d476d2f775ba4d7afca12eeff527b46bb8e2. On reconsideration, I think this is less readable since immediately following code still sets SitTargetAvatar directly
2012-07-10refactor: Add SOP.IsSitTargetOccupied to improve readabilityJustin Clark-Casey (justincc)1-2/+2
2012-07-10refactor: use sit orientation argument passed in to SP.SendSitResponse() ↵Justin Clark-Casey (justincc)1-4/+2
rather than creating a new copy There are no issues with side-effects since this is a struct.
2012-07-10Move common code to detect whether a part has a valid sit target into a SOP ↵Justin Clark-Casey (justincc)1-30/+5
property rather than being repeated in SP. This also makes the detection in SP.FindNextAvailableSitTarget() and SendSitResponse() identical. Previously they varied slightly (SendSitResponse didn't check for an older type of invalid quaternion) but the practical effect is most probably zero.
2012-07-10Remove log line accidentally left in SP.SendSitResponse()Justin Clark-Casey (justincc)1-1/+1
2012-07-09Don't allow a prim to be sat upon if its part of an attachmentJustin Clark-Casey (justincc)1-0/+9
2012-07-09Do not allow a script to attach a prim if its being sat upon.Justin Clark-Casey (justincc)1-1/+17
This prevents a stack overflow where a get position on the avatar will refer to the attachment which will in turn refer back to the avatar. This required recording of all sitting avatars on a prim which is done separately from recording the sit target avatar. Recording HashSet is null if there are no sitting avatars in order to save memory.
2012-06-27refactor: Move ScenePresence <-> AgentData attachments copying code into ↵Justin Clark-Casey (justincc)1-37/+4
AttachmentsModule.
2012-06-25When attachments are being saved and deleted for a closing root agent, ↵Justin Clark-Casey (justincc)1-3/+0
delete first to avoid a hud race condition with update threads. If delete doesn't occur first then the update thread can outrace the IsAttachment = false necessary to save attachments and send hud artifacts to other viewers.
2012-06-11Comment out the scene presence sitting debug log messages for nowJustin Clark-Casey (justincc)1-6/+6
2012-06-08Don't make duplicate call to ScenePresence.Close() separately in ↵Justin Clark-Casey (justincc)1-1/+1
ETM.DoTeleport() if an agent needs closing. This is always done as part of Scene.RemoveClient() Also refactors try/catching in Scene.RemoveClient() to log NREs instead of silently discarding, since these are useful symptoms of problems.