denikson 5 years ago
parent
commit
7fa6fe43b9
45 changed files with 917 additions and 143 deletions
  1. 5 5
      Assembly-CSharp.sln
  2. 33 0
      Assembly-CSharp/AdjustObjHeightToMaidBone.cs
  3. 20 16
      Assembly-CSharp/Assembly-CSharp.csproj
  4. 1 1
      Assembly-CSharp/BaseKagManager.cs
  5. 1 1
      Assembly-CSharp/BasePhotoCustomObject.cs
  6. 1 1
      Assembly-CSharp/BasePhotoWindowManager.cs
  7. 34 4
      Assembly-CSharp/CMSystem.cs
  8. 4 4
      Assembly-CSharp/CharacterMgr.cs
  9. 2 2
      Assembly-CSharp/ControllerShortcutSettingData.cs
  10. 2 0
      Assembly-CSharp/Dance/SettingData.cs
  11. 2 0
      Assembly-CSharp/DanceData.cs
  12. 365 69
      Assembly-CSharp/DanceMain.cs
  13. 1 0
      Assembly-CSharp/DanceSelect.cs
  14. 17 2
      Assembly-CSharp/DanceSetting.cs
  15. 104 0
      Assembly-CSharp/DanceSubtitleMgr.cs
  16. 1 1
      Assembly-CSharp/DeskManager.cs
  17. 3 3
      Assembly-CSharp/DynamicBone.cs
  18. 62 0
      Assembly-CSharp/DynamicLabelBG.cs
  19. 1 1
      Assembly-CSharp/DynamicSkirtBone.cs
  20. 144 0
      Assembly-CSharp/DynamicUIGrid.cs
  21. 1 1
      Assembly-CSharp/EditMod.cs
  22. 1 1
      Assembly-CSharp/EmpireLifeModeManager.cs
  23. 1 1
      Assembly-CSharp/FacilityManager.cs
  24. 2 2
      Assembly-CSharp/GameMain.cs
  25. 1 1
      Assembly-CSharp/GameModeManager.cs
  26. 2 2
      Assembly-CSharp/GameUty.cs
  27. 2 2
      Assembly-CSharp/HandSignShortcut.cs
  28. 1 1
      Assembly-CSharp/Kasizuki/KasizukiManager.cs
  29. 8 3
      Assembly-CSharp/Maid.cs
  30. 1 1
      Assembly-CSharp/MaidParts.cs
  31. 1 1
      Assembly-CSharp/MaidProp.cs
  32. 1 1
      Assembly-CSharp/MaidStatus/Status.cs
  33. 1 1
      Assembly-CSharp/Menu.cs
  34. 1 1
      Assembly-CSharp/Misc.cs
  35. 1 1
      Assembly-CSharp/ModCompile.cs
  36. 2 2
      Assembly-CSharp/OvrIK.cs
  37. 1 1
      Assembly-CSharp/PhotoModeSaveAndLoad.cs
  38. 1 1
      Assembly-CSharp/PlayerStatus/Status.cs
  39. 28 0
      Assembly-CSharp/Product_Mgr.cs
  40. 29 1
      Assembly-CSharp/RhythmAction_Mgr.cs
  41. 17 5
      Assembly-CSharp/SceneEdit.cs
  42. 1 1
      Assembly-CSharp/SceneNPCEdit/SaveData.cs
  43. 1 1
      Assembly-CSharp/ScriptManager.cs
  44. 8 0
      Assembly-CSharp/ThumShot.cs
  45. 1 1
      Assembly-CSharp/WindowPartsFingerPreset.cs

+ 5 - 5
Assembly-CSharp.sln

@@ -3,7 +3,7 @@ Microsoft Visual Studio Solution File, Format Version 12.00
 # Visual Studio 15
 VisualStudioVersion = 15.0.26228.4
 MinimumVisualStudioVersion = 10.0.40219.1
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Assembly-CSharp", "Assembly-CSharp\Assembly-CSharp.csproj", "{C63A29C9-1507-4CD4-8417-048311C88A82}"
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Assembly-CSharp", "Assembly-CSharp\Assembly-CSharp.csproj", "{1100033F-2788-4BBC-9106-CABDF94B43AD}"
 EndProject
 Global
 	GlobalSection(SolutionConfigurationPlatforms) = preSolution
@@ -11,10 +11,10 @@ Global
 		Release|Any CPU = Release|Any CPU
 	EndGlobalSection
 	GlobalSection(ProjectConfigurationPlatforms) = postSolution
-		{C63A29C9-1507-4CD4-8417-048311C88A82}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
-		{C63A29C9-1507-4CD4-8417-048311C88A82}.Debug|Any CPU.Build.0 = Debug|Any CPU
-		{C63A29C9-1507-4CD4-8417-048311C88A82}.Release|Any CPU.ActiveCfg = Release|Any CPU
-		{C63A29C9-1507-4CD4-8417-048311C88A82}.Release|Any CPU.Build.0 = Release|Any CPU
+		{1100033F-2788-4BBC-9106-CABDF94B43AD}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+		{1100033F-2788-4BBC-9106-CABDF94B43AD}.Debug|Any CPU.Build.0 = Debug|Any CPU
+		{1100033F-2788-4BBC-9106-CABDF94B43AD}.Release|Any CPU.ActiveCfg = Release|Any CPU
+		{1100033F-2788-4BBC-9106-CABDF94B43AD}.Release|Any CPU.Build.0 = Release|Any CPU
 	EndGlobalSection
 	GlobalSection(SolutionProperties) = preSolution
 		HideSolutionNode = FALSE

+ 33 - 0
Assembly-CSharp/AdjustObjHeightToMaidBone.cs

@@ -0,0 +1,33 @@
+using System;
+using UnityEngine;
+
+public class AdjustObjHeightToMaidBone : MonoBehaviour
+{
+	private void Awake()
+	{
+		this.m_myTransform = base.transform;
+	}
+
+	public void Adjust(int maidNo, string boneNameY)
+	{
+		Maid maid = GameMain.Instance.CharacterMgr.GetMaid(maidNo);
+		if (maid == null)
+		{
+			Debug.LogError("AdjustObjHeightToMaidBone メイド番号:" + maidNo + "は居ません。");
+			return;
+		}
+		Transform transform = CMT.SearchObjName(maid.body0.m_trBones, boneNameY, true);
+		if (transform == null)
+		{
+			Debug.LogError("AdjustObjHeightToMaidBone ボーン名:" + boneNameY + "は見つかりません。");
+			return;
+		}
+		this.m_myTransform.position = new Vector3(this.m_myTransform.position.x, transform.position.y, this.m_myTransform.position.z);
+	}
+
+	private void Update()
+	{
+	}
+
+	private Transform m_myTransform;
+}

+ 20 - 16
Assembly-CSharp/Assembly-CSharp.csproj

@@ -4,7 +4,7 @@
   <PropertyGroup>
     <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
     <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
-    <ProjectGuid>{C63A29C9-1507-4CD4-8417-048311C88A82}</ProjectGuid>
+    <ProjectGuid>{1100033F-2788-4BBC-9106-CABDF94B43AD}</ProjectGuid>
     <OutputType>Library</OutputType>
     <RootNamespace>Assembly-CSharp</RootNamespace>
     <AssemblyName>Assembly-CSharp</AssemblyName>
@@ -34,49 +34,49 @@
   </PropertyGroup>
   <ItemGroup>
     <Reference Include="Assembly-CSharp-firstpass">
-      <HintPath>..\..\com_managed\Managed\Assembly-CSharp-firstpass.dll</HintPath>
+      <HintPath>..\..\com126\Managed\Assembly-CSharp-firstpass.dll</HintPath>
     </Reference>
     <Reference Include="Assembly-UnityScript-firstpass">
-      <HintPath>..\..\com_managed\Managed\Assembly-UnityScript-firstpass.dll</HintPath>
+      <HintPath>..\..\com126\Managed\Assembly-UnityScript-firstpass.dll</HintPath>
     </Reference>
     <Reference Include="FoveUnityPlugin">
-      <HintPath>..\..\com_managed\Managed\FoveUnityPlugin.dll</HintPath>
+      <HintPath>..\..\com126\Managed\FoveUnityPlugin.dll</HintPath>
     </Reference>
     <Reference Include="Ionic.Zlib">
-      <HintPath>..\..\com_managed\Managed\Ionic.Zlib.dll</HintPath>
+      <HintPath>..\..\com126\Managed\Ionic.Zlib.dll</HintPath>
     </Reference>
     <Reference Include="JsonFx.Json">
-      <HintPath>..\..\com_managed\Managed\JsonFx.Json.dll</HintPath>
+      <HintPath>..\..\com126\Managed\JsonFx.Json.dll</HintPath>
     </Reference>
     <Reference Include="LeapCSharp.NET3.5">
-      <HintPath>..\..\com_managed\Managed\LeapCSharp.NET3.5.dll</HintPath>
+      <HintPath>..\..\com126\Managed\LeapCSharp.NET3.5.dll</HintPath>
     </Reference>
     <Reference Include="System">
-      <HintPath>..\..\com_managed\Managed\System.dll</HintPath>
+      <HintPath>..\..\com126\Managed\System.dll</HintPath>
     </Reference>
     <Reference Include="System.Core">
-      <HintPath>..\..\com_managed\Managed\System.Core.dll</HintPath>
+      <HintPath>..\..\com126\Managed\System.Core.dll</HintPath>
     </Reference>
     <Reference Include="System.Drawing">
-      <HintPath>..\..\com_managed\Managed\System.Drawing.dll</HintPath>
+      <HintPath>..\..\com126\Managed\System.Drawing.dll</HintPath>
     </Reference>
     <Reference Include="System.Windows.Forms">
-      <HintPath>..\..\com_managed\Managed\System.Windows.Forms.dll</HintPath>
+      <HintPath>..\..\com126\Managed\System.Windows.Forms.dll</HintPath>
     </Reference>
     <Reference Include="System.Xml">
-      <HintPath>..\..\com_managed\Managed\System.Xml.dll</HintPath>
+      <HintPath>..\..\com126\Managed\System.Xml.dll</HintPath>
     </Reference>
     <Reference Include="System.Xml.Linq">
-      <HintPath>..\..\com_managed\Managed\System.Xml.Linq.dll</HintPath>
+      <HintPath>..\..\com126\Managed\System.Xml.Linq.dll</HintPath>
     </Reference>
     <Reference Include="UnityEngine">
-      <HintPath>..\..\com_managed\Managed\UnityEngine.dll</HintPath>
+      <HintPath>..\..\com126\Managed\UnityEngine.dll</HintPath>
     </Reference>
     <Reference Include="UnityEngine.UI">
