mirror of
https://github.com/opensim/opensim.git
synced 2026-08-10 11:33:28 +08:00
Various small changes (some likely to be removed again soon)
This commit is contained in:
@@ -27,7 +27,7 @@ namespace OpenSim.Region.Environment.Modules
|
||||
m_scene = scene;
|
||||
m_scene.EventManager.OnNewClient += NewClient;
|
||||
|
||||
m_scene.RegisterAPIMethod("API_AddXferFile", new ModuleAPIMethod<bool, string, byte[]>(this.AddNewFile));
|
||||
m_scene.RegisterAPIMethod("API_AddXferFile", new ModuleAPIMethod2<bool, string, byte[]>(this.AddNewFile));
|
||||
}
|
||||
|
||||
public void PostInitialise()
|
||||
|
||||
@@ -9,7 +9,8 @@ using OpenSim.Region.Environment.LandManagement;
|
||||
|
||||
namespace OpenSim.Region.Environment
|
||||
{
|
||||
public delegate TResult ModuleAPIMethod<TResult, TParam0, TParam1>(TParam0 param0, TParam1 param1);
|
||||
public delegate TResult ModuleAPIMethod1<TResult, TParam0>(TParam0 param0);
|
||||
public delegate TResult ModuleAPIMethod2<TResult, TParam0, TParam1>(TParam0 param0, TParam1 param1);
|
||||
|
||||
public class RegionManager
|
||||
{
|
||||
|
||||
@@ -554,6 +554,15 @@ namespace OpenSim.Region.Environment.Scenes
|
||||
}
|
||||
}
|
||||
|
||||
public void StartAnimation(IClientAPI client, LLUUID animID, int seq)
|
||||
{
|
||||
List<ScenePresence> avatars = this.RequestAvatarList();
|
||||
for (int i = 0; i < avatars.Count; i++)
|
||||
{
|
||||
avatars[i].ControllingClient.SendAnimation(animID, seq, client.AgentId);
|
||||
}
|
||||
}
|
||||
|
||||
public virtual void ProcessObjectGrab(uint localID, LLVector3 offsetPos, IClientAPI remoteClient)
|
||||
{
|
||||
this.EventManager.TriggerObjectGrab(localID, offsetPos, remoteClient);
|
||||
|
||||
@@ -90,7 +90,7 @@ namespace OpenSim.Region.Environment.Scenes
|
||||
//API method Delegates
|
||||
|
||||
// this most likely shouldn't be handled as a API method like this, but doing it for testing purposes
|
||||
public ModuleAPIMethod<bool, string, byte[]>AddXferFile = null;
|
||||
public ModuleAPIMethod2<bool, string, byte[]>AddXferFile = null;
|
||||
|
||||
#region Properties
|
||||
|
||||
@@ -196,7 +196,7 @@ namespace OpenSim.Region.Environment.Scenes
|
||||
|
||||
private void SetMethodDelegates()
|
||||
{
|
||||
AddXferFile = (ModuleAPIMethod<bool, string, byte[]>)this.RequestAPIMethod("API_AddXferFile");
|
||||
AddXferFile = (ModuleAPIMethod2<bool, string, byte[]>)this.RequestAPIMethod("API_AddXferFile");
|
||||
}
|
||||
|
||||
#region Script Handling Methods
|
||||
@@ -267,7 +267,7 @@ namespace OpenSim.Region.Environment.Scenes
|
||||
|
||||
//backup scene data
|
||||
storageCount++;
|
||||
if (storageCount > 600) //set to how often you want to backup
|
||||
if (storageCount > 1200) //set to how often you want to backup
|
||||
{
|
||||
Backup();
|
||||
storageCount = 0;
|
||||
@@ -692,6 +692,7 @@ namespace OpenSim.Region.Environment.Scenes
|
||||
|
||||
protected virtual void SubscribeToClientEvents(IClientAPI client)
|
||||
{
|
||||
// client.OnStartAnim += StartAnimation;
|
||||
client.OnRegionHandShakeReply += SendLayerData;
|
||||
//remoteClient.OnRequestWearables += new GenericCall(this.GetInitialPrims);
|
||||
client.OnModifyTerrain += ModifyTerrain;
|
||||
|
||||
@@ -35,6 +35,7 @@ using OpenSim.Framework.Types;
|
||||
using OpenSim.Framework.Communications.Caches;
|
||||
using OpenSim.Region.Terrain;
|
||||
using OpenSim.Framework;
|
||||
using OpenSim.Region.Environment.Interfaces;
|
||||
|
||||
namespace OpenSim.Region.Environment.Scenes
|
||||
{
|
||||
|
||||
@@ -157,7 +157,7 @@ namespace OpenSim.Region.Environment.Scenes
|
||||
this.m_lastname = ControllingClient.LastName;
|
||||
m_localId = m_scene.NextLocalId;
|
||||
AbsolutePosition = ControllingClient.StartPos;
|
||||
|
||||
|
||||
visualParams = new byte[218];
|
||||
for (int i = 0; i < 218; i++)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user