aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Examples/SimpleApp/MyWorld.cs
diff options
context:
space:
mode:
authorlbsa712007-06-20 15:18:54 +0000
committerlbsa712007-06-20 15:18:54 +0000
commit64ed1e1b3bea2b187679a7e61a7d56292c47daab (patch)
tree6757719377b1cfd0300e9ff47eba543f5236be26 /OpenSim/Examples/SimpleApp/MyWorld.cs
parent* re-added SimpleApp projects (diff)
downloadopensim-SC-64ed1e1b3bea2b187679a7e61a7d56292c47daab.zip
opensim-SC-64ed1e1b3bea2b187679a7e61a7d56292c47daab.tar.gz
opensim-SC-64ed1e1b3bea2b187679a7e61a7d56292c47daab.tar.bz2
opensim-SC-64ed1e1b3bea2b187679a7e61a7d56292c47daab.tar.xz
* Removed ClientThreads from avatar
* Deleted SimpleApp2 as it's getting wonkier and wonkier by the minute * Added avatar handling to SimpleApp, still don't have any avatar out on the playing field * Removed some warnings * Went from IWorld to Scene *
Diffstat (limited to '')
-rw-r--r--OpenSim/Examples/SimpleApp/MyWorld.cs29
1 files changed, 19 insertions, 10 deletions
diff --git a/OpenSim/Examples/SimpleApp/MyWorld.cs b/OpenSim/Examples/SimpleApp/MyWorld.cs
index d3da1c7..bc7a3b0 100644
--- a/OpenSim/Examples/SimpleApp/MyWorld.cs
+++ b/OpenSim/Examples/SimpleApp/MyWorld.cs
@@ -5,19 +5,28 @@ using OpenSim.Framework.Interfaces;
5using OpenSim.Framework.Types; 5using OpenSim.Framework.Types;
6using OpenSim.Framework.Console; 6using OpenSim.Framework.Console;
7using libsecondlife; 7using libsecondlife;
8using OpenSim.Region;
9using Avatar=OpenSim.Region.Scenes.Avatar;
10using OpenSim.Region.Scenes;
11using OpenSim.Framework;
12using OpenSim.Caches;
13using OpenGrid.Framework.Communications;
8 14
9namespace SimpleApp 15namespace SimpleApp
10{ 16{
11 public class MyWorld : IWorld 17 public class MyWorld : Scene
12 { 18 {
13 private RegionInfo m_regionInfo; 19 private RegionInfo m_regionInfo;
20 private List<OpenSim.Region.Scenes.Avatar> m_avatars;
14 21
15 public MyWorld(RegionInfo regionInfo) 22 public MyWorld(Dictionary<uint, IClientAPI> clientThreads, RegionInfo regionInfo, AuthenticateSessionsBase authen, CommunicationsManager commsMan, AssetCache assetCach)
23 : base(clientThreads, regionInfo, authen, commsMan, assetCach)
16 { 24 {
17 m_regionInfo = regionInfo; 25 m_regionInfo = regionInfo;
26 m_avatars = new List<Avatar>();
18 } 27 }
19 28
20 private void SendLayerData(IClientAPI remoteClient) 29 public override void SendLayerData(IClientAPI remoteClient)
21 { 30 {
22 float[] map = new float[65536]; 31 float[] map = new float[65536];
23 32
@@ -34,7 +43,7 @@ namespace SimpleApp
34 43
35 #region IWorld Members 44 #region IWorld Members
36 45
37 void IWorld.AddNewAvatar(IClientAPI client, LLUUID agentID, bool child) 46 override public void AddNewAvatar(IClientAPI client, LLUUID agentID, bool child)
38 { 47 {
39 LLVector3 pos = new LLVector3(128, 128, 128); 48 LLVector3 pos = new LLVector3(128, 128, 128);
40 49
@@ -65,6 +74,8 @@ namespace SimpleApp
65 74
66 client.SendRegionHandshake(m_regionInfo); 75 client.SendRegionHandshake(m_regionInfo);
67 76
77 OpenSim.Region.Scenes.Avatar avatar = new Avatar( client, this, m_regionInfo );
78
68 } 79 }
69 80
70 private void SendWearables( IClientAPI client ) 81 private void SendWearables( IClientAPI client )
@@ -72,30 +83,28 @@ namespace SimpleApp
72 client.SendWearables( AvatarWearable.DefaultWearables ); 83 client.SendWearables( AvatarWearable.DefaultWearables );
73 } 84 }
74 85
75 void IWorld.RemoveAvatar(LLUUID agentID) 86 public void RemoveAvatar(LLUUID agentID)
76 { 87 {
77 88
78 } 89 }
79 90
80 RegionInfo IWorld.RegionInfo 91 public RegionInfo RegionInfo
81 { 92 {
82 get { return m_regionInfo; } 93 get { return m_regionInfo; }
83 } 94 }
84 95
85 object IWorld.SyncRoot 96 public object SyncRoot
86 { 97 {
87 get { return this; } 98 get { return this; }
88 } 99 }
89 100
90 private uint m_nextLocalId = 1; 101 private uint m_nextLocalId = 1;
91 102
92 uint IWorld.NextLocalId 103 public uint NextLocalId
93 { 104 {
94 get { return m_nextLocalId++; } 105 get { return m_nextLocalId++; }
95 } 106 }
96 107
97 #endregion 108 #endregion
98
99
100 } 109 }
101} 110}