-      <HintPath>..\..\com_managed\Managed\UnityEngine.UI.dll</HintPath>
+      <HintPath>..\..\com126\Managed\UnityEngine.UI.dll</HintPath>
     </Reference>
     <Reference Include="zxing.unity">
-      <HintPath>..\..\com_managed\Managed\zxing.unity.dll</HintPath>
+      <HintPath>..\..\com126\Managed\zxing.unity.dll</HintPath>
     </Reference>
   </ItemGroup>
   <ItemGroup>
@@ -91,6 +91,7 @@
     <Compile Include="ActionDirect.cs" />
     <Compile Include="ActiveAnimation.cs" />
     <Compile Include="AdditionalScenario.cs" />
+    <Compile Include="AdjustObjHeightToMaidBone.cs" />
     <Compile Include="ADVKagManager.cs" />
     <Compile Include="AlignmentPresetWindow.cs" />
     <Compile Include="AMAction.cs" />
@@ -295,6 +296,7 @@
     <Compile Include="DanceSelectManager.cs" />
     <Compile Include="DanceSelectMusicInfo.cs" />
     <Compile Include="DanceSetting.cs" />
+    <Compile Include="DanceSubtitleMgr.cs" />
     <Compile Include="Dance\SettingData.cs" />
     <Compile Include="Dance\UndressItem.cs" />
     <Compile Include="Dance_Note.cs" />
@@ -351,7 +353,9 @@
     <Compile Include="DynamicBoneDemo1.cs" />
     <Compile Include="DynamicBoneMuneCollider.cs" />
     <Compile Include="DynamicBonePlaneCollider.cs" />
+    <Compile Include="DynamicLabelBG.cs" />
     <Compile Include="DynamicSkirtBone.cs" />
+    <Compile Include="DynamicUIGrid.cs" />
     <Compile Include="EditItemTextureCache.cs" />
     <Compile Include="EditMod.cs" />
     <Compile Include="EditOkCancel.cs" />

+ 1 - 1
Assembly-CSharp/BaseKagManager.cs

