Skip to content

Commit 1f099e7

Browse files
committed
hf pm
2 parents 24b4c0a + acd11d8 commit 1f099e7

26 files changed

+868
-575
lines changed

Assembly-CSharp-Editor.csproj

Lines changed: 210 additions & 210 deletions
Large diffs are not rendered by default.

Assembly-CSharp.csproj

Lines changed: 193 additions & 188 deletions
Large diffs are not rendered by default.

Assets/Game/HotFix/HotFix.dll.bytes

1 KB
Binary file not shown.

Assets/Game/HotFix/HotFix.pdb.bytes

6 KB
Binary file not shown.

Assets/Game/Scripts/Base/GameMode.cs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ public class GameMode : MonoBehaviour
2727
public static SettingManager Setting;
2828
public static SystemManager System;
2929
public static NetworkManager Network;
30+
public static PoolManager Pool;
3031

3132
public static HotFixManager HotFix;
3233

@@ -78,13 +79,12 @@ IEnumerator Start()
7879
Setting = GameFrameworkMode.GetModule<SettingManager>();
7980
System= GameFrameworkMode.GetModule<SystemManager>();
8081
Network= GameFrameworkMode.GetModule<NetworkManager>();
81-
8282
HotFix = GameFrameworkMode.GetModule<HotFixManager>();
83-
84-
#endregion
83+
Pool = GameFrameworkMode.GetModule<PoolManager>();
84+
#endregion
8585

86-
#region resource
87-
Resource.ResUpdateType = ResUpdateType;
86+
#region resource
87+
Resource.ResUpdateType = ResUpdateType;
8888
Resource.ResUpdatePath = ResUpdatePath;
8989
Resource.LocalPathType = LocalPathType;
9090

Assets/Game/Scripts/Editor/GameModeEditor.cs

Lines changed: 1 addition & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -380,52 +380,7 @@ void DrawNodeDataGUI()
380380
return;
381381

382382
GUILayout.BeginVertical("HelpBox");
383-
//int
384-
// if (VrCoreEntity.Node.IntNodes.Count > 0)
385-
{
386-
GUILayout.Label("Int Node", EditorStyles.boldLabel);
387-
foreach (var item in GameMode.Node.IntNodes)
388-
{
389-
GUILayout.Label(item.Key + ":" + item.Value);
390-
}
391-
}
392-
//float
393-
// if (VrCoreEntity.Node.FloatNodes.Count > 0)
394-
{
395-
GUILayout.Label("Float Node", EditorStyles.boldLabel);
396-
foreach (var item in GameMode.Node.FloatNodes)
397-
{
398-
GUILayout.Label(item.Key + ":" + item.Value);
399-
}
400-
}
401-
//bool
402-
// if (VrCoreEntity.Node.BoolNodes.Count > 0)
403-
{
404-
GUILayout.Label("Bool Node", EditorStyles.boldLabel);
405-
foreach (var item in GameMode.Node.BoolNodes)
406-
{
407-
GUILayout.Label(item.Key + ":" + item.Value);
408-
}
409-
}
410-
//string
411-
// if (VrCoreEntity.Node.StringNodes.Count > 0)
412-
{
413-
GUILayout.Label("String Node", EditorStyles.boldLabel);
414-
foreach (var item in GameMode.Node.StringNodes)
415-
{
416-
GUILayout.Label(item.Key + ":" + item.Value);
417-
}
418-
}
419-
//object
420-
//if (VrCoreEntity.Node.ObjectNodes.Count > 0)
421-
{
422-
GUILayout.Label("Float Node", EditorStyles.boldLabel);
423-
foreach (var item in GameMode.Node.ObjectNodes)
424-
{
425-
GUILayout.Label(item.Key + ":" + item.Value);
426-
}
427-
}
428-
383+
429384
GUILayout.EndVertical();
430385
}
431386

Assets/GameFramework/Node/NodeData.cs

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
//-----------------------------------------------------------------------
2+
// <copyright>
3+
// Copyright (c) 2018 Zhang Yang. All rights reserved.
4+
// </copyright>$
5+
// <describe> #数据节点# </describe>
6+
// <email> [email protected] </email>
7+
// <time> #2018年8月26日 17点35# </time>
8+
//-----------------------------------------------------------------------
9+
using System;
10+
using System.Collections.Generic;
11+
12+
namespace GameFramework.Taurus
13+
{
14+
public class NodeData<T>:NodeDataBase
15+
{
16+
private readonly Dictionary<string, T> _nodeDatas = new Dictionary<string, T>();
17+
18+
public T Get(string key,T defaultValue = default(T))
19+
{
20+
T t;
21+
if (!_nodeDatas.TryGetValue(key, out t))
22+
t = defaultValue;
23+
return t;
24+
}
25+
26+
public void Set(string key,T value)
27+
{
28+
_nodeDatas[key] = value;
29+
}
30+
31+
public bool Has(string key)
32+
{
33+
return _nodeDatas.ContainsKey(key);
34+
}
35+
36+
public void Remove(string key)
37+
{
38+
if (_nodeDatas.ContainsKey(key))
39+
_nodeDatas.Remove(key);
40+
}
41+
42+
public override void Clear()
43+
{
44+
_nodeDatas.Clear();
45+
}
46+
}
47+
}

Assets/GameFramework/Node/NodeData.cs.meta

Lines changed: 11 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
//-----------------------------------------------------------------------
2+
// <copyright>
3+
// Copyright (c) 2018 Zhang Yang. All rights reserved.
4+
// </copyright>$
5+
// <describe> #数据节点的基类# </describe>
6+
// <email> [email protected] </email>
7+
// <time> #2018年8月26日 17点34# </time>
8+
//-----------------------------------------------------------------------
9+
10+
namespace GameFramework.Taurus
11+
{
12+
public abstract class NodeDataBase
13+
{
14+
public abstract void Clear();
15+
}
16+
}

Assets/GameFramework/Node/NodeDataBase.cs.meta

Lines changed: 11 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)