Пример #1
0
 private void Start()
 {
     characterController = GetComponent<CharacterController>();
     movementSystem = GetComponent<PlayerInputSystem>();
     healthSystem = GetComponent<HealthSystem>();
     healthSystem.OnDied += HealthSystem_OnDied;
     weaponSystem = GetComponent<WeaponSystem>();
     weapon = GetComponent<BaseWeapon>();
     weaponModifier.SetTarget(weapon);
     weaponSystem.EquipWeapon(weapon);
     collisionSystem = GetComponent<CharacterCollisionSystem>();
     collisionSystem.OnBulletCollisionEnter.AddListener(OnBulletCollision);
 }
Пример #2
0
 public void EquipWeapon(BaseWeapon.BaseWeaponModifier modifier)
 {
     modifier.SetTarget(weapon);
     weaponSystem.EquipWeapon(weapon);
 }
Пример #3
0
 public void EquipWeapon(BaseWeapon.BaseWeaponModifier weapon)
 {
     weapon.SetTarget(baseWeapon);
     scaledWeapon = baseWeapon.Clone().Scale(difficulty);
     weaponSystem.EquipWeapon(scaledWeapon);
 }