Add AnimState to CADU

avinationmerge
Melanie 2012-10-30 21:45:39 +01:00
parent 5328808b18
commit ff61d59e60
1 changed files with 18 additions and 0 deletions

View File

@ -312,6 +312,7 @@ namespace OpenSim.Framework
public AgentGroupData[] Groups; public AgentGroupData[] Groups;
public Animation[] Anims; public Animation[] Anims;
public Animation DefaultAnim = null; public Animation DefaultAnim = null;
public Animation AnimState = null;
public UUID GranterID; public UUID GranterID;
public UUID ParentPart; public UUID ParentPart;
@ -403,6 +404,11 @@ namespace OpenSim.Framework
args["default_animation"] = DefaultAnim.PackUpdateMessage(); args["default_animation"] = DefaultAnim.PackUpdateMessage();
} }
if (AnimState != null)
{
args["animation_state"] = AnimState.PackUpdateMessage();
}
if (Appearance != null) if (Appearance != null)
args["packed_appearance"] = Appearance.Pack(); args["packed_appearance"] = Appearance.Pack();
@ -612,6 +618,18 @@ namespace OpenSim.Framework
} }
} }
if (args["animation_state"] != null)
{
try
{
AnimState = new Animation((OSDMap)args["animation_state"]);
}
catch
{
AnimState = null;
}
}
//if ((args["agent_textures"] != null) && (args["agent_textures"]).Type == OSDType.Array) //if ((args["agent_textures"] != null) && (args["agent_textures"]).Type == OSDType.Array)
//{ //{
// OSDArray textures = (OSDArray)(args["agent_textures"]); // OSDArray textures = (OSDArray)(args["agent_textures"]);