Add DisableInterRegionTeleportCancellation option in [EntityTransfer] section of OpenSim.ini. False by default.
This option allows the simulator to specify that the cancel button on inter-region teleports should never appear. This exists because sometimes cancellation will result in a stuck avatar requiring relog. It may be hard to prevent this due to the protocol design (the LL grid has the same issue) In small controlled grids where teleport failure is practically impossible it can be better to disable teleport cancellation entirely.0.7.4-extended
parent
adfc8ade9a
commit
85a327dc59
|
@ -64,6 +64,17 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer
|
|||
/// </summary>
|
||||
public bool WaitForAgentArrivedAtDestination { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// If true then we ask the viewer to disable teleport cancellation and ignore teleport requests.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// This is useful in situations where teleport is very likely to always succeed and we want to avoid a
|
||||
/// situation where avatars can be come 'stuck' due to a failed teleport cancellation. Unfortunately, the
|
||||
/// nature of the teleport protocol makes it extremely difficult (maybe impossible) to make teleport
|
||||
/// cancellation consistently suceed.
|
||||
/// </remarks>
|
||||
public bool DisableInterRegionTeleportCancellation { get; set; }
|
||||
|
||||
protected bool m_Enabled = false;
|
||||
|
||||
public Scene Scene { get; private set; }
|
||||
|
@ -114,6 +125,9 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer
|
|||
IConfig transferConfig = source.Configs["EntityTransfer"];
|
||||
if (transferConfig != null)
|
||||
{
|
||||
DisableInterRegionTeleportCancellation
|
||||
= transferConfig.GetBoolean("DisableInterRegionTeleportCancellation", false);
|
||||
|
||||
WaitForAgentArrivedAtDestination
|
||||
= transferConfig.GetBoolean("wait_for_callback", WaitForAgentArrivedAtDestinationDefault);
|
||||
|
||||
|
@ -146,9 +160,11 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer
|
|||
|
||||
protected virtual void OnNewClient(IClientAPI client)
|
||||
{
|
||||
client.OnTeleportCancel += OnClientCancelTeleport;
|
||||
client.OnTeleportHomeRequest += TeleportHome;
|
||||
client.OnTeleportLandmarkRequest += RequestTeleportLandmark;
|
||||
|
||||
if (!DisableInterRegionTeleportCancellation)
|
||||
client.OnTeleportCancel += OnClientCancelTeleport;
|
||||
}
|
||||
|
||||
public virtual void Close() {}
|
||||
|
@ -511,6 +527,9 @@ namespace OpenSim.Region.CoreModules.Framework.EntityTransfer
|
|||
if (sp.ParentID != (uint)0)
|
||||
sp.StandUp();
|
||||
|
||||
if (DisableInterRegionTeleportCancellation)
|
||||
teleportFlags |= (uint)TeleportFlags.DisableCancel;
|
||||
|
||||
// At least on LL 3.3.4, this is not strictly necessary - a teleport will succeed without sending this to
|
||||
// the viewer. However, it might mean that the viewer does not see the black teleport screen (untested).
|
||||
sp.ControllingClient.SendTeleportStart(teleportFlags);
|
||||
|
|
|
@ -464,6 +464,13 @@
|
|||
; shout_distance = 100
|
||||
|
||||
|
||||
[EntityTransfer]
|
||||
;# {DisableInterRegionTeleportCancellation} {} {Determine whether the cancel button is shown at all during teleports.} {false true} false
|
||||
;; This option exists because cancelling at certain points can result in an unuseable session (frozen avatar, etc.)
|
||||
;; Disabling cancellation can be okay in small closed grids where all teleports are highly likely to suceed.
|
||||
;DisableInterRegionTeleportCancellation = false
|
||||
|
||||
|
||||
[Messaging]
|
||||
;# {OfflineMessageModule} {} {Module to use for offline message storage} {OfflineMessageModule *}
|
||||
;; Module to handle offline messaging. The core module requires an external
|
||||
|
|
|
@ -639,6 +639,11 @@
|
|||
; Minimum user level required for HyperGrid teleports
|
||||
LevelHGTeleport = 0
|
||||
|
||||
; Determine whether the cancel button is shown at all during teleports.
|
||||
; This option exists because cancelling at certain points can result in an unuseable session (frozen avatar, etc.)
|
||||
; Disabling cancellation can be okay in small closed grids where all teleports are highly likely to suceed.
|
||||
DisableInterRegionTeleportCancellation = false
|
||||
|
||||
|
||||
[Messaging]
|
||||
; Control which region module is used for instant messaging.
|
||||
|
|
Loading…
Reference in New Issue