public void Load(LusuoStream ls) { //Debug.Log("模型自身读取数据"); m_resID = ls.ReadInt(); ls.ReadString(out m_strName); ls.ReadVector3(ref m_vPos); ls.ReadVector3(ref m_vRotate); ls.ReadVector3(ref m_vScale); ls.ReadBool(ref m_bStatic); // 读取光照图 ls.ReadInt(ref m_lightMapIndexNum); m_lightMapIndex = new int[m_lightMapIndexNum]; m_lightMapScaleOffset = new Vector4[m_lightMapIndexNum]; for (int i = 0; i < m_lightMapIndexNum; i++) { ls.ReadInt(ref m_lightMapIndex[i]); } for (int i = 0; i < m_lightMapIndexNum; i++) { ls.ReadVector4(ref m_lightMapScaleOffset[i]); } // 读取环境音效 ls.ReadInt(ref m_envSoundNum); m_envSoundResId = new int[m_envSoundNum]; for (int i = 0; i < m_envSoundNum; i++) { ls.ReadInt(ref m_envSoundResId[i]); } }