@@ -5111,7 +5111,7 @@ public class BaseKagManager : IDisposable
 	public void Serialize(BinaryWriter binary)
 	{
 		binary.Write("CM3D2_KAG");
-		binary.Write(1250);
+		binary.Write(1260);
 		byte[] array = this.kag_.Serialize();
 		int value = array.Length;
 		binary.Write(value);

+ 1 - 1
Assembly-CSharp/BasePhotoCustomObject.cs

@@ -173,7 +173,7 @@ public abstract class BasePhotoCustomObject : MonoBehaviour, IComparable<BasePho
 			using (BinaryWriter binaryWriter = new BinaryWriter(memoryStream))
 			{
 				binaryWriter.Write("COM3D2_PHOTO_CUSTOM_OBJECT");
-				binaryWriter.Write(1250);
+				binaryWriter.Write(1260);
 				binaryWriter.Write(this.type.ToString());
 				binaryWriter.Write(this.scale_);
 				binaryWriter.Write(this.enabledTextureColor_);

+ 1 - 1
Assembly-CSharp/BasePhotoWindowManager.cs

@@ -153,7 +153,7 @@ public abstract class BasePhotoWindowManager : MonoBehaviour
 			using (BinaryWriter binaryWriter = new BinaryWriter(memoryStream))
 			{
 				binaryWriter.Write(this.save_header_uidata);
-				binaryWriter.Write(1250);
+				binaryWriter.Write(1260);
 				binaryWriter.Write(this.save_data_.Count);
 				foreach (KeyValuePair<string, Dictionary<string, Dictionary<string, string>>> keyValuePair3 in this.save_data_)
 				{

+ 34 - 4
Assembly-CSharp/CMSystem.cs

@@ -808,7 +808,7 @@ public class CMSystem
 	{
 		XElement xelement = new XElement("Config", new object[]
 		{
-			new XAttribute("Version", 1250),
+			new XAttribute("Version", 1260),
 			new XElement("System", new XElement("SysButtonShowAlways", this.SysButtonShowAlways)),
 			new XElement("Screen", new object[]
 			{
@@ -1133,7 +1133,7 @@ public class CMSystem
 		MemoryStream memoryStream = new MemoryStream();
 		BinaryWriter binaryWriter = new BinaryWriter(memoryStream);
 		binaryWriter.Write("CM3D2_SYSTEM2");
-		binaryWriter.Write(1250);
+		binaryWriter.Write(1260);
 		binaryWriter.Write(this.m_dicEditColorPresetData.Count);
 		foreach (KeyValuePair<int, Dictionary<string, int>> keyValuePair in this.m_dicEditColorPresetData)
 		{
@@ -1739,9 +1739,33 @@ public class CMSystem
 			}
 		}
 
+		public bool EditAutoCam
+		{
+			get
+			{
+				return this.m_bEditAutoCam;
+			}
+			set
+			{
+				this.m_bEditAutoCam = value;
+			}
+		}
+
+		public bool EditEyeToCam
+		{
+			get
+			{
+				return this.m_bEditEyeToCam;
+			}
+			set
+			{
+				this.m_bEditEyeToCam = value;
+			}
+		}
+
 		public void OnBeforeSerialize()
 		{
-			this.m_nVersion = 1250;
+			this.m_nVersion = 1260;
 		}
 
 		public void OnAfterDeserialize()
@@ -1749,7 +1773,7 @@ public class CMSystem
 		}
 
 		[SerializeField]
-		private int m_nVersion = 1250;
+		private int m_nVersion = 1260;
 
 		[SerializeField]
 		private string m_strDShowFilter = "Microsoft DTV-DVD Video Decoder";
@@ -1805,6 +1829,12 @@ public class CMSystem
 		[SerializeField]
 		private CMSystem.SerializeConfig.OVR_HAND_TO_SKIRT m_eOvrHandHitToSkirtVAS = CMSystem.SerializeConfig.OVR_HAND_TO_SKIRT.GRAB;
 
+		[SerializeField]
+		private bool m_bEditAutoCam = true;
+
+		[SerializeField]
+		private bool m_bEditEyeToCam = true;
+
 		public enum OVR_MOVE_TYPE
 		{
 			WARP_DRAW_STEPROT,

+ 4 - 4
Assembly-CSharp/CharacterMgr.cs

@@ -990,7 +990,7 @@ public class CharacterMgr : MonoBehaviour
 		BinaryWriter binaryWriter = new BinaryWriter(memoryStream);
 		string result = string.Empty;
 		binaryWriter.Write("CM3D2_PRESET_S");
-		binaryWriter.Write(1250);
+		binaryWriter.Write(1260);
 		binaryWriter.Write((char)presset_type);
 		maid.SerializePropLowCapacity(binaryWriter);
 		maid.SerializeMultiColor(binaryWriter);
@@ -1007,7 +1007,7 @@ public class CharacterMgr : MonoBehaviour
 		MemoryStream memoryStream = new MemoryStream();
 		BinaryWriter binaryWriter = new BinaryWriter(memoryStream);
 		binaryWriter.Write("CM3D2_PRESET");
-		binaryWriter.Write(1250);
+		binaryWriter.Write(1260);
 		binaryWriter.Write((int)f_type);
 		if (texture2D != null)
 		{
@@ -1053,7 +1053,7 @@ public class CharacterMgr : MonoBehaviour
 		MemoryStream memoryStream = new MemoryStream();
 		BinaryWriter binaryWriter = new BinaryWriter(memoryStream);
 		binaryWriter.Write("CM3D2_PRESET");
-		binaryWriter.Write(1250);
+		binaryWriter.Write(1260);
 		binaryWriter.Write((int)f_type);
 		if (texture2D != null)
 		{
@@ -1312,7 +1312,7 @@ public class CharacterMgr : MonoBehaviour
 	public bool Serialize(BinaryWriter bwWrite)
 	{
 		bwWrite.Write("CM3D2_CHR_MGR");
-		bwWrite.Write(1250);
+		bwWrite.Write(1260);
 		this.m_PlayerStatus.Serialize(bwWrite);
 		bwWrite.Write(this.m_listStockMan.Count);
 		for (int i = 0; i < this.m_listStockMan.Count; i++)

+ 2 - 2
Assembly-CSharp/ControllerShortcutSettingData.cs

@@ -33,7 +33,7 @@ public static class ControllerShortcutSettingData
 	{
 		public void OnBeforeSerialize()
 		{
-			this.m_nVersion = 1250;
+			this.m_nVersion = 1260;
 		}
 
 		public void OnAfterDeserialize()
@@ -261,7 +261,7 @@ public static class ControllerShortcutSettingData
 		private const string CONF_NAME = "OvrControllerShortcutConfig.json";
 
 		[SerializeField]
-		private int m_nVersion = 1250;
+		private int m_nVersion = 1260;
 
 		[SerializeField]
 		private bool IsDirectShortcutMode = true;

+ 2 - 0
Assembly-CSharp/Dance/SettingData.cs

@@ -30,5 +30,7 @@ namespace Dance
 		public bool FPSCamMode;
 
 		public bool AllRelease;
+
+		public bool IsSubtitleOn = true;
 	}
 }

+ 2 - 0
Assembly-CSharp/DanceData.cs

@@ -58,6 +58,8 @@ public class DanceData
 
 	public bool RhythmGameCorrespond = true;
 
+	public string SubtitleSheetName = string.Empty;
+
 	public enum BgType
 	{
 		LiveStage,

+ 365 - 69
Assembly-CSharp/DanceMain.cs

@@ -138,14 +138,33 @@ public class DanceMain : MonoBehaviour
 				this.maid_event_binary_.AttachObject(this.m_AnimatorData.getTake(this.m_strPlayTakeName));
 			}
 		}
-		foreach (string str in this.m_listKuchiPakuFile)
+		this.m_listKuchiPattern = new string[this.m_listKuchiPakuFile.Count];
+		Func<string, string> func = delegate(string fn)
 		{
-			TextAsset textAsset = Resources.Load("SceneDance/" + str) as TextAsset;
-			NDebug.Assert(textAsset != null, "口パクパターンテキストファイルが開けません。" + str);
-			string text = textAsset.text;
-			NDebug.Assert(text.Length != 0, "口パクパターンファイル内が空です。" + str);
-			text = Regex.Replace(text, "(\\r|\\n| )", string.Empty);
-			this.m_listKuchiPattern.Add(text);
+			TextAsset textAsset = Resources.Load("SceneDance/" + fn) as TextAsset;
+			NDebug.Assert(textAsset != null, "口パクパターンテキストファイルが開けません。" + fn);
+			string text3 = textAsset.text;
+			NDebug.Assert(text3.Length != 0, "口パクパターンファイル内が空です。" + fn);
+			return Regex.Replace(text3, "(\\r|\\n| )", string.Empty);
+		};
+		for (int l = 0; l < this.m_listKuchiPakuFile.Count; l++)
+		{
+			string text = this.m_listKuchiPakuFile[l];
+			if (!string.IsNullOrEmpty(text))
+			{
+				this.m_listKuchiPattern[l] = func(text);
+			}
+		}
+		if (this.m_KuchipakuCacheFileName != null)
+		{
+			for (int m2 = 0; m2 < this.m_KuchipakuCacheFileName.Length; m2++)
+			{
+				string text2 = this.m_KuchipakuCacheFileName[m2];
+				if (!string.IsNullOrEmpty(text2))
+				{
+					this.m_KuchiPatternCache[text2] = func(text2);
+				}
+			}
 		}
 		this.m_AnimatorData.playOnStart = null;
 		this.m_AnimatorData.bAutoTimeUpdate = false;
@@ -164,9 +183,9 @@ public class DanceMain : MonoBehaviour
 		{
 			gameObject.GetComponent<RhythmAction_Mgr>().InstanceInit();
 		}
-		for (int l = 0; l < this.m_listTestPreset.Count; l++)
+		for (int n = 0; n < this.m_listTestPreset.Count; n++)
 		{
-			Maid maid = GameMain.Instance.CharacterMgr.GetMaid(l);
+			Maid maid = GameMain.Instance.CharacterMgr.GetMaid(n);
 			if (maid)
 			{
 				if (!this.m_maidUser)
@@ -187,68 +206,107 @@ public class DanceMain : MonoBehaviour
 		GameMain.Instance.CharacterMgr.ResetCharaPosAll();
 		if (DanceMain.SelectDanceData != null)
 		{
-			for (int m = 0; m < DanceMain.SelectDanceData.select_chara_num; m++)
+			for (int num = 0; num < DanceMain.SelectDanceData.select_chara_num; num++)
 			{
-				RhythmAction_Mgr.Instance.FactOrderList.Add(GameMain.Instance.CharacterMgr.GetMaid(m));
+				RhythmAction_Mgr.Instance.FactOrderList.Add(GameMain.Instance.CharacterMgr.GetMaid(num));
 			}
 		}
 		if (RhythmAction_Mgr.NowDance != RhythmAction_Mgr.DanceType.BenchMark && DanceMain.SelectDanceData != null && DanceMain.SelectDanceData.maid_order.Count > 0)
 		{
 			List<Maid> list = new List<Maid>();
-			for (int n = 0; n < DanceMain.SelectDanceData.maid_order.Count; n++)
+			for (int num2 = 0; num2 < DanceMain.SelectDanceData.maid_order.Count; num2++)
 			{
-				list.Add(GameMain.Instance.CharacterMgr.GetMaid(n));
+				list.Add(GameMain.Instance.CharacterMgr.GetMaid(num2));
 			}
 			GameMain.Instance.CharacterMgr.DeactivateCharaAll();
 			GameMain.Instance.CharacterMgr.DeactivateMaid(0);
-			for (int num = 0; num < DanceMain.SelectDanceData.maid_order.Count; num++)
+			for (int num3 = 0; num3 < DanceMain.SelectDanceData.maid_order.Count; num3++)
 			{
-				int index = DanceMain.SelectDanceData.maid_order[num];
+				int index = DanceMain.SelectDanceData.maid_order[num3];
 				if (list[index])
 				{
-					GameMain.Instance.CharacterMgr.SetActiveMaid(list[index], num);
+					GameMain.Instance.CharacterMgr.SetActiveMaid(list[index], num3);
 					list[index].Visible = true;
 				}
 			}
 		}
-		if (RhythmAction_Mgr.Instance.FactOrderList.Any((Maid e) => !e) || DanceMain.SelectDanceData == null)
+		if (this.m_listTestPreset.Count <= RhythmAction_Mgr.Instance.FactOrderList.Count)
 		{
-			for (int num2 = 0; num2 < this.m_listTestPreset.Count; num2++)
+			if (!RhythmAction_Mgr.Instance.FactOrderList.Any((Maid e) => !e) && DanceMain.SelectDanceData != null)
 			{
-				Maid maid2 = GameMain.Instance.CharacterMgr.GetMaid(num2);
-				if (!maid2)
+				goto IL_97D;
+			}
+		}
+		for (int num4 = 0; num4 < this.m_listTestPreset.Count; num4++)
+		{
+			Maid maid2 = GameMain.Instance.CharacterMgr.GetMaid(num4);
+			if (!maid2)
+			{
+				maid2 = GameMain.Instance.CharacterMgr.AddStockMaid();
+				GameMain.Instance.CharacterMgr.SetActiveMaid(maid2, num4);
+				CharacterMgr.Preset preset;
+				if (DanceMain.SelectDanceData != null && num4 < DanceMain.SelectDanceData.preset_name.Count && !string.IsNullOrEmpty(DanceMain.SelectDanceData.preset_name[num4]))
 				{
-					maid2 = GameMain.Instance.CharacterMgr.AddStockMaid();
-					GameMain.Instance.CharacterMgr.SetActiveMaid(maid2, num2);
-					CharacterMgr.Preset preset;
-					if (DanceMain.SelectDanceData != null && !string.IsNullOrEmpty(DanceMain.SelectDanceData.preset_name[num2]))
-					{
-						preset = GameMain.Instance.CharacterMgr.PresetLoadFromResources(DanceMain.SelectDanceData.preset_name[num2]);
-					}
-					else
-					{
-						preset = GameMain.Instance.CharacterMgr.PresetLoadFromResources(this.m_listTestPreset[num2]);
-					}
-					if (preset != null)
-					{
-						GameMain.Instance.CharacterMgr.PresetSet(maid2, preset);
-					}
-					this.m_listTempMaid.Add(maid2);
-					maid2.Visible = true;
+					preset = GameMain.Instance.CharacterMgr.PresetLoadFromResources(DanceMain.SelectDanceData.preset_name[num4]);
+				}
+				else
+				{
+					preset = GameMain.Instance.CharacterMgr.PresetLoadFromResources(this.m_listTestPreset[num4]);
+				}
+				if (preset != null)
+				{
+					GameMain.Instance.CharacterMgr.PresetSet(maid2, preset);
+				}
+				this.m_listTempMaid.Add(maid2);
+				maid2.Visible = true;
+			}
+		}
+		if (DanceMain.SelectDanceData != null)
+		{
+			for (int num5 = 0; num5 < DanceMain.SelectDanceData.maid_order.Count; num5++)
+			{
+				int index2 = DanceMain.SelectDanceData.maid_order[num5];
+				if (!RhythmAction_Mgr.Instance.FactOrderList[index2])
+				{
+					RhythmAction_Mgr.Instance.FactOrderList[index2] = GameMain.Instance.CharacterMgr.GetMaid(num5);
 				}
 			}
-			if (DanceMain.SelectDanceData != null)
+		}
+		IL_97D:
+		if (this.m_PresetCopyToDummyChara != null)
+		{
+			NDebug.Assert(this.m_PresetCopyToDummyChara.Length <= this.m_listDummyAnimChara.Count<GameObject>(), "PresetCopyToDummyChara は listDummyAnimChara の数以下である必要があります。");
+			for (int num6 = 0; num6 < this.m_PresetCopyToDummyChara.Length; num6++)
 			{
-				for (int num3 = 0; num3 < DanceMain.SelectDanceData.maid_order.Count; num3++)
+				int num7 = this.m_PresetCopyToDummyChara[num6];
+				if (num7 != num6)
 				{
-					int index2 = DanceMain.SelectDanceData.maid_order[num3];
-					if (!RhythmAction_Mgr.Instance.FactOrderList[index2])
+					Maid maid3 = GameMain.Instance.CharacterMgr.GetMaid(num7);
+					if (maid3)
 					{
-						RhythmAction_Mgr.Instance.FactOrderList[index2] = GameMain.Instance.CharacterMgr.GetMaid(num3);
+						byte[] buffer = GameMain.Instance.CharacterMgr.PresetSaveNotWriteFile(maid3, CharacterMgr.PresetType.All);
+						BinaryReader binaryReader = new BinaryReader(new MemoryStream(buffer));
+						CharacterMgr.Preset f_prest = GameMain.Instance.CharacterMgr.PresetLoad(binaryReader, string.Empty);
+						binaryReader.Close();
+						Maid maidDest = GameMain.Instance.CharacterMgr.GetMaid(num6);
+						if (maidDest != null && this.m_listTempMaid.Find((Maid m) => m == maidDest) != null)
+						{
+							GameMain.Instance.CharacterMgr.PresetSet(maidDest, f_prest);
+							maidDest.AllProcPropSeqStart();
+						}
+						else
+						{
+							Debug.LogError("Presetコピー先メイドが居ないか、一時雇用メイドではありません。");
+						}
 					}
 				}
 			}
 		}
+		this.m_KuchipakuAudioStartTimeAtMaid = new float[this.m_listDummyAnimChara.Count<GameObject>()];
+		for (int num8 = 0; num8 < this.m_KuchipakuAudioStartTimeAtMaid.Length; num8++)
+		{
+			this.m_KuchipakuAudioStartTimeAtMaid[num8] = 0f;
+		}
 	}
 
 	private void Start()
@@ -347,6 +405,44 @@ public class DanceMain : MonoBehaviour
 		GameMain.Instance.MainCamera.FadeIn(f_fTime, false, null, false, true, default(Color));
 	}
 
+	public void ChangeAnimation(int maidNo, string animName, float fadeTime)
+	{
+		Maid maid = GameMain.Instance.CharacterMgr.GetMaid(maidNo);
+		try
+		{
+			maid.CrossFade(animName + ".anm", false, false, false, fadeTime, 1f);
+		}
+		catch (Exception ex)
+		{
+			NDebug.Assert(string.Concat(new object[]
+			{
+				"ChangeAnimation メイド ",
+				maidNo,
+				" : ",
+				animName,
+				" は不正です。\n",
+				ex.Message
+			}), false);
+		}
+	}
+
+	public void ChangeKuchipaku(int maidNo, string kuchipakuName)
+	{
+		Maid maid = GameMain.Instance.CharacterMgr.GetMaid(maidNo);
+		maid.StartKuchipakuPattern((!(this.m_audioNew != null)) ? 0f : (this.m_audioNew.time * -1f), this.m_KuchiPatternCache[kuchipakuName], true);
+	}
+
+	public void SetActiveObj(GameObject targetObj, bool visible)
+	{
+		targetObj.SetActive(visible);
+	}
+
+	public void SetEyeTarget(int maidNo, GameObject targetObj)
+	{
+		Maid maid = GameMain.Instance.CharacterMgr.GetMaid(maidNo);
+		maid.EyeToTargetObject(targetObj.transform, 0f);
+	}
+
 	private void ChangeObj(AMTake f_take, string f_strOldObjName, GameObject f_goNew)
 	{
 		AMTranslationTrack[] array = f_take.findTranslationTrack(f_strOldObjName);
@@ -369,6 +465,7 @@ public class DanceMain : MonoBehaviour
 	public void OnDestroy()
 	{
 		this.Uninit();
+		NUty.GCFree();
 		Debug.Log("DanceMain::OnDestroy");
 	}
 
@@ -411,19 +508,24 @@ public class DanceMain : MonoBehaviour
 				this.m_listMaid[i].AllIKDetach(0f);
 				this.m_listMaid[i].SetAutoTwist(Maid.AutoTwist.WristL, true);
 				this.m_listMaid[i].SetAutoTwist(Maid.AutoTwist.WristR, true);
+				Transform[] componentsInChildren = this.m_listMaid[i].gameObject.GetComponentsInChildren<Transform>(true);
+				foreach (Transform transform in componentsInChildren)
+				{
+					transform.gameObject.layer = LayerMask.NameToLayer("Charactor");
+				}
 			}
 		}
-		for (int j = 0; j < this.m_listItemObject.Count; j++)
+		for (int k = 0; k < this.m_listItemObject.Count; k++)
 		{
-			if (this.m_listItemObject[j] != null)
+			if (this.m_listItemObject[k] != null)
 			{
-				UnityEngine.Object.DestroyImmediate(this.m_listItemObject[j]);
+				UnityEngine.Object.DestroyImmediate(this.m_listItemObject[k]);
 			}
 		}
 		this.m_listItemObject.Clear();
-		for (int k = 0; k < this.m_listTempMaid.Count; k++)
+		for (int l = 0; l < this.m_listTempMaid.Count; l++)
 		{
-			GameMain.Instance.CharacterMgr.BanishmentMaid(this.m_listTempMaid[k]);
+			GameMain.Instance.CharacterMgr.BanishmentMaid(this.m_listTempMaid[l]);
 		}
 		if (!DanceMain.KaraokeMode)
 		{
@@ -604,10 +706,13 @@ public class DanceMain : MonoBehaviour
 					{
 						this.m_listMaid[l].EyeToCamera(Maid.EyeMoveType.目だけ向ける, 0f);
 					}
-					NDebug.Assert(this.m_listKuchiPattern.Count == this.m_listMaid.Count, "メイド数と口パクパターン数が異なります。");
+					NDebug.Assert(this.m_listKuchiPattern.Length == this.m_listMaid.Count, "メイド数と口パクパターン数が異なります。");
 					for (int m = 0; m < this.m_listMaid.Count; m++)
 					{
-						this.m_listMaid[m].StartKuchipakuPattern(0f, this.m_listKuchiPattern[m], true);
+						if (!string.IsNullOrEmpty(this.m_listKuchiPattern[m]))
+						{
+							this.m_listMaid[m].StartKuchipakuPattern(0f, this.m_listKuchiPattern[m], true);
+						}
 					}
 				}
 				this.m_eMode = DanceMain.Mode.LoadChara;
@@ -630,16 +735,42 @@ public class DanceMain : MonoBehaviour
 						}
 						int num2 = num - 1;
 						Maid maid = GameMain.Instance.CharacterMgr.GetMaid(num2);
-						string name = maid.CrossFade(this.m_listAnimName[num2] + ".anm", false, false, false, 0f, 1f);
-						Animation component = maid.body0.m_Bones.GetComponent<Animation>();
-						component.Stop();
-						amanimationTrack.obj = maid.body0.m_Bones;
-						NDebug.Assert(amanimationTrack.cache.Count == 1, "キャラアニメーショントラックにはアクションを一つしか使えません。(開始と終了キーひとつのみ)");
-						foreach (AMAction amaction5 in amanimationTrack.cache)
+						IEnumerator enumerator5 = Enum.GetValues(typeof(Maid.AutoTwist)).GetEnumerator();
+						try
+						{
+							while (enumerator5.MoveNext())
+							{
+								object obj = enumerator5.Current;
+								maid.SetAutoTwist((Maid.AutoTwist)obj, true);
+							}
+						}
+						finally
+						{
+							IDisposable disposable;
+							if ((disposable = (enumerator5 as IDisposable)) != null)
+							{
+								disposable.Dispose();
+							}
+						}
+						if (!string.IsNullOrEmpty(this.m_listAnimName[num2]))
+						{
+							string name = maid.CrossFade(this.m_listAnimName[num2] + ".anm", false, false, false, 0f, 1f);
+							Animation component = maid.body0.m_Bones.GetComponent<Animation>();
+							component.Stop();
+							amanimationTrack.obj = maid.body0.m_Bones;
+							foreach (AMAction amaction5 in amanimationTrack.cache)
+							{
+								AMAnimationAction amanimationAction = (AMAnimationAction)amaction5;
+								amanimationAction.amClip = component.GetClip(name);
+								amanimationAction.obj = maid.body0.m_Bones;
+							}
+						}
+						else
 						{
-							AMAnimationAction amanimationAction = (AMAnimationAction)amaction5;
-							amanimationAction.amClip = component.GetClip(name);
-							amanimationAction.obj = maid.body0.m_Bones;
+							this.m_focePauseAnim.Add(new DanceMain.AnimTime
+							{
+								anim = maid.body0.m_Bones.GetComponent<Animation>()
+							});
 						}
 						if (this.UseFloorHitY)
 						{
@@ -662,9 +793,79 @@ public class DanceMain : MonoBehaviour
 							}
 						}
 					}
-					for (int num4 = 0; num4 < this.m_listDebugObj.Count; num4++)
+					if (this.m_MoveToDummyCharaPos != null)
+					{
+						NDebug.Assert(this.m_MoveToDummyCharaPos.Length <= this.m_listDummyAnimChara.Count<GameObject>(), "MoveToDummyCharaPos は listDummyAnimChara の数以下である必要があります。");
+						for (int num4 = 0; num4 < this.m_MoveToDummyCharaPos.Length; num4++)
+						{
+							if (this.m_MoveToDummyCharaPos[num4])
+							{
+								Vector3 position = this.m_listDummyAnimChara[num4].transform.position;
+								Maid maid3 = GameMain.Instance.CharacterMgr.GetMaid(num4);
+								if (maid3 != null)
+								{
+									maid3.SetPos(position);
+								}
+							}
+						}
+					}
+					if (this.m_LayerChangeToDummyChara != null)
 					{
-						UnityEngine.Object.DestroyImmediate(this.m_listDebugObj[num4]);
+						NDebug.Assert(this.m_LayerChangeToDummyChara.Length <= this.m_listDummyAnimChara.Count<GameObject>(), "LayerChangeToDummyChara は listDummyAnimChara の数以下である必要があります。");
+						for (int num5 = 0; num5 < this.m_LayerChangeToDummyChara.Length; num5++)
+						{
+							if (this.m_LayerChangeToDummyChara[num5])
+							{
+								int layer = this.m_listDummyAnimChara[num5].layer;
+								Maid maid4 = GameMain.Instance.CharacterMgr.GetMaid(num5);
+								if (maid4 != null)
+								{
+									Transform[] componentsInChildren = maid4.gameObject.GetComponentsInChildren<Transform>(true);
+									foreach (Transform transform3 in componentsInChildren)
+									{
+										transform3.gameObject.layer = layer;
+									}
+								}
+							}
+						}
+					}
+					if (this.m_EyeTarget != null)
+					{
+						NDebug.Assert(this.m_EyeTarget.Length <= this.m_listDummyAnimChara.Count<GameObject>(), "EyeTarget は listDummyAnimChara の数以下である必要があります。");
+						for (int num7 = 0; num7 < this.m_EyeTarget.Length; num7++)
+						{
+							if (this.m_EyeTarget[num7] != null)
+							{
+								Maid maid5 = GameMain.Instance.CharacterMgr.GetMaid(num7);
+								if (maid5 != null)
+								{
+									maid5.EyeToCamera(Maid.EyeMoveType.目だけ向ける, 0f);
+									maid5.body0.trsLookTarget = this.m_EyeTarget[num7].transform;
+								}
+							}
+						}
+					}
+					if (this.m_MotionCacheEnable != null)
+					{
+						NDebug.Assert(this.m_MotionCacheEnable.Length <= this.m_listDummyAnimChara.Count<GameObject>(), "MotionCacheEnable は listDummyAnimChara の数以下である必要があります。");
+						for (int num8 = 0; num8 < this.m_MotionCacheEnable.Length; num8++)
+						{
+							if (this.m_MotionCacheEnable[num8])
+							{
+								Maid maid6 = GameMain.Instance.CharacterMgr.GetMaid(num8);
+								if (maid6 != null)
+								{
+									for (int num9 = 0; num9 < this.m_MotionCacheFileName.Length; num9++)
+									{
+										maid6.CacheAnime(this.m_MotionCacheFileName[num9], false, false);
+									}
+								}
+							}
+						}
+					}
+					for (int num10 = 0; num10 < this.m_listDebugObj.Count; num10++)
+					{
+						UnityEngine.Object.DestroyImmediate(this.m_listDebugObj[num10]);
 					}
 					this.m_listDebugObj.Clear();
 				}
@@ -688,26 +889,69 @@ public class DanceMain : MonoBehaviour
 		}
 		else if (this.m_eMode == DanceMain.Mode.Exec)
 		{
-			if (!RhythmAction_Mgr.Instance.IsPause)
+			bool isPause = RhythmAction_Mgr.Instance.IsPause;
+			if (!isPause)
 			{
-				float num5 = RhythmAction_Mgr.Instance.DanceDeltaTime;
+				float num11 = RhythmAction_Mgr.Instance.DanceDeltaTime;
 				if (this.m_audioNew != null && this.m_audioNew.isPlaying)
 				{
 					float time = this.m_audioNew.time;
-					for (int num6 = 0; num6 < this.m_listMaid.Count; num6++)
+					for (int num12 = 0; num12 < this.m_listMaid.Count; num12++)
 					{
-						this.m_listMaid[num6].FoceKuchipakuUpdate(time);
+						this.m_listMaid[num12].FoceKuchipakuUpdate(time);
 					}
 					if (this.m_bAudioFirst)
 					{
-						float num7 = time;
-						num5 = Time.realtimeSinceStartup - this.m_fTakeStartRealTime;
+						float num13 = time;
+						num11 = Time.realtimeSinceStartup - this.m_fTakeStartRealTime;
 						this.m_bAudioFirst = false;
-						this.m_fOffsetTime = num7 - num5;
+						this.m_fOffsetTime = num13 - num11;
 						RhythmAction_Mgr.Instance.RhythmGame_Start();
 					}
 				}
-				this.m_fNowRealTime += num5;
+				this.m_fNowRealTime += num11;
+			}
+			if (isPause != this.m_pauseBack)
+			{
+				foreach (DanceMain.AnimTime animTime in this.m_focePauseAnim)
+				{
+					if (isPause)
+					{
+						IEnumerator enumerator8 = animTime.anim.GetEnumerator();
+						try
+						{
+							while (enumerator8.MoveNext())
+							{
+								object obj2 = enumerator8.Current;
+								AnimationState animationState = (AnimationState)obj2;
+								animTime.stateTimeList.Add(new DanceMain.AnimTime.StateTime
+								{
+									state = animationState,
+									time = animationState.time
+								});
+								animationState.speed = 0f;
+							}
+						}
+						finally
+						{
+							IDisposable disposable2;
+							if ((disposable2 = (enumerator8 as IDisposable)) != null)
+							{
+								disposable2.Dispose();
+							}
+						}
+					}
+					else
+					{
+						foreach (DanceMain.AnimTime.StateTime stateTime in animTime.stateTimeList)
+						{
+							stateTime.state.time = stateTime.time;
+							stateTime.state.speed = 1f;
+						}
+						animTime.stateTimeList.Clear();
+					}
+				}
+				this.m_pauseBack = isPause;
 			}
 			if (this.IsForceDanceEnd || this.m_AnimatorData.takeName == null || this.IsDanceSkip || (DanceMain.KaraokeMode && Input.GetKeyDown(KeyCode.Return)))
 			{
@@ -761,7 +1005,7 @@ public class DanceMain : MonoBehaviour
 
 	public List<string> m_listKuchiPakuFile = new List<string>();
 
-	private List<string> m_listKuchiPattern = new List<string>();
+	private string[] m_listKuchiPattern;
 
 	private List<Maid> m_listMaid = new List<Maid>();
 
@@ -823,6 +1067,44 @@ public class DanceMain : MonoBehaviour
 	[Header("AdjustScript読み込みに要する時間")]
 	private float m_LoadScriptTime = 3f;
 
+	[SerializeField]
+	[Header("初期化時にダミーキャラの位置にメイドを移動させるメイド番号スイッチ")]
+	public bool[] m_MoveToDummyCharaPos;
+
+	[SerializeField]
+	[Header("初期化時にダミーキャラのLayerをメイドに設定させるメイド番号スイッチ")]
+	public bool[] m_LayerChangeToDummyChara;
+
+	public Light[] m_OffScreenLight;
+
+	[SerializeField]
+	[Header("初期化時にメイドの視線に設定するオブジェクト対メイド番号")]
+	public GameObject[] m_EyeTarget;
+
+	[SerializeField]
+	[Header("特定メイド番号からダミーメイドへの容姿のコピー(Elementが元メイド番号/値が先メイド番号")]
+	public int[] m_PresetCopyToDummyChara;
+
+	[SerializeField]
+	[Header("途中でモーションを変えるメイド番号のファイル名リスト")]
+	public bool[] m_MotionCacheEnable;
+
+	[SerializeField]
+	[Header("途中でモーションを変える場合のファイル名リスト")]
+	public string[] m_MotionCacheFileName;
+
+	[SerializeField]
+	[Header("途中で口パクを変える場合のファイル名リスト")]
+	public string[] m_KuchipakuCacheFileName;
+
+	private Dictionary<string, string> m_KuchiPatternCache = new Dictionary<string, string>();
+
+	public float[] m_KuchipakuAudioStartTimeAtMaid;
+
+	private List<DanceMain.AnimTime> m_focePauseAnim = new List<DanceMain.AnimTime>();
+
+	private bool m_pauseBack;
+
 	private bool m_bFinished;
 
 	private float m_fNowRealTime;
@@ -842,4 +1124,18 @@ public class DanceMain : MonoBehaviour
 		Finish,
 		LoadScript
 	}
+
+	private class AnimTime
+	{
+		public Animation anim;
+
+		public List<DanceMain.AnimTime.StateTime> stateTimeList = new List<DanceMain.AnimTime.StateTime>();
+
+		public class StateTime
+		{
+			public AnimationState state;
+
+			public float time;
+		}
+	}
 }

+ 1 - 0
Assembly-CSharp/DanceSelect.cs

@@ -138,6 +138,7 @@ public class DanceSelect : WfScreenChildren
 							danceData.InitialPlayable = csvParser.IsCellToExistData(num++, j);
 							danceData.IsPlayable = danceData.InitialPlayable;
 							danceData.RhythmGameCorrespond = (csvParser.GetCellAsString(num++, j) == "◯");
+							danceData.SubtitleSheetName = csvParser.GetCellAsString(num++, j);
 							DanceSelect.dance_data_list_.Add(danceData);
 						}
 					}

+ 17 - 2
Assembly-CSharp/DanceSetting.cs

@@ -204,12 +204,18 @@ public class DanceSetting : MonoBehaviour
 			case DanceSetting.SettingType.Undress:
 				flag = this.IsUndressFaceMatch(text3);
 				break;
+			case DanceSetting.SettingType.Subtitle:
+				flag = this.IsSettingOn(text3, DanceSetting.Settings.IsSubtitleOn);
+				break;
 			}
