public override void Init(iGameMaster nMaster, string nteam, int level) { base.Init(nMaster, nteam, level); float sinAnsw = 0; if (sinIterator % 2 == 0) { sinAnsw = Mathf.Abs(Mathf.Sin(level * Mathf.Deg2Rad)); } else { sinAnsw = Mathf.Abs(Mathf.Cos(level * Mathf.Deg2Rad)); } if (sinAnsw > 0) { myBodyDamage += (sinIterator + sinAnsw) * myBodyBaseDamage; //charStats.CountDamageForGun(fireDamage, new WarriorStats(1)); } else { sinIterator += 1; } int tmp = Random.Range(0, 100); if (tmp < 50 && lookingRight) { ChangeOrientation(); } currentArmor = armorOverride; currentHealth = healthOverride; }
public override void Init(iGameMaster nMaster, string nteam, int level) { base.Init(nMaster, nteam, level); currentHealth = overrideHealth; beatSource = GetComponent <AudioSource>(); myDJ = myDJObject.GetComponent <PlayerDJ>(); myDJ.InitBaseObject(master, master.GetSoundMasterVolume(), master.GetMusicVolume(), master.GetSoundFXVolume()); }
public override void Init(iGameMaster nMaster, string nteam) { activeItems = new ActiveItem[activeItemsMaxCount]; InitSelectedSkill(); availableAmmo = new Dictionary <AmmoType, int>(); DeserializeListsIntoDictionary(); base.Init(nMaster, nteam); if (triggeringObjects == null) { triggeringObjects = new Dictionary <int, iInteractiveObject>(); } else { triggeringObjects.Clear(); } appliedPowerups = new List <iPowerUp>(); if (Tools.IsDebugging()) { moneyCount = 1000; } SetInputActions(); UpdateAmmoIcon(); UpdateItemsIcon(ItemType.Empty, 0, 0); UpdateItemsIcon(ItemType.Empty, 1, 0); UpdateItemsIcon(ItemType.Empty, 2, 0); UpdateItemsIcon(ItemType.Empty, 3, 0); myDJ = GetComponent <PlayerDJ>(); UpdateHealthText(); UpdateMoneyText(); UpdateAmmoIcon(); UpdateAmmoText(); UpdateArmorText(); UpdateGunIcon(); master.UpdateSkillCooldownIcon(0, 0, 1); for (int i = 0; i < 4; i++) { activeItems[i] = new ActiveItem(); activeItems[i].count = 0; activeItems[i].itemType = ItemType.Empty; UpdateItemsCount(i, activeItems[i].count); UpdateItemsIcon(activeItems[i].itemType, i, activeItems[i].count); } if (currentRifleObject != null) { master.UpdateAlternateFireIcon(currentRifleObject.GetComponent <iGun>().GetGunType()); } }
public override void Init(iGameMaster myMaster) { base.Init(myMaster); gameText = master.GetGameText(); }
public void Init(iGameMaster nMaster, string nteam, int level, bool willLookRight) { Init(nMaster, nteam, level); lookingRight = willLookRight; }