public void RegisterWeapon(WeaponValue weaponSlot) { UnregisterWeapon(); PlayerCurrentWeapon = weaponSlot; weaponSlot.OnBeforeValueSet += DetachEventsFromOldWeapon; weaponSlot.OnValueSet += PrepareViewForNewWeapon; RefreshView(weaponSlot.Value); AttachEvents(); }
public void RegisterWeapon(WeaponValue weapon) { WeaponPanel.RegisterWeapon(weapon); }
private void ChooseDefaultWeapon() { ActiveWeaponIndex = 0; ActiveWeapon = new WeaponValue(Weapons[ActiveWeaponIndex]); ActiveWeapon.Value.WeaponLevel.AddValue(1); }