Merge branch 'develop' into feature/elseplayer

# Conflicts:
#	Assets/NetworkLib/Debug/netstandard2.1/CSNetwork.dll
#	Assets/PerfectWorld/Scripts/Network/EC_ManMessageMono.cs
#	Assets/Scripts/CECHostPlayer.cs
#	Assets/Scripts/GameController.cs
This commit is contained in:
Tungdv
2025-09-13 16:36:09 +07:00
46 changed files with 38537 additions and 323 deletions
@@ -16,6 +16,7 @@ namespace PerfectWorld.Scripts.Managers
{
namespace BrewMonster.Managers
{
[Serializable]
public class EC_ManPlayer : IMsgHandler
{
Dictionary<int, int> m_UkPlayerTab = new Dictionary<int, int>();
@@ -24,9 +25,11 @@ namespace PerfectWorld.Scripts.Managers
public int HandlerId => (int)MANAGER_INDEX.MAN_PLAYER;
public bool ProcessMessage(ECMSG Msg)
{
Debug.LogWarning("HoangDev : EC_ManPlayerProcessMessage");
if (Msg.iSubID == 0)
{
Debug.LogWarning("HoangDev : EC_ManPlayerEC_ManPlayerEC_ManPlayer");
GameController.Instance.GetHostPlayer().ProcessMessage(Msg);
}
else if (Msg.iSubID < 0)
{
@@ -58,6 +61,7 @@ namespace PerfectWorld.Scripts.Managers
public void OnMsgPlayerInfo(ECMSG Msg)
{
Debug.LogWarning("OnMsgPlayerInfo ");
int iHostID = Convert.ToInt32(Msg.dwParam3);
int lenghtByte = Marshal.SizeOf<int>();
byte[] byteArray = new byte[lenghtByte];
@@ -110,6 +114,7 @@ namespace PerfectWorld.Scripts.Managers
{
bool isDoneWorldRender = false;
bool isDoneNPCRender = false;
Debug.Log("HostPlayerInfo1HostPlayerInfo1");
Action actLoadChar = () =>
{
if(!isDoneNPCRender || !isDoneWorldRender)
@@ -119,13 +124,18 @@ namespace PerfectWorld.Scripts.Managers
GameController.Instance.InitCharacter(info);
};
string nameScene = "NPCRender";
UnityGameSession.Instance.LoadScene(nameScene, LoadSceneMode.Single, (value) =>
/* UnityGameSession.Instance.LoadScene(nameScene, LoadSceneMode.Single, (value) =>
{
isDoneNPCRender = value;
actLoadChar?.Invoke();
});
nameScene = "WorldRender";
UnityGameSession.Instance.LoadScene(nameScene, LoadSceneMode.Additive, (value) =>
UnityGameSession.Instance.LoadScene(nameScene, LoadSceneMode.Additive, (value) =>
{
isDoneWorldRender = value;
actLoadChar?.Invoke();
});*/
UnityGameSession.Instance.LoadScene("HoangTest", LoadSceneMode.Single, (value) =>
{
isDoneWorldRender = value;
actLoadChar?.Invoke();