// Token: 0x06000209 RID: 521 RVA: 0x000115B0 File Offset: 0x0000F7B0 public static void SetReadme(Pmx pmx, string path) { PmxModelInfo modelInfo = pmx.ModelInfo; PmxModelInfo pmxModelInfo = modelInfo; PmxModelInfo pmxModelInfo2 = pmxModelInfo; pmxModelInfo2.CommentE += Environment.NewLine; PmxTag.SetTag("readme", pmx.ModelInfo.CommentE); }
// Token: 0x0600024C RID: 588 RVA: 0x00012E84 File Offset: 0x00011084 public static string RemoveTag(string tag, string text) { MatchCollection matchCollection = PmxTag.MatchsTag(tag, text, "gp"); for (int i = 0; i < matchCollection.Count; i++) { text = text.Replace(matchCollection[i].Value, ""); } return(text); }
public static string[] GetReadme(Pmx pmx, string root = "") { string[] tag = PmxTag.GetTag("readme", pmx.ModelInfo.CommentE); if (tag != null && !string.IsNullOrEmpty(root)) { for (int i = 0; i < tag.Length; i++) { if (!Path.IsPathRooted(tag[i])) { tag[i] = root + "\\" + tag[i]; } } } return(tag); }
// Token: 0x060001BF RID: 447 RVA: 0x000106C0 File Offset: 0x0000E8C0 public void SetFromText(string text) { this.Clear(); bool flag = !string.IsNullOrEmpty(text); if (flag) { string[] tag = PmxTag.GetTag("BumpMap", text); bool flag2 = tag != null && tag.Length != 0; if (flag2) { this.BumpMapTexture = tag[0]; } string[] tag2 = PmxTag.GetTag("BumpMapUV", text); bool flag3 = tag2 != null && tag2.Length != 0; if (flag3) { this.BumpMapUV = PmxMaterialAttribute.TextToUVTarget(tag2[0]); } string[] tag3 = PmxTag.GetTag("NormalMap", text); bool flag4 = tag3 != null && tag3.Length != 0; if (flag4) { this.NormalMapTexture = tag3[0]; } string[] tag4 = PmxTag.GetTag("NormalMapUV", text); bool flag5 = tag4 != null && tag4.Length != 0; if (flag5) { this.NormalMapUV = PmxMaterialAttribute.TextToUVTarget(tag4[0]); } string[] tag5 = PmxTag.GetTag("CubeMap", text); bool flag6 = tag5 != null && tag5.Length != 0; if (flag6) { this.CubeMapTexture = tag5[0]; } string[] tag6 = PmxTag.GetTag("CubeMapUV", text); bool flag7 = tag6 != null && tag6.Length != 0; if (flag7) { this.CubeMapUV = PmxMaterialAttribute.TextToUVTarget(tag6[0]); } } }
// Token: 0x06000249 RID: 585 RVA: 0x00012D74 File Offset: 0x00010F74 public static string[] GetTag(string tag, string text) { MatchCollection matchCollection = PmxTag.MatchsTag(tag, text, "gp"); bool flag = matchCollection.Count <= 0; string[] result; if (flag) { result = null; } else { string[] array = new string[matchCollection.Count]; for (int i = 0; i < matchCollection.Count; i++) { Match match = matchCollection[i]; string value = match.Groups["gp"].Value; array[i] = (string.IsNullOrEmpty(value) ? "" : value); } result = array; } return(result); }
public void SetFromText(string text) { Clear(); if (!string.IsNullOrEmpty(text)) { string[] tag = PmxTag.GetTag("BumpMap", text); if (tag != null && tag.Length != 0) { BumpMapTexture = tag[0]; } string[] tag2 = PmxTag.GetTag("BumpMapUV", text); if (tag2 != null && tag2.Length != 0) { BumpMapUV = TextToUVTarget(tag2[0]); } string[] tag3 = PmxTag.GetTag("NormalMap", text); if (tag3 != null && tag3.Length != 0) { NormalMapTexture = tag3[0]; } string[] tag4 = PmxTag.GetTag("NormalMapUV", text); if (tag4 != null && tag4.Length != 0) { NormalMapUV = TextToUVTarget(tag4[0]); } string[] tag5 = PmxTag.GetTag("CubeMap", text); if (tag5 != null && tag5.Length != 0) { CubeMapTexture = tag5[0]; } string[] tag6 = PmxTag.GetTag("CubeMapUV", text); if (tag6 != null && tag6.Length != 0) { CubeMapUV = TextToUVTarget(tag6[0]); } } }
// Token: 0x06000208 RID: 520 RVA: 0x00011524 File Offset: 0x0000F724 public static string[] GetReadme(Pmx pmx, string root) { bool flag = root == null; if (flag) { root = ""; } string[] tag = PmxTag.GetTag("readme", pmx.ModelInfo.CommentE); bool flag2 = tag != null && !string.IsNullOrEmpty(root); if (flag2) { for (int i = 0; i < tag.Length; i++) { bool flag3 = !Path.IsPathRooted(tag[i]); if (flag3) { tag[i] = root + "\\" + tag[i]; } } } return(tag); }
// Token: 0x0600020B RID: 523 RVA: 0x0001161B File Offset: 0x0000F81B public static void RemoveReadme(Pmx pmx) { pmx.ModelInfo.CommentE = PmxTag.RemoveTag("readme", pmx.ModelInfo.CommentE); pmx.ModelInfo.CommentE = pmx.ModelInfo.CommentE.Trim(); }
// Token: 0x0600020A RID: 522 RVA: 0x000115F4 File Offset: 0x0000F7F4 public static bool ExistReadme(Pmx pmx) { return(PmxTag.ExistTag("readme", pmx.ModelInfo.CommentE)); }
// Token: 0x0600024B RID: 587 RVA: 0x00012E64 File Offset: 0x00011064 public static bool ExistTag(string tag, string text) { string[] tag2 = PmxTag.GetTag(tag, text); return(tag2 != null); }