remove another partial class, and map another class back to a real file

afrisby
Sean Dague 2007-12-12 20:45:39 +00:00
parent 5e6483f209
commit 100fb6a0b1
2 changed files with 26 additions and 27 deletions

View File

@ -28,42 +28,41 @@
using System.Collections.Generic; using System.Collections.Generic;
using System.Xml; using System.Xml;
using libsecondlife; using libsecondlife;
using libsecondlife.Packets;
namespace OpenSim.Region.Environment.Scenes namespace OpenSim.Region.Environment.Scenes
{ {
partial class ScenePresence public class AvatarAnimations
{ {
public class AvatarAnimations public Dictionary<string, LLUUID> AnimsLLUUID = new Dictionary<string, LLUUID>();
public Dictionary<LLUUID, string> AnimsNames = new Dictionary<LLUUID, string>();
public AvatarAnimations()
{ {
public Dictionary<string, LLUUID> AnimsLLUUID = new Dictionary<string, LLUUID>(); }
public Dictionary<LLUUID, string> AnimsNames = new Dictionary<LLUUID, string>();
public void LoadAnims()
public AvatarAnimations() {
//MainLog.Instance.Verbose("CLIENT", "Loading avatar animations");
using (XmlTextReader reader = new XmlTextReader("data/avataranimations.xml"))
{ {
} XmlDocument doc = new XmlDocument();
doc.Load(reader);
public void LoadAnims() foreach (XmlNode nod in doc.DocumentElement.ChildNodes)
{
//MainLog.Instance.Verbose("CLIENT", "Loading avatar animations");
using (XmlTextReader reader = new XmlTextReader("data/avataranimations.xml"))
{ {
XmlDocument doc = new XmlDocument(); if (nod.Attributes["name"] != null)
doc.Load(reader);
foreach (XmlNode nod in doc.DocumentElement.ChildNodes)
{ {
if (nod.Attributes["name"] != null) AnimsLLUUID.Add(nod.Attributes["name"].Value, nod.InnerText);
{
AnimsLLUUID.Add(nod.Attributes["name"].Value, nod.InnerText);
}
} }
} }
}
// MainLog.Instance.Verbose("CLIENT", "Loaded " + AnimsLLUUID.Count.ToString() + " animation(s)");
// MainLog.Instance.Verbose("CLIENT", "Loaded " + AnimsLLUUID.Count.ToString() + " animation(s)");
foreach (KeyValuePair<string, LLUUID> kp in Animations.AnimsLLUUID)
{ foreach (KeyValuePair<string, LLUUID> kp in ScenePresence.Animations.AnimsLLUUID)
AnimsNames.Add(kp.Value, kp.Key); {
} AnimsNames.Add(kp.Value, kp.Key);
} }
} }
} }

View File

@ -38,7 +38,7 @@ using OpenSim.Region.Physics.Manager;
namespace OpenSim.Region.Environment.Scenes namespace OpenSim.Region.Environment.Scenes
{ {
public partial class ScenePresence : EntityBase public class ScenePresence : EntityBase
{ {
public static AvatarAnimations Animations; public static AvatarAnimations Animations;
public static byte[] DefaultTexture; public static byte[] DefaultTexture;