public override void parseXml(SecurityElement xmlelem) { SecurityElement itemXml = null; UtilXml.getXmlChild(xmlelem, "item", ref itemXml); UtilXml.getXmlAttrUInt(itemXml, "id", ref m_sceneId); UtilXml.getXmlAttrStr(itemXml, "name", ref m_sceneName); UtilXml.getXmlAttrStr(itemXml, "res", ref m_levelName); }
public virtual ArrayList getXmlNodeList(SecurityElement config, string itemNode) { SecurityElement objElem = null; UtilXml.getXmlChild(config, itemNode, ref objElem); ArrayList itemNodeList = objElem.Children; return(itemNodeList); }
public void parseXmlElem(SecurityElement elem_) { // 解析 Id UtilXml.getXmlAttrStr(elem_, "Id", ref m_id); // 解析攻击 ArrayList attackActionNodeList = elem_.Children; // AttackAction 攻击动作节点,这个节点只有一个 AttackAction SecurityElement attackActionNode = attackActionNodeList[0] as SecurityElement; m_attackActionNode = new AttackActionNode(); m_attackActionNode.parseXmlElem(attackActionNode); // 解析被击 SecurityElement hurtActionNode = null; UtilXml.getXmlChild(attackActionNode, "HurtAction", ref hurtActionNode); if (hurtActionNode != null) { m_hurtActionNode = new HurtActionNode(); m_hurtActionNode.parseXmlElem(hurtActionNode); } }