aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Examples/SimpleApp/ComplexObject.cs
diff options
context:
space:
mode:
authorlbsa712007-08-15 21:24:25 +0000
committerlbsa712007-08-15 21:24:25 +0000
commit94af93874226bf4441a35bfd4cf498e9ed83ccf5 (patch)
tree4fd6498ca8384f375bfc1365e74469af13954ae0 /OpenSim/Region/Examples/SimpleApp/ComplexObject.cs
parentcompile error removed :) (diff)
downloadopensim-SC_OLD-94af93874226bf4441a35bfd4cf498e9ed83ccf5.zip
opensim-SC_OLD-94af93874226bf4441a35bfd4cf498e9ed83ccf5.tar.gz
opensim-SC_OLD-94af93874226bf4441a35bfd4cf498e9ed83ccf5.tar.bz2
opensim-SC_OLD-94af93874226bf4441a35bfd4cf498e9ed83ccf5.tar.xz
The 'Party Party Groupie Groupie Life is a game' commit:
* Added prototypical MoneyBalance support * Finalized konceptual touch wiring * Turned SimpleApp into a tedious harvesting game.
Diffstat (limited to 'OpenSim/Region/Examples/SimpleApp/ComplexObject.cs')
-rw-r--r--OpenSim/Region/Examples/SimpleApp/ComplexObject.cs23
1 files changed, 23 insertions, 0 deletions
diff --git a/OpenSim/Region/Examples/SimpleApp/ComplexObject.cs b/OpenSim/Region/Examples/SimpleApp/ComplexObject.cs
index b1da33a..5821b9f 100644
--- a/OpenSim/Region/Examples/SimpleApp/ComplexObject.cs
+++ b/OpenSim/Region/Examples/SimpleApp/ComplexObject.cs
@@ -5,6 +5,7 @@ using OpenSim.Region.Environment.Scenes;
5using Axiom.Math; 5using Axiom.Math;
6using libsecondlife; 6using libsecondlife;
7using OpenSim.Framework.Types; 7using OpenSim.Framework.Types;
8using OpenSim.Framework.Interfaces;
8 9
9namespace SimpleApp 10namespace SimpleApp
10{ 11{
@@ -35,6 +36,8 @@ namespace SimpleApp
35 base.UpdateMovement(); 36 base.UpdateMovement();
36 } 37 }
37 38
39
40
38 public ComplexObject(Scene scene, ulong regionHandle, LLUUID ownerID, uint localID, LLVector3 pos ) 41 public ComplexObject(Scene scene, ulong regionHandle, LLUUID ownerID, uint localID, LLVector3 pos )
39 : base(scene, regionHandle, ownerID, localID, pos, BoxShape.Default ) 42 : base(scene, regionHandle, ownerID, localID, pos, BoxShape.Default )
40 { 43 {
@@ -51,5 +54,25 @@ namespace SimpleApp
51 54
52 UpdateParentIDs(); 55 UpdateParentIDs();
53 } 56 }
57
58 public override void OnGrabPart(SceneObjectPart part, LLVector3 offsetPos, IClientAPI remoteClient)
59 {
60 m_parts.Remove(part.UUID);
61 remoteClient.SendKillObject(m_regionHandle, part.LocalID);
62 remoteClient.AddMoney(1);
63 remoteClient.SendChatMessage("Poof!", 1, Pos, "Party Party", LLUUID.Zero);
64 }
65
66 public override void OnGrabGroup( LLVector3 offsetPos, IClientAPI remoteClient)
67 {
68 if( m_parts.Count == 1 )
69 {
70 m_parts.Remove(m_rootPart.UUID);
71 m_scene.RemoveEntity(this);
72 remoteClient.SendKillObject(m_regionHandle, m_rootPart.LocalID);
73 remoteClient.AddMoney(50);
74 remoteClient.SendChatMessage("KABLAM!!!", 1, Pos, "Groupie Groupie", LLUUID.Zero);
75 }
76 }
54 } 77 }
55} 78}