aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/src/world/World.cs
diff options
context:
space:
mode:
authorgareth2007-03-02 22:17:39 +0000
committergareth2007-03-02 22:17:39 +0000
commitcb55056e3bb0d34e51d8efa60cb8ef82484af900 (patch)
tree5bc1a97e7f8c1629dd99433c0751a77159fc3555 /src/world/World.cs
parentr105 somehow got put in wrong place, so replacing files (diff)
downloadopensim-SC-cb55056e3bb0d34e51d8efa60cb8ef82484af900.zip
opensim-SC-cb55056e3bb0d34e51d8efa60cb8ef82484af900.tar.gz
opensim-SC-cb55056e3bb0d34e51d8efa60cb8ef82484af900.tar.bz2
opensim-SC-cb55056e3bb0d34e51d8efa60cb8ef82484af900.tar.xz
Began implementing basic physics engine plugin framework
Diffstat (limited to '')
-rw-r--r--src/world/World.cs18
1 files changed, 13 insertions, 5 deletions
diff --git a/src/world/World.cs b/src/world/World.cs
index ebbd61e..f02f73f 100644
--- a/src/world/World.cs
+++ b/src/world/World.cs
@@ -1,4 +1,5 @@
1using System; 1using System;
2using System.Threading;
2using libsecondlife; 3using libsecondlife;
3using libsecondlife.Packets; 4using libsecondlife.Packets;
4using System.Collections.Generic; 5using System.Collections.Generic;
@@ -13,6 +14,7 @@ namespace OpenSim.world
13 public ScriptEngine Scripts; 14 public ScriptEngine Scripts;
14 public TerrainDecode terrainengine = new TerrainDecode(); 15 public TerrainDecode terrainengine = new TerrainDecode();
15 public uint _localNumber=0; 16 public uint _localNumber=0;
17 public PhysicsEngine physics;
16 18
17 private Random Rand = new Random(); 19 private Random Rand = new Random();
18 20
@@ -28,13 +30,19 @@ namespace OpenSim.world
28 LandMap[i] = 21.4989f; 30 LandMap[i] = 21.4989f;
29 } 31 }
30 32
31 Console.WriteLine("World.cs - Creating script engine instance");
32 // Initialise this only after the world has loaded
33 Scripts = new ScriptEngine(this);
34 } 33 }
35 34
36 public void Update() 35 public void InitLoop() {
37 { 36 Console.WriteLine("World.cs:StartLoop() - Initialising physics");
37 this.physics = new PhysicsEngine();
38 physics.Startup();
39 }
40
41 public void DoStuff() {
42 Thread.Sleep(1000);
43 }
44
45 public void Update() {
38 foreach (libsecondlife.LLUUID UUID in Entities.Keys) 46 foreach (libsecondlife.LLUUID UUID in Entities.Keys)
39 { 47 {
40 Entities[UUID].update(); 48 Entities[UUID].update();