private void InitialWeapon(ref GameObject go, int player, int serial, bool b) { Transform t = (b) ? m_PrimaryWeapon.transform : m_SecondaryWeapon.transform; go = Instantiate(m_WeaponUI, t) as GameObject; LobbyUI_Weapon uI = go.GetComponent <LobbyUI_Weapon>(); int id = PlayerManager.Instance.Players[player].info.Weapons[serial]; uI.SetWeaponUI(id); if (b) { PriWeaponID = uI.ID; } else { SecWeaponID = uI.ID; } }
private void GetCurrentID(LobbyUI_Weapon uI_Weapon) { m_iType = uI_Weapon.Type; m_iCurrentID = uI_Weapon.ID; }