+			IL_1DF:
 			if (flag)
 			{
 				list.value = ((!flag2) ? text3 : text2);
 				break;
 			}
+			continue;
+			goto IL_1DF;
 		}
 	}
 
@@ -523,6 +529,9 @@ public class DanceSetting : MonoBehaviour
 		case DanceSetting.SettingType.Undress:
 			this.SetUndressFace(text2);
 			break;
+		case DanceSetting.SettingType.Subtitle:
+			this.SwitchFlag(text2, ref DanceSetting.Settings.IsSubtitleOn);
+			break;
 		}
 		if (this.m_SettingUIList[UIPopupList.current].Label)
 		{
@@ -589,6 +598,10 @@ public class DanceSetting : MonoBehaviour
 			{
 				flag &= uiinspectorSetting.UseVR;
 			}
+			if (uiinspectorSetting.MyType == DanceSetting.SettingType.Subtitle)
+			{
+				flag = false;
+			}
 			gameObject.SetActive(flag);
 			if (flag)
 			{
@@ -638,7 +651,8 @@ public class DanceSetting : MonoBehaviour
 		new DanceSetting.UIInspectorSetting(DanceSetting.SettingType.JudgeTiming),
 		new DanceSetting.UIInspectorSetting(DanceSetting.SettingType.FpsCam),
 		new DanceSetting.UIInspectorSetting(DanceSetting.SettingType.Cutin),
-		new DanceSetting.UIInspectorSetting(DanceSetting.SettingType.Undress)
+		new DanceSetting.UIInspectorSetting(DanceSetting.SettingType.Undress),
+		new DanceSetting.UIInspectorSetting(DanceSetting.SettingType.Subtitle)
 	};
 
 	private bool m_IsSettingChange;
@@ -682,7 +696,8 @@ public class DanceSetting : MonoBehaviour
 		FpsCam,
 		Cutin,
 		Undress,
-		AllRelease
+		AllRelease,
+		Subtitle
 	}
 
 	[Serializable]

