private void Start() { isChange = false; redAura.SetActive(false); blueAura.SetActive(false); greenAura.SetActive(false); redAura2.SetActive(false); blueAura2.SetActive(false); greenAura2.SetActive(false); redAura3.SetActive(false); blueAura3.SetActive(false); greenAura3.SetActive(false); redAura4.SetActive(false); blueAura4.SetActive(false); greenAura4.SetActive(false); _level = 1; _exp = 0; _defense = 5; _moveSpeed = 5.0f; _gold = 0; loseCondition = FindObjectOfType <LoseCondition>(); SetStat(_level); }
public override void ResetValues() { base.ResetValues(); sizeX = 0; sizeY = 0; mapSprite = null; mapDescription = ""; winCondition = WinCondition.ROUT; loseCondition = LoseCondition.NONE; turnLimit = 0; skipBattlePrep = false; preDialogue = null; introDialogue = null; endDialogue = null; mapMusic = null; spawnPoints1 = new List <Position>(); spawnPoints2 = new List <Position>(); forcedCharacters = new List <CharEntry>(); lockedCharacters = new List <CharEntry>(); enemies = new List <SpawnData>(); allies = new List <SpawnData>(); reinforcements = new List <SpawnData>(); interactions = new List <InteractPosition>(); triggerIds = new List <TriggerTuple>(); triggerAreas = new List <TriggerArea>(); turnEvents = new List <TurnEvent>(); }
// Use this for initialization void Start() { // Get defeat type from GameManager LoseCondition loseCondition = GameManager.Instance.loseCondition; // TODO depending the defeat type, assign the attributes (or remove them and the function) Sprite defeatSprite = null; string defeatDescription = null; if (loseCondition == LoseCondition.REVOLUTION) { defeatSprite = Resources.Load <Sprite>("revolution"); defeatDescription = "Le peuple en a assez d'être exploité, il se révolte !"; } else if (loseCondition == LoseCondition.BANKRUPT) { defeatSprite = Resources.Load <Sprite>("bankrupt"); defeatDescription = "Vous avez perdu votre fortune ! A quoi bon gouverner ?"; } else if (loseCondition == LoseCondition.JAIL) { defeatSprite = Resources.Load <Sprite>("prison"); defeatDescription = "Vos pairs en ont eu assez de vos opinions progressistes. Ils vous ont fait arrêter !"; } else // loseCondition == LoseCondition.NONE { defeatSprite = Resources.Load <Sprite>("revolution2"); defeatDescription = "Quelque chose s'est mal passé ..."; } this.loadDefeatScene(defeatSprite, defeatDescription); }
public void Lose(LoseCondition lc) { switch (lc) { case LoseCondition.NoWayToGo: Debug.Log("此处,就是落凤坡吗"); break; } }
public void LoseLevel(LoseCondition loseCondition) { if (gameState == GameState.LostLevelAndAwaitingReload) { return; // we're allready in a lose loop } UI.Instance.showLostMessage(loseCondition); gameState = GameState.LostLevelAndAwaitingReload; // show death msg StartCoroutine(WaitAndReloadLevel()); }
//コンストラクタ public Stage(Chapter chapter, bool isUnitSelectRequired, int entryUnitCount, List <Coordinate> entryUnitCoordinates, List <Enemy> enemyList, WinCondition winCondition, LoseCondition loseCondition, string storyText, bool isReimuRoute, List <TreasureBox> treasureList) { this.chapter = chapter; this.isUnitSelectRequired = isUnitSelectRequired; this.entryUnitCount = entryUnitCount; this.entryUnitCoordinates = entryUnitCoordinates; this.winCondition = winCondition; this.loseCondition = loseCondition; this.storyText = storyText; this.isReimuRoute = isReimuRoute; this.enemyList = enemyList; this.treasureList = treasureList; }
public void showLostMessage(LoseCondition loseCondition) { switch (loseCondition) { case LoseCondition.FellInHole: MirrorTextWriter.TypeText("You fell into a hole", 0); break; case LoseCondition.HitWall: MirrorTextWriter.TypeText("7 years of bad luck", 0); break; } // todo sound // todo animate mirror portrait }
public void Show(LoseCondition loseCondition) { image.sprite = loseCondition switch { LoseCondition.Bankrupcy => bankruptSprite, LoseCondition.Destruction => destructionSprite, _ => image.sprite }; RectTransform imageRect = (RectTransform)image.transform; Vector3 correctPosition = imageRect.anchoredPosition; imageRect.anchoredPosition = Vector3.zero; imageRect.DOAnchorPos(correctPosition, signEnterDuration).SetEase(Ease.OutBounce); gameObject.SetActive(true); }
public BettingSystem(double initialStake, double budget, StakingTypeOnLose stakingTypeOnLose, StakingTypeOnWin stakingTypeOnWin, List <BetToDisplayGvVM> bets, List <DataFilter> filters, double budgetIncreaseReference, double stakeIncrease, double budgetDecreaseReference, double stakeDecrease, double loseCoefficient, double winCoefficient, LoseCondition loseCondition, double maxStake, bool resetStake) { InitialStake = initialStake; Budget = budget; StakingTypeOnLose = stakingTypeOnLose; StakingTypeOnWin = stakingTypeOnWin; InitialBets = bets; FilteredBets = new List <BetToDisplayGvVM>(); Filters = filters; BudgetIncreaseReference = budgetIncreaseReference; StakeIncrease = stakeIncrease; BudgetDecreaseReference = budgetDecreaseReference; StakeDecrease = stakeDecrease; LoseCoefficient = loseCoefficient; WinCoefficient = winCoefficient; LoseCondition = loseCondition; MaxStake = maxStake; ResetStake = resetStake; }
public override void CopyValues(ScrObjLibraryEntry other) { base.CopyValues(other); MapEntry map = (MapEntry)other; sizeX = map.sizeX; sizeY = map.sizeY; mapSprite = map.mapSprite; mapDescription = map.mapDescription; winCondition = map.winCondition; loseCondition = map.loseCondition; turnLimit = map.turnLimit; skipBattlePrep = map.skipBattlePrep; preDialogue = map.preDialogue; introDialogue = map.introDialogue; endDialogue = map.endDialogue; mapMusic = map.mapMusic; spawnPoints1 = new List <Position>(); for (int i = 0; i < map.spawnPoints1.Count; i++) { spawnPoints1.Add(map.spawnPoints1[i]); } spawnPoints2 = new List <Position>(); for (int i = 0; i < map.spawnPoints2.Count; i++) { spawnPoints2.Add(map.spawnPoints2[i]); } forcedCharacters = new List <CharEntry>(); for (int i = 0; i < map.forcedCharacters.Count; i++) { forcedCharacters.Add(map.forcedCharacters[i]); } lockedCharacters = new List <CharEntry>(); for (int i = 0; i < map.lockedCharacters.Count; i++) { lockedCharacters.Add(map.lockedCharacters[i]); } enemies = new List <SpawnData>(); for (int i = 0; i < map.enemies.Count; i++) { enemies.Add(map.enemies[i]); } allies = new List <SpawnData>(); for (int i = 0; i < map.allies.Count; i++) { allies.Add(map.allies[i]); } reinforcements = new List <SpawnData>(); for (int i = 0; i < map.reinforcements.Count; i++) { reinforcements.Add(map.reinforcements[i]); } interactions = new List <InteractPosition>(); for (int i = 0; i < map.interactions.Count; i++) { interactions.Add(map.interactions[i]); } triggerIds = new List <TriggerTuple>(); for (int i = 0; i < map.triggerIds.Count; i++) { triggerIds.Add(map.triggerIds[i]); } triggerAreas = new List <TriggerArea>(); for (int i = 0; i < map.triggerAreas.Count; i++) { triggerAreas.Add(map.triggerAreas[i]); } turnEvents = new List <TurnEvent>(); for (int i = 0; i < map.turnEvents.Count; i++) { turnEvents.Add(map.turnEvents[i]); } }
public int droneHealth; // Drone's health void Awake() { loseCondition = GameObject.FindGameObjectWithTag("T_Base").GetComponent <LoseCondition>(); droneManager = GameObject.FindGameObjectWithTag("T_DronesManager").GetComponent <DroneManager>(); }
private void Awake() { loseCondition = GameObject.FindGameObjectWithTag("GameManagerTag").GetComponent <LoseCondition>(); }
private void Awake() { this.loseCondition = GetComponent <LoseCondition>(); }
void Awake() { Instance = this; }