toon link on crack
toon link on crack
CC#
Created by toon link on crack on 10/18/2024 in #help
The Given key was not present in the dictionary
ive revived a nostalgic old mobile game and ive converted the offline dead servers from smart fox to photon and everything seems to work but one mode in the game doesnt work at all here is a code snippet public void BirthPlayer(PhotonPlayer player) { if (!SFS_Player_Arr.ContainsKey(player)) { Multiplayer multiplayer = new Multiplayer(player.ID); multiplayer.InitAvatar((AvatarType)player.customProperties["avatarType"], (uint)(int)player.customProperties["birthPoint"]); multiplayer.InitWeaponList((int)player.customProperties["weapon1"], (int)player.customProperties["weapon2"], (int)player.customProperties["weapon3"]); SFS_Player_Arr.Add(player, multiplayer); multiplayer.nick_name = (string)player.customProperties["nickname"]; multiplayer.Init(); multiplayer.ChangeWeaponWithindex((int)player.customProperties["weaponNum"]); } } public void InitializePlayer(PhotonPlayer player) { // Check if the player is already added, if not, add them BirthPlayer(player); }
public void OnPlayerJoin(PhotonPlayer newPlayer) { InitializePlayer(newPlayer); } public override void DoLogic(float deltaTime) { if (!is_game_excute) { return; } player.DoLogic(deltaTime); if (!is_game_over && PhotonNetwork.isMasterClient) { object[] array = new object[enemyList.Count]; enemyList.Keys.CopyTo(array, 0); for (int i = 0; i < array.Length; i++) { Enemy enemy = enemyList[array[i]] as Enemy; enemy.DoLogic(deltaTime);
9 replies
CC#
Created by toon link on crack on 6/10/2023 in #help
✅ im new and i dont get this
37 replies