+ 104 - 0
Assembly-CSharp/DanceSubtitleMgr.cs

@@ -0,0 +1,104 @@
+using System;
+using System.Collections.Generic;
+using I2.Loc;
+using UnityEngine;
+
+public class DanceSubtitleMgr : PartsMgrBase
+{
+	protected override void Start()
+	{
+		base.Start();
+		base.IsActive &= (DanceMain.SelectDanceData != null);
+		base.IsActive &= DanceSetting.Settings.IsSubtitleOn;
+		if (!base.IsActive)
+		{
+			base.gameObject.SetActive(false);
+			return;
+		}
+		this.m_SubtitleUI.SetActive(false);
+		string csv_path = RhythmAction_Mgr.Instance.MusicCSV_Path + "dance_subtitle.nei";
+		KasaiUtility.CsvReadY(csv_path, delegate(CsvParser csv, int cy)
+		{
+			int num = 0;
+			DanceSubtitleMgr.SubtitleData subtitleData = new DanceSubtitleMgr.SubtitleData();
+			subtitleData.ID = csv.GetCellAsInteger(num++, cy);
+			subtitleData.StartTime = csv.GetCellAsReal(num++, cy);
+			subtitleData.EndTime = csv.GetCellAsReal(num++, cy);
+			subtitleData.TranslationKey = csv.GetCellAsString(num++, cy);
+			this.m_SubtitleDataList.Add(subtitleData);
+		}, 1, delegate
+		{
+			Debug.Log(csv_path + "が見つからなかったので、ダンスの字幕を非表示にします。");
+			this.gameObject.SetActive(false);
+		});
+	}
+
+	private void DrawSubtitle()
+	{
+		float danceTimer = RhythmAction_Mgr.Instance.DanceTimer;
+		string str = DanceMain.SelectDanceData.SubtitleSheetName + "/";
+		string currentLanguageCode = LocalizationManager.CurrentLanguageCode;
+		foreach (DanceSubtitleMgr.SubtitleData subtitleData in this.m_SubtitleDataList)
+		{
+			if (subtitleData.EndTime <= danceTimer)
+			{
+				if (subtitleData.SubtitleUI)
+				{
+					UnityEngine.Object.DestroyImmediate(subtitleData.SubtitleUI);
+					this.m_SubtitleUIGrid.UpdateChildUI();
+				}
+			}
+			else if (subtitleData.StartTime <= danceTimer && !subtitleData.SubtitleUI)
+			{
+				string term = str + subtitleData.TranslationKey;
+				string translation = LocalizationManager.GetTranslation(term, true, 0, true, false, null, currentLanguageCode);
+				if (!string.IsNullOrEmpty(translation))
+				{
+					subtitleData.SubtitleUI = UnityEngine.Object.Instantiate<GameObject>(this.m_SubtitleUI, this.m_SubtitleUIGrid.transform, false);
+					subtitleData.SubtitleUI.SetActive(true);
+					UILabel component = subtitleData.SubtitleUI.GetComponent<UILabel>();
+					component.text = translation;
+					if (component.width > this.m_NewLineWidthSize)
+					{
+						component.overflowMethod = UILabel.Overflow.ResizeHeight;
+						component.width = this.m_NewLineWidthSize;
+						component.ProcessText();
+					}
+					this.m_SubtitleUIGrid.UpdateChildUI();
+				}
+			}
+		}
+	}
+
+	public override void StartAction()
+	{
+		RhythmAction_Mgr.Instance.StartTimeCroutine(new Action(this.DrawSubtitle), null);
+	}
+
+	private List<DanceSubtitleMgr.SubtitleData> m_SubtitleDataList = new List<DanceSubtitleMgr.SubtitleData>();
+
+	[SerializeField]
+	[Header("使い回し用オブジェクト")]
+	private GameObject m_SubtitleUI;
+
+	[SerializeField]
+	[Header("字幕UIの親")]
+	private DynamicUIGrid m_SubtitleUIGrid;
+
+	[SerializeField]
+	[Header("表示領域の横サイズがこれ以上になったら改行")]
+	private int m_NewLineWidthSize = 930;
+
+	private class SubtitleData
+	{
+		public int ID;
+
+		public float StartTime;
+
+		public float EndTime;
+
+		public string TranslationKey;
+
+		public GameObject SubtitleUI;
+	}
+}

