|
@@ -688,31 +688,40 @@ namespace CM3D2.MultipleMaids.Plugin
|
|
|
subcamera.cullingMask = 256;
|
|
|
subcamera.depth = 1f;
|
|
|
subcamera.transform.parent = mainCamera.transform;
|
|
|
- float num2 = 2f;
|
|
|
- if (Application.unityVersion.StartsWith("4"))
|
|
|
- {
|
|
|
- num2 = 1f;
|
|
|
- }
|
|
|
-
|
|
|
- GameObject gameObject3 = new GameObject("Light");
|
|
|
- gameObject3.AddComponent<Light>();
|
|
|
- lightList.Add(gameObject3);
|
|
|
- lightColorR.Add(1f);
|
|
|
- lightColorG.Add(1f);
|
|
|
- lightColorB.Add(1f);
|
|
|
- lightIndex.Add(0);
|
|
|
- lightX.Add(40f);
|
|
|
- lightY.Add(180f);
|
|
|
- lightAkarusa.Add(num2);
|
|
|
- lightKage.Add(0.098f);
|
|
|
- lightRange.Add(50f);
|
|
|
- gameObject3.transform.position = GameMain.Instance.MainLight.transform.position;
|
|
|
- gameObject3.GetComponent<Light>().intensity = num2;
|
|
|
- gameObject3.GetComponent<Light>().spotAngle = 50f;
|
|
|
- gameObject3.GetComponent<Light>().range = 10f;
|
|
|
- gameObject3.GetComponent<Light>().type = LightType.Directional;
|
|
|
- gameObject3.GetComponent<Light>().color = new Color(0.5f, 1f, 0f);
|
|
|
- gameObject3.GetComponent<Light>().cullingMask = 256;
|
|
|
+
|
|
|
+ if (lightList.Count == 0)
|
|
|
+ {
|
|
|
+ float num2 = 2f;
|
|
|
+ if (Application.unityVersion.StartsWith("4"))
|
|
|
+ {
|
|
|
+ num2 = 1f;
|
|
|
+ }
|
|
|
+
|
|
|
+ GameObject gameObject3 = new GameObject("Light");
|
|
|
+ gameObject3.AddComponent<Light>();
|
|
|
+ lightList.Add(gameObject3);
|
|
|
+ lightColorR.Add(1f);
|
|
|
+ lightColorG.Add(1f);
|
|
|
+ lightColorB.Add(1f);
|
|
|
+ lightIndex.Add(0);
|
|
|
+ lightX.Add(40f);
|
|
|
+ lightY.Add(180f);
|
|
|
+ lightAkarusa.Add(num2);
|
|
|
+ lightKage.Add(0.098f);
|
|
|
+ lightRange.Add(50f);
|
|
|
+ gameObject3.transform.position = GameMain.Instance.MainLight.transform.position;
|
|
|
+ gameObject3.GetComponent<Light>().intensity = num2;
|
|
|
+ gameObject3.GetComponent<Light>().spotAngle = 50f;
|
|
|
+ gameObject3.GetComponent<Light>().range = 10f;
|
|
|
+ gameObject3.GetComponent<Light>().type = LightType.Directional;
|
|
|
+ gameObject3.GetComponent<Light>().color = new Color(0.5f, 1f, 0f);
|
|
|
+ gameObject3.GetComponent<Light>().cullingMask = 256;
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
if (getModKeyPressing(modKey.Shift) && !getModKeyPressing(modKey.Ctrl) && !getModKeyPressing(modKey.Alt)
|