internal void AddHeroBasicWeapon(EHero pHero) { HeroBasicWeaponConfig config = brainiacs.ItemManager.GetHeroBasicWeaponConfig(pHero); if (config == null) { Debug.LogError($"Added weapon was null"); return; } PlayerWeaponProjectile weaponProjectile = new PlayerWeaponProjectile(player, config); weapon.AddWeapon(weaponProjectile); }
//TODO: create system to check weapon cathegory internal void AddMapWeapon(EWeaponId pWeapon) { if (pWeapon == EWeaponId.None) { Debug.LogError($"Added weapon was null"); return; } MapWeaponConfig config = brainiacs.ItemManager.GetMapWeaponConfig(pWeapon); if (config == null) { return; } game.PlayerStatusManager.ShowMapItem(player.Stats.MapItemUiPosition.position, config.MapItemInfo); PlayerWeaponProjectile weaponProjectile = new PlayerWeaponProjectile(player, config); weapon.AddWeapon(weaponProjectile); }