+ 1 - 1
Assembly-CSharp/DeskManager.cs

@@ -143,7 +143,7 @@ internal class DeskManager
 	public static void SerializeSingleSaveData(BinaryWriter binary)
 	{
 		binary.Write("CM3D2_DeskCustomize");
-		binary.Write(1250);
+		binary.Write(1260);
 		binary.Write(DeskManager.item_inst_data_.Count);
 		for (int i = 0; i < DeskManager.item_inst_data_.Count; i++)
 		{

+ 3 - 3
Assembly-CSharp/DynamicBone.cs

@@ -30,7 +30,7 @@ public class DynamicBone : MonoBehaviour
 			return false;
 		};
 		f_bw.Write("CM3D21_PHY");
-		f_bw.Write(1250);
+		f_bw.Write(1260);
 		if (this.m_Root == null)
 		{
 			NDebug.MessageBox("エラー", "×物理ルートボーンが設定されていません。");
@@ -94,7 +94,7 @@ public class DynamicBone : MonoBehaviour
 	public bool SerializeWriteCollider(BinaryWriter f_bw, string f_strFileName)
 	{
 		f_bw.Write("CM3D21_COL");
-		f_bw.Write(1250);
+		f_bw.Write(1260);
 		if (this.m_Colliders == null || this.m_Colliders.Count == 0)
 		{
 			NDebug.MessageBox("エラー", "×物理Collidersは空です。");
@@ -110,7 +110,7 @@ public class DynamicBone : MonoBehaviour
 			else
 			{
 				f_bw.Write(this.m_Colliders[i].TypeName);
-				this.m_Colliders[i].Serialize(f_bw, 1250);
+				this.m_Colliders[i].Serialize(f_bw, 1260);
 			}
 		}
 		this.m_ColliderFileName = f_strFileName;

+ 62 - 0
Assembly-CSharp/DynamicLabelBG.cs

@@ -0,0 +1,62 @@
+using System;
+using UnityEngine;
+
+[ExecuteInEditMode]
+[RequireComponent(typeof(UIWidget))]
+public class DynamicLabelBG : MonoBehaviour
+{
+	private void Start()
+	{
+		this.BGResize();
+	}
+
+	private void Update()
+	{
+		if (!this.m_Label)
+		{
+			return;
+		}
+		if (this.m_MyWidget.pivot != this.m_Label.pivot)
+		{
+			this.m_MyWidget.pivot = this.m_Label.pivot;
+		}
+		this.BGResize();
+	}
+
+	private void BGResize()
+	{
+		if (!this.m_Label)
+		{
+			return;
+		}
+		if (!string.IsNullOrEmpty(this.m_Label.text))
+		{
+			this.m_MyWidget.width = this.m_Label.width + this.m_HorizontalMarjinSize;
+			this.m_MyWidget.height = this.m_Label.height + this.m_VerticalMarjinSize;
+		}
+		else
+		{
+			this.m_MyWidget.width = 0;
+			this.m_MyWidget.height = 0;
+		}
+		Vector3 a = Mathf.Lerp(-1f, 1f, this.m_Label.pivotOffset.x) * Vector3.right * (float)this.m_HorizontalMarjinSize / 2f;
+		Vector3 b = Mathf.Lerp(-1f, 1f, this.m_Label.pivotOffset.y) * Vector3.up * (float)this.m_VerticalMarjinSize / 2f;
+		base.transform.localPosition = a + b;
+	}
+
+	[SerializeField]
+	[Header("縦マージンサイズ")]
+	private int m_VerticalMarjinSize = 14;
+
+	[SerializeField]
+	[Header("横マージンサイズ")]
+	private int m_HorizontalMarjinSize = 67;
+
+	[SerializeField]
+	[Header("実際にサイズを合わせるUIラベル")]
+	private UILabel m_Label;
+
+	[SerializeField]
+	[HideInInspector]
+	private UIWidget m_MyWidget;
+}

+ 1 - 1
Assembly-CSharp/DynamicSkirtBone.cs

@@ -18,7 +18,7 @@ public class DynamicSkirtBone : MonoBehaviour
 	public bool SerializeWrite(BinaryWriter f_bw)
 	{
 		f_bw.Write("CM3D21_PSK");
-		f_bw.Write(1250);
+		f_bw.Write(1260);
 		f_bw.Write(this.m_fPanierRadius);
 		this.SerializeWriteAnimationCurve(f_bw, this.m_PanierRadiusDistrib);
 		int num = (this.m_PanierRadiusDistribGroup == null) ? 0 : this.m_PanierRadiusDistribGroup.Length;

+ 144 - 0
Assembly-CSharp/DynamicUIGrid.cs

@@ -0,0 +1,144 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using UnityEngine;
+
+[ExecuteInEditMode]
+public class DynamicUIGrid : MonoBehaviour
+{
+	private int m_activeChildCount
+	{
+		get
+		{
+			int num = 0;
+			for (int i = 0; i < base.transform.childCount; i++)
+			{
+				Transform child = base.transform.GetChild(i);
+				if (child.gameObject.activeSelf)
+				{
+					num++;
+				}
+			}
+			return num;
+		}
+	}
+
+	private Vector3 sortAxis
+	{
+		get
+		{
+			return DynamicUIGrid.GetSortAxis(this.m_SortType);
+		}
+	}
+
+	private void Update()
+	{
+		this.Reposition();
+	}
+
+	public void UpdateChildUI()
+	{
+		this.m_ChildWidgetPair.Clear();
+		for (int i = 0; i < base.transform.childCount; i++)
+		{
+			Transform child = base.transform.GetChild(i);
+			if (child.gameObject.activeSelf)
+			{
+				UIWidget component = child.GetComponent<UIWidget>();
+				if (component)
+				{
+					this.m_ChildWidgetPair.Add(child, component);
+				}
+			}
+		}
+	}
+
+	public void Reposition()
+	{
+		Vector3 a = Vector3.zero;
+		for (int i = 0; i < this.m_ChildWidgetPair.Count; i++)
+		{
+			Transform transform = this.m_ChildWidgetPair.Keys.ElementAt(i);
+			float num = 0f;
+			float num2 = 0f;
+			if (i != 0)
+			{
+				if (this.m_SortType == DynamicUIGrid.SortAxisType.Up || this.m_SortType == DynamicUIGrid.SortAxisType.Down)
+				{
+					num = (float)this.m_ChildWidgetPair[transform].height;
+					num2 = this.m_VerticalSpace;
+				}
+				else
+				{
+					num = (float)this.m_ChildWidgetPair[transform].width;
+					num2 = this.m_HorizontalSpace;
+				}
+			}
+			transform.localPosition = a + this.sortAxis * (num + num2);
+			a = transform.localPosition;
+		}
+		if (this.m_ChildInverse)
+		{
+			this.ChildPosInverse();
+		}
+	}
+
+	private void ChildPosInverse()
+	{
+		List<Transform> list = this.m_ChildWidgetPair.Keys.ToList<Transform>();
+		int count = list.Count;
+		for (int i = 0; i < list.Count / 2; i++)
+		{
+			Transform transform = list[i];
+			int num = count - (1 + i);
+			if (num >= 0)
+			{
+				Transform transform2 = list[num];
+				Vector3 localPosition = transform.localPosition;
+				transform.localPosition = transform2.localPosition;
+				transform2.localPosition = localPosition;
+			}
+		}
+	}
+
+	public static Vector3 GetSortAxis(DynamicUIGrid.SortAxisType sort_type)
+	{
+		switch (sort_type)
+		{
+		case DynamicUIGrid.SortAxisType.Up:
+			return Vector3.up;
+		case DynamicUIGrid.SortAxisType.Down:
+			return Vector3.down;
+		case DynamicUIGrid.SortAxisType.Left:
+			return Vector3.left;
+		default:
+			return Vector3.right;
+		}
+	}
+
+	[SerializeField]
+	[Header("UIの配置方向")]
+	private DynamicUIGrid.SortAxisType m_SortType;
+
+	[SerializeField]
+	[Header("配置時に空ける横のスペース")]
+	private float m_HorizontalSpace;
+
+	[SerializeField]
+	[Header("配置時に空ける縦のスペース")]
+	private float m_VerticalSpace;
+
+	[SerializeField]
+	[Header("子の位置を反転させるか")]
+	private bool m_ChildInverse;
+
+	private Dictionary<Transform, UIWidget> m_ChildWidgetPair = new Dictionary<Transform, UIWidget>();
+
+	public enum SortAxisType
+	{
+		Up,
+		Down,
+		Left,
+		Right
+	}
+}

+ 1 - 1
Assembly-CSharp/EditMod.cs

@@ -303,7 +303,7 @@ public class EditMod : MonoBehaviour
 		MemoryStream memoryStream = new MemoryStream();
 		BinaryWriter binaryWriter = new BinaryWriter(memoryStream);
 		binaryWriter.Write("CM3D2_MOD");
-		binaryWriter.Write(1250);
+		binaryWriter.Write(1260);
 		binaryWriter.Write(value);
 		binaryWriter.Write(text2.ToLower());
 		binaryWriter.Write(value2);

+ 1 - 1
Assembly-CSharp/EmpireLifeModeManager.cs

@@ -477,7 +477,7 @@ public class EmpireLifeModeManager : MonoBehaviour
 	public bool Serialize(BinaryWriter brWrite)
 	{
 		brWrite.Write("CM3D21_LIFE_MODE_MGR");
-		brWrite.Write(1250);
+		brWrite.Write(1260);
 		brWrite.Write("2");
 		DataArray<int, byte> saveDataScenarioExecuteCountArray = this.m_SaveDataScenarioExecuteCountArray;
 		if (EmpireLifeModeManager.<>f__mg$cache1 == null)

+ 1 - 1
Assembly-CSharp/FacilityManager.cs

@@ -657,7 +657,7 @@ public class FacilityManager : MonoBehaviour
 		Stopwatch stopwatch = new Stopwatch();
 		stopwatch.Start();
 		brWrite.Write("CM3D21_FACILITY_MGR");
-		brWrite.Write(1250);
+		brWrite.Write(1260);
 		brWrite.Write("5");
 		int num = 0;
 		for (int i = 0; i < this.m_FacilityArray.Count; i++)

+ 2 - 2
Assembly-CSharp/GameMain.cs

@@ -679,7 +679,7 @@ public class GameMain : MonoSingleton<GameMain>
 		serializeHeader.nMaidNum = this.m_CharacterMgr.GetStockMaidCount();
 		serializeHeader.strComment = f_strComment;
 		binaryWriter.Write("COM3D2_SAVE");
-		binaryWriter.Write(1250);
+		binaryWriter.Write(1260);
 		this.SerializeWriteHeader(binaryWriter, serializeHeader);
 		binaryWriter.Write("bookmark_kk_01");
 		GameMain.BinaryBookmark binaryBookmark = new GameMain.BinaryBookmark(binaryWriter);
@@ -796,7 +796,7 @@ public class GameMain : MonoSingleton<GameMain>
 		MemoryStream memoryStream = new MemoryStream();
 		BinaryWriter binaryWriter = new BinaryWriter(memoryStream);
 		binaryWriter.Write("COM3D2_SAVE");
-		binaryWriter.Write(1250);
+		binaryWriter.Write(1260);
 		this.SerializeWriteHeader(binaryWriter, saveDataHeader);
 		binaryWriter.Write(array, (int)saveDataHeader.lHeaderSize, (int)((long)array.Length - saveDataHeader.lHeaderSize));
 		File.WriteAllBytes(path, memoryStream.ToArray());

+ 1 - 1
Assembly-CSharp/GameModeManager.cs

@@ -31,7 +31,7 @@ public static class GameModeManager
 	public static bool Serialize(BinaryWriter brWrite)
 	{
 		brWrite.Write("CM3D21_GAME_MODE_MGR");
-		brWrite.Write(1250);
+		brWrite.Write(1260);
 		brWrite.Write(1);
 		brWrite.Write((int)GameModeManager.m_NowGameModeType);
 		return true;

+ 2 - 2
Assembly-CSharp/GameUty.cs

@@ -985,14 +985,14 @@ public class GameUty
 
 	public static string GetBuildVersionText()
 	{
-		int num = 1250;
+		int num = 1260;
 		return (num >= 1000) ? ((float)num / 1000f).ToString("F2") : ((float)num / 100f).ToString("F2");
 	}
 
 	public static string GetGameVersionText()
 	{
 		string text = "COM3D2x64.exe";
-		int num = 1250;
+		int num = 1260;
 		string path = Path.GetFullPath(".\\") + "update.lst";
 		string[] array = new string[0];
 		if (File.Exists(path))

+ 2 - 2
Assembly-CSharp/HandSignShortcut.cs

@@ -494,7 +494,7 @@ public class HandSignShortcut : MonoBehaviour
 	{
 		public void OnBeforeSerialize()
 		{
-			this.m_nVersion = 1250;
+			this.m_nVersion = 1260;
 		}
 
 		public void OnAfterDeserialize()
@@ -803,7 +803,7 @@ public class HandSignShortcut : MonoBehaviour
 		private const string CONF_NAME = "MaidFingerDataList.json";
 
 		[SerializeField]
-		private int m_nVersion = 1250;
+		private int m_nVersion = 1260;
 
 		[SerializeField]
 		private List<HandSignShortcut.MaidFingerData> MaidFingerDataList = new List<HandSignShortcut.MaidFingerData>();

+ 1 - 1
Assembly-CSharp/Kasizuki/KasizukiManager.cs

@@ -808,7 +808,7 @@ namespace Kasizuki
 		public void Serialize(BinaryWriter bw)
 		{
 			bw.Write("COM3D2_KASIZUKI");
-			bw.Write(1250);
+			bw.Write(1260);
 			this.SerializeOriginHeader(bw);
 			foreach (KeyValuePair<int, KasizukiManager.SaveData> keyValuePair in this.m_SaveDataArray)
 			{

+ 8 - 3
Assembly-CSharp/Maid.cs

@@ -1279,7 +1279,7 @@ public class Maid : MonoBehaviour
 	public bool SerializeProp(BinaryWriter f_bwWrite)
 	{
 		f_bwWrite.Write("CM3D2_MPROP_LIST");
-		f_bwWrite.Write(1250);
+		f_bwWrite.Write(1260);
 		f_bwWrite.Write(this.m_dicMaidProp.Count);
 		int num = 0;
 		foreach (KeyValuePair<string, MaidProp> keyValuePair in this.m_dicMaidProp)
@@ -1313,7 +1313,7 @@ public class Maid : MonoBehaviour
 	public bool SerializeMisc(BinaryWriter f_bwWrite)
 	{
 		f_bwWrite.Write("CM3D2_MAID_MISC");
-		f_bwWrite.Write(1250);
+		f_bwWrite.Write(1260);
 		f_bwWrite.Write(this.m_nActiveSlotNo);
 		if (this.m_texIcon != null)
 		{
@@ -1338,7 +1338,7 @@ public class Maid : MonoBehaviour
 	public bool SerializeBody(BinaryWriter f_bwWrite)
 	{
 		f_bwWrite.Write("CM3D2_MAID_BODY");
-		f_bwWrite.Write(1250);
+		f_bwWrite.Write(1260);
 		return true;
 	}
 
@@ -1939,6 +1939,11 @@ public class Maid : MonoBehaviour
 		return this.body0.CrossFadeAbsolute(fn, fileSystem, additive, loop, boAddQue, val, weight);
 	}
 
+	public void CacheAnime(string fn, bool loadMuneL = false, bool loadMuneR = false)
+	{
+		this.body0.CacheLoadAnime(GameUty.FileSystem, Path.ChangeExtension(fn, ".anm"), loadMuneL, loadMuneR);
+	}
+
 	public Animation GetAnimation()
 	{
 		return this.body0.GetAnimation();

+ 1 - 1
Assembly-CSharp/MaidParts.cs

@@ -37,7 +37,7 @@ public class MaidParts : MonoBehaviour
 	public unsafe bool Serialize(BinaryWriter f_bwWrite)
 	{
 		f_bwWrite.Write("CM3D2_MULTI_COL");
-		f_bwWrite.Write(1250);
+		f_bwWrite.Write(1260);
 		f_bwWrite.Write(this.m_aryPartsColor.Length);
 		for (int i = 0; i < this.m_aryPartsColor.Length; i++)
 		{

+ 1 - 1
Assembly-CSharp/MaidProp.cs

@@ -8,7 +8,7 @@ public class MaidProp
 	public bool Serialize(BinaryWriter f_bwWrite)
 	{
 		f_bwWrite.Write("CM3D2_MPROP");
-		f_bwWrite.Write(1250);
+		f_bwWrite.Write(1260);
 		f_bwWrite.Write(this.idx);
 		f_bwWrite.Write(this.name);
 		f_bwWrite.Write(this.type);

+ 1 - 1
Assembly-CSharp/MaidStatus/Status.cs

@@ -1231,7 +1231,7 @@ namespace MaidStatus
 		public void Serialize(BinaryWriter binary)
 		{
 			binary.Write("CM3D2_MAID_STATUS");
-			binary.Write(1250);
+			binary.Write(1260);
 			binary.Write(this.guid);
 			binary.Write(this.creationTime);
 			binary.Write((short)this.heroineType);

+ 1 - 1
Assembly-CSharp/Menu.cs

@@ -907,7 +907,7 @@ public class Menu : MonoBehaviour
 			Directory.CreateDirectory(text);
 		}
 		StreamWriter streamWriter = new StreamWriter(text + "\\" + text2 + ".txt", false, Encoding.UTF8);
-		streamWriter.WriteLine("出力バージョン\t" + 1250);
+		streamWriter.WriteLine("出力バージョン\t" + 1260);
 		streamWriter.WriteLine("基本アイテム\t" + filename.Replace(" ", ":"));
 		try
 		{

+ 1 - 1
Assembly-CSharp/Misc.cs

@@ -2,7 +2,7 @@
 
 public class Misc
 {
-	public const int GAME_VERSION = 1250;
+	public const int GAME_VERSION = 1260;
 
 	public const string GAME_DATA_PATH = "GameData";
 

+ 1 - 1
Assembly-CSharp/ModCompile.cs

@@ -604,7 +604,7 @@ public class ModCompile : MonoBehaviour
 		MemoryStream memoryStream = new MemoryStream();
 		BinaryWriter binaryWriter = new BinaryWriter(memoryStream);
 		binaryWriter.Write("CM3D2_MESH");
-		binaryWriter.Write(1250);
+		binaryWriter.Write(1260);
 		string fileNameWithoutExtension = Path.GetFileNameWithoutExtension(f_strMqoFile);
 		binaryWriter.Write(fileNameWithoutExtension);
 		binaryWriter.Write(exObjIn2.strName);

+ 2 - 2
Assembly-CSharp/OvrIK.cs

@@ -1568,7 +1568,7 @@ public class OvrIK : MonoBehaviour
 	{
 		public void OnBeforeSerialize()
 		{
-			this.m_nVersion = 1250;
+			this.m_nVersion = 1260;
 		}
 
 		public void OnAfterDeserialize()
@@ -1628,7 +1628,7 @@ public class OvrIK : MonoBehaviour
 		private const string CONF_NAME = "OvrIK.json";
 
 		[SerializeField]
-		private int m_nVersion = 1250;
+		private int m_nVersion = 1260;
 
 		[SerializeField]
 		private float solver_locomotion_weight = 1f;

+ 1 - 1
Assembly-CSharp/PhotoModeSaveAndLoad.cs

@@ -450,7 +450,7 @@ public class PhotoModeSaveAndLoad : MonoBehaviour
 	private XElement CreateCommonData(string title, string comment)
 	{
 		string value = DateTime.ParseExact(DateTime.Now.ToString("yyyyMMddHHmmss"), "yyyyMMddHHmmss", null).ToString("yyyy.MM.dd HH:mm");
-		XElement xelement = new XElement("GameVersion", 1250);
+		XElement xelement = new XElement("GameVersion", 1260);
 		XElement xelement2 = new XElement("SaveTime", value);
 		XElement xelement3 = new XElement("Title", title);
 		XElement xelement4 = new XElement("Comment", comment);

+ 1 - 1
Assembly-CSharp/PlayerStatus/Status.cs

@@ -827,7 +827,7 @@ namespace PlayerStatus
 		public void Serialize(BinaryWriter binary)
 		{
 			binary.Write("CM3D2_PLAYER_STATUS");
-			binary.Write(1250);
+			binary.Write(1260);
 			binary.Write(this.playerName_);
 			binary.Write(this.days_);
 			binary.Write(this.totalPurchasePrice_);

+ 28 - 0
Assembly-CSharp/Product_Mgr.cs

@@ -39,6 +39,7 @@ public class Product_Mgr : PartsMgrBase
 			this.m_nAudience = Product_Mgr.AudienceState.Many;
 			this.m_nProduct = Product_Mgr.ProductRank.Special;
 		}
+		this.CheckProductAndAudience();
 		int voltage = this.m_AllAudience.Single((Product_Mgr.Audience e) => e.State == this.m_nAudience).Voltage;
 		foreach (Product_Mgr.Audience audience in this.m_AllAudience)
 		{
@@ -98,6 +99,33 @@ public class Product_Mgr : PartsMgrBase
 		this.ReadTimeData();
 	}
 
+	private void CheckProductAndAudience()
+	{
+		if (this.m_SpecialProduct.Count == 0)
+		{
+			this.m_SpecialProduct.Add(GameObject.Find("LiveStage_Laser_use_dance"));
+			this.m_SpecialProduct.Add(GameObject.Find("MovingLight"));
+			this.m_SpecialProduct.Add(GameObject.Find("SpotLightL"));
+			this.m_SpecialProduct.Add(GameObject.Find("SpotLightL"));
+			this.m_SpecialProduct.Add(GameObject.Find("SpotFloorLight"));
+			if (this.m_SpecialProduct.Contains(null))
+			{
+				this.m_SpecialProduct.Clear();
+				return;
+			}
+		}
+		for (int i = 0; i < this.m_AllAudience.Length; i++)
+		{
+			Product_Mgr.Audience audience = this.m_AllAudience[i];
+			if (audience.AudienceObj.Count == 0)
+			{
+				audience.AudienceObj.Add(GameObject.Find(string.Format("psyllium_A00{0}_alpha", i + 1)));
+				audience.AudienceObj.Add(GameObject.Find(string.Format("psyllium_B00{0}_alpha", i + 1)));
+				audience.AudienceObj.Add(GameObject.Find(string.Format("psyllium_C00{0}_alpha", i + 1)));
+			}
+		}
+	}
+
 	private void CheckSpecialObj(Transform parent)
 	{
 		if (parent.childCount > 0)

+ 29 - 1
Assembly-CSharp/RhythmAction_Mgr.cs

@@ -574,14 +574,29 @@ public class RhythmAction_Mgr : MonoBehaviour
 				ellipsoidParticleEmitter.enabled = !this.m_IsPause;
 			}
 		}
-		foreach (Maid maid in this.DanceMaid)
+		for (int i = 0; i < this.DanceMaid.Count; i++)
 		{
+			Maid maid = this.DanceMaid[i];
 			if (GameMain.Instance.VRMode && GameMain.Instance.CMSystem.GetTmpGenericFlag("ダンスOVRカメラタイプ") == 0)
 			{
+				RhythmAction_Mgr.PauseBackupLookTarget pauseBackupLookTarget2;
 				if (this.m_IsPause)
 				{
+					RhythmAction_Mgr.PauseBackupLookTarget pauseBackupLookTarget = new RhythmAction_Mgr.PauseBackupLookTarget();
+					pauseBackupLookTarget.m_backupHeadToCam = maid.body0.boHeadToCam;
+					pauseBackupLookTarget.m_backupEyeToCam = maid.body0.boEyeToCam;
+					pauseBackupLookTarget.m_backupEyeSorashi = maid.body0.boEyeSorashi;
+					pauseBackupLookTarget.m_backupLookTarget = maid.body0.trsLookTarget;
+					this.m_backupLookTarget[i] = pauseBackupLookTarget;
 					maid.EyeToCamera(Maid.EyeMoveType.無視する, 0f);
 				}
+				else if (this.m_backupLookTarget.TryGetValue(i, out pauseBackupLookTarget2))
+				{
+					maid.body0.boHeadToCam = pauseBackupLookTarget2.m_backupHeadToCam;
+					maid.body0.boEyeToCam = pauseBackupLookTarget2.m_backupEyeToCam;
+					maid.body0.boEyeSorashi = pauseBackupLookTarget2.m_backupEyeSorashi;
+					maid.body0.trsLookTarget = pauseBackupLookTarget2.m_backupLookTarget;
+				}
 				else
 				{
 					maid.EyeToCamera(Maid.EyeMoveType.目だけ向ける, 0f);
@@ -1208,6 +1223,8 @@ public class RhythmAction_Mgr : MonoBehaviour
 
 	private GameObject m_RightPenlight;
 
+	private Dictionary<int, RhythmAction_Mgr.PauseBackupLookTarget> m_backupLookTarget = new Dictionary<int, RhythmAction_Mgr.PauseBackupLookTarget>();
+
 	public enum DanceType
 	{
 		Free,
@@ -1262,4 +1279,15 @@ public class RhythmAction_Mgr : MonoBehaviour
 		[HideInInspector]
 		public UISprite UIImage;
 	}
+
+	private class PauseBackupLookTarget
+	{
+		public bool m_backupHeadToCam;
+
+		public bool m_backupEyeToCam;
+
+		public bool m_backupEyeSorashi;
+
+		public Transform m_backupLookTarget;
+	}
 }

+ 17 - 5
Assembly-CSharp/SceneEdit.cs

@@ -345,15 +345,23 @@ public class SceneEdit : MonoBehaviour
 		this.m_FFNameDlg.Init();
 		childObject6.SetActive(false);
 		Maid maid = this.m_maid;
-		maid.EyeToCamera(Maid.EyeMoveType.目と顔を向ける, 0f);
-		this.m_viewreset.SetVisibleEyeToCam(true);
+		this.m_viewreset.SetVisibleEyeToCam(GameMain.Instance.CMSystem.SConfig.EditEyeToCam);
+		if (GameMain.Instance.CMSystem.SConfig.EditEyeToCam)
+		{
+			maid.EyeToCamera(Maid.EyeMoveType.目と顔を向ける, 0f);
+		}
+		else
+		{
+			maid.EyeToCamera(Maid.EyeMoveType.無視する, 0f);
+		}
 		if (!GameMain.Instance.VRMode)
 		{
-			this.m_viewreset.SetVisibleAutoCam(true);
+			this.m_viewreset.SetVisibleAutoCam(GameMain.Instance.CMSystem.SConfig.EditAutoCam);
 		}
 		else
 		{
 			this.m_viewreset.SetVisibleAutoCam(false);
+			GameMain.Instance.CMSystem.SConfig.EditAutoCam = false;
 		}
 		new List<string>
 		{
@@ -3050,13 +3058,17 @@ public class SceneEdit : MonoBehaviour
 
 	private void OnClickAutoCam()
 	{
-		this.m_viewreset.SetVisibleAutoCam(!this.m_viewreset.GetVisibleAutoCam());
+		bool flag = !this.m_viewreset.GetVisibleAutoCam();
+		this.m_viewreset.SetVisibleAutoCam(flag);
+		GameMain.Instance.CMSystem.SConfig.EditAutoCam = flag;
 	}
 
 	private void OnClickEyeToCam()
 	{
 		Maid maid = this.m_maid;
-		this.m_viewreset.SetVisibleEyeToCam(!this.m_viewreset.GetVisibleEyeToCam());
+		bool flag = !this.m_viewreset.GetVisibleEyeToCam();
+		this.m_viewreset.SetVisibleEyeToCam(flag);
+		GameMain.Instance.CMSystem.SConfig.EditEyeToCam = flag;
 		if (this.m_viewreset.GetVisibleEyeToCam())
 		{
 			maid.EyeToCamera(Maid.EyeMoveType.目と顔を向ける, 0.8f);

+ 1 - 1
Assembly-CSharp/SceneNPCEdit/SaveData.cs

@@ -10,7 +10,7 @@ namespace SceneNPCEdit
 		public static void Serialize(BinaryWriter binary)
 		{
 			binary.Write("CM3D2_NPCEDIT");
-			binary.Write(1250);
+			binary.Write(1260);
 			binary.Write(SaveData.presetData.Count);
 			foreach (KeyValuePair<int, byte[]> keyValuePair in SaveData.presetData)
 			{

+ 1 - 1
Assembly-CSharp/ScriptManager.cs

@@ -3072,7 +3072,7 @@ public class ScriptManager : IDisposable
 	public void Serialize(BinaryWriter binary)
 	{
 		binary.Write("CM3D2_SCRIPT");
-		binary.Write(1250);
+		binary.Write(1260);
 		this.adv_kag_.Serialize(binary);
 	}
 

+ 8 - 0
Assembly-CSharp/ThumShot.cs

@@ -60,7 +60,15 @@ public class ThumShot : MonoBehaviour
 
 	public Texture2D ShotThumPreset(Maid f_maid)
 	{
+		if (f_maid.body0 == null || f_maid.body0.m_Bones == null)
+		{
+			return null;
+		}
 		Transform transform = CMT.SearchObjName(f_maid.body0.m_Bones.transform, "Bip01 HeadNub", true);
+		if (transform == null)
+		{
+			return null;
+		}
 		base.transform.position = transform.TransformPoint(transform.localPosition + new Vector3(0.38f, 1.07f, 0f));
 		base.transform.rotation = transform.rotation * Quaternion.Euler(90f, 0f, 90f);
 		this.m_camMain.fieldOfView = 30f;

+ 1 - 1
Assembly-CSharp/WindowPartsFingerPreset.cs

@@ -182,7 +182,7 @@ public class WindowPartsFingerPreset : MonoBehaviour
 	{
 		WindowPartsFingerBlend.Type blendType = tareget_blend.BlendType;
 		FingerBlend.BaseFinger baseFingerClass = tareget_blend.GetBaseFingerClass(tareget_blend.mgr.select_maid, blendType);
-		XElement xelement = new XElement("GameVersion", 1250);
+		XElement xelement = new XElement("GameVersion", 1260);
 		XElement xelement2 = new XElement("RightData", blendType == WindowPartsFingerBlend.Type.RightArm || blendType == WindowPartsFingerBlend.Type.RightLeg);
 		XElement xelement3 = new XElement("BinaryData", Convert.ToBase64String(baseFingerClass.GetBinary()));
 		XNode[] contents = new XNode[]