Skip to content

Commit 5fea37c

Browse files
committed
Updater to version 1.4.1
1 parent 9932977 commit 5fea37c

File tree

316 files changed

+38836
-874
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

316 files changed

+38836
-874
lines changed

Assets/BossFight_Assets/Scripts/BF_AutoAttacker.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@ private void LockShoot()
177177
/// </summary>
178178
private void ResetTimeZone()
179179
{
180-
float adjustTime = JCS_Utility.JCS_FloatRange(-mAdjustTimeZone, mAdjustTimeZone);
180+
float adjustTime = JCS_Random.Range(-mAdjustTimeZone, mAdjustTimeZone);
181181
mRealTimeZone = mTimeZone + adjustTime;
182182

183183
mShooted = false;

Assets/BossFight_Assets/Scripts/Characters/BF_RainFaller.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ private void DoRainFall()
140140
/// </summary>
141141
private void ResetTimeZone()
142142
{
143-
float adjustTime = JCS_Utility.JCS_FloatRange(-mAdjustTimeZone, mAdjustTimeZone);
143+
float adjustTime = JCS_Random.Range(-mAdjustTimeZone, mAdjustTimeZone);
144144
mRealTimeZone = mTimeZone + adjustTime;
145145

146146
mShooted = false;
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
using System.Collections;
2+
using System.Collections.Generic;
3+
using UnityEngine;
4+
using JCSUnity;
5+
6+
7+
public class BGM_Tester
8+
: MonoBehaviour
9+
{
10+
public AudioClip mBGM_01 = null;
11+
public AudioClip mBGM_02 = null;
12+
13+
private void Update()
14+
{
15+
if (JCS_Input.GetKeyDown(KeyCode.A))
16+
JCS_SoundManager.instance.SwitchBackgroundMusic(mBGM_01, 0.5f, 0.5f);
17+
if (JCS_Input.GetKeyDown(KeyCode.S))
18+
JCS_SoundManager.instance.SwitchBackgroundMusic(mBGM_02, 0.5f, 0.5f);
19+
}
20+
21+
}

Assets/FrameworkTest_Assets/Scripts/BGM_Tester.cs.meta

Lines changed: 12 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Assets/FrameworkTest_Assets/Scripts/ParticleSytem_Test.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ public class ParticleSytem_Test
2727
private JCS_TowardTarget mParticle = null;
2828

2929
[SerializeField]
30-
private JCS_2DParticleSystem mParticleSystem = null;
30+
private JCS_ParticleSystem mParticleSystem = null;
3131

3232
private JCS_Vector<JCS_Particle> mParticles = null;
3333

@@ -52,14 +52,14 @@ private void Update()
5252
{
5353
if (JCS_Input.GetKeyDown(KeyCode.G))
5454
{
55-
JCS_Tweener masterTweener = mParticle.GetComponent<JCS_Tweener>();
55+
JCS_TransfromTweener masterTweener = mParticle.GetComponent<JCS_TransfromTweener>();
5656
JCS_TowardTarget masterTt = mParticle.GetComponent<JCS_TowardTarget>();
5757

5858
for (int index = 0;
5959
index < mParticles.length;
6060
++index)
6161
{
62-
JCS_Tweener tweener = mParticles.at(index).GetComponent<JCS_Tweener>();
62+
JCS_TransfromTweener tweener = mParticles.at(index).GetComponent<JCS_TransfromTweener>();
6363

6464
tweener.EasingX = masterTweener.EasingX;
6565
tweener.EasingY = masterTweener.EasingY;

Assets/JCSUnity/Editors/JCSUnity_About.cs

Lines changed: 28 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,10 @@
99
*/
1010
using UnityEngine;
1111
using System.Collections;
12+
using System.Collections.Generic;
1213
using UnityEditor;
14+
using UnityEngine.UI;
15+
using System;
1316

1417

1518
namespace JCSUnity
@@ -25,8 +28,14 @@ public class JCSUnity_About
2528
//----------------------
2629
// Public Variables
2730

31+
/* all the .ini file located here. */
32+
public static Dictionary<string, string> EDITOR_INI = new Dictionary<string, string>();
33+
2834
//----------------------
2935
// Private Variables
36+
private static string INI_FILE_PATH = Application.dataPath + "/JCSUnity/Editors/ini/";
37+
private static string EDITOR_PROPERTIES_FILENAME = "editor.properties";
38+
3039
private static int WINDOW_WIDTH = 400;
3140
private static int WINDOW_HEIGHT = 200;
3241

@@ -42,17 +51,19 @@ public class JCSUnity_About
4251
//------------------------------
4352
private void OnGUI()
4453
{
54+
ReadINIFile();
55+
4556
GUILayout.Label("About JCSUnity", EditorStyles.boldLabel);
4657

4758
// TODO(jenchieh): info should be out source.
48-
GUILayout.Label("Author: Jen-Chieh Shen");
49-
GUILayout.Label("Email: [email protected]");
50-
GUILayout.Label("Current Version: 1.3.9");
59+
GUILayout.Label("Author: " + EDITOR_INI["author"]);
60+
GUILayout.Label("Email: " + EDITOR_INI["email"]);
61+
GUILayout.Label("Current Version: " + EDITOR_INI["version"]);
5162

5263
// GUI.Button that is drawn in the Label style.
53-
if (GUILayout.Button("Source: https://github.com/jcs090218/JCSUnity_Framework", "Label"))
64+
if (GUILayout.Button("Source: " + EDITOR_INI["url"], "Label"))
5465
{
55-
string url = "https://github.com/jcs090218/JCSUnity_Framework";
66+
string url = EDITOR_INI["url"];
5667
Application.OpenURL(url);
5768
}
5869
}
@@ -63,6 +74,17 @@ private void OnGUI()
6374
//----------------------
6475
// Public Functions
6576

77+
/// <summary>
78+
/// Read the .ini/.properties file for this editor window.
79+
/// </summary>
80+
public static void ReadINIFile()
81+
{
82+
//string path = Application.dataPath + "/../editor.properties";
83+
string path = INI_FILE_PATH + EDITOR_PROPERTIES_FILENAME;
84+
85+
EDITOR_INI = JCS_INIFileReader.ReadINIFile(path);
86+
}
87+
6688
//----------------------
6789
// Protected Functions
6890

@@ -80,6 +102,7 @@ private static void AboutJCSUnity()
80102
window.maxSize = new Vector2(WINDOW_WIDTH, WINDOW_HEIGHT);
81103
window.Show();
82104
}
105+
83106
}
84107
}
85108

Assets/JCSUnity/Editors/JCSUnity_EditorWindow.cs

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,10 @@
99
*/
1010
using UnityEngine;
1111
using System.Collections;
12+
using System.Collections.Generic;
1213
using UnityEditor;
1314
using UnityEngine.UI;
15+
using System;
1416

1517

1618
namespace JCSUnity
@@ -28,9 +30,6 @@ public class JCSUnity_EditorWindow
2830

2931
//----------------------
3032
// Private Variables
31-
private static string EDITOR_TITLE = "JCSUnity";
32-
33-
3433
private bool mOCSFoldeout = false; // OCS = One click serialize
3534
private bool mBOFoldout = false; // BO = Bases Object
3635
private bool mGUIFoldout = false;
@@ -52,6 +51,8 @@ public class JCSUnity_EditorWindow
5251
//------------------------------
5352
private void OnGUI()
5453
{
54+
JCSUnity_About.ReadINIFile();
55+
5556
GUILayout.Label("** Editor Settings **", EditorStyles.boldLabel);
5657

5758
mOCSFoldeout = EditorGUILayout.Foldout(mOCSFoldeout, "One click serialize");
@@ -173,7 +174,7 @@ private void PartARVR()
173174
private static void JCSUnityEditor()
174175
{
175176
JCSUnity_EditorWindow window = (JCSUnity_EditorWindow)GetWindow(typeof(JCSUnity_EditorWindow));
176-
window.titleContent = new GUIContent(EDITOR_TITLE);
177+
window.titleContent = new GUIContent(JCSUnity_About.EDITOR_INI["editor_title"]);
177178
window.Show();
178179
}
179180

@@ -380,10 +381,13 @@ private static void CreateSlidePanel()
380381
slidePanelNewPos.y = starting_pos_y - (starting_pos_y * row);
381382
slidePanel.localPosition = slidePanelNewPos;
382383

384+
// set scale to one.
385+
slidePanel.localScale = Vector3.one;
386+
383387
Image panelImage = slidePanel.GetComponent<Image>();
384388
if (panelImage != null)
385389
{
386-
panelImage.color = JCS_Utility.JCS_RandomColor();
390+
panelImage.color = JCS_Random.RandomColor();
387391
}
388392

389393
// assign to slide panel holder.
@@ -420,6 +424,9 @@ private static void Create2DCamera()
420424
string camera_path = "JCSUnity_Resources/JCS_Camera/JCS_2DCamera";
421425
GameObject gameObj = JCS_Utility.SpawnGameObject(camera_path);
422426
gameObj.name = gameObj.name.Replace("(Clone)", "");
427+
428+
// set camera depth to default -10.
429+
gameObj.transform.position = new Vector3(0, 0, -10);
423430
}
424431

425432
/// <summary>

Assets/JCSUnity/Editors/ini.meta

Lines changed: 9 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
#
2+
# JCSUnity editor properties.
3+
#
4+
editor_title=JCSUnity
5+
version=1.4.1
6+
7+
author=Jen-Chieh Shen
8+
url=https://github.com/jcs090218/JCSUnity_Framework

Assets/JCSUnity/Editors/ini/editor.properties.meta

Lines changed: 8 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)