public void SetTarget(SelectionRegion Selected) { if (Selected == null || !Selected.Enabled || !typeof(SelectionRegion).IsAssignableFrom(Selected.GetType())) { return; } Morphid = Selected.Morphid; Lane = Selected.Lane; Minion = Selected.Minion; }
public bool MorphidAllowed(Morphid m) { return HasFlag(TargetTypeFlag.Morphid) && m != null && TargetScanner(m.GUID) && ((HasFlag(TargetTypeFlag.Friendly) && m.GUID == GameState.ActiveMorphid.GUID) || (HasFlag(TargetTypeFlag.Enemy) && m.GUID != GameState.ActiveMorphid.GUID)); }
public void Start() { CardOptions = new Dictionary<Slot, List<Card>>(); CardChecked = new Dictionary<Card, bool>(); CardByName = new Dictionary<string, Card>(); string lastSavedDeck = PlayerPrefs.GetString(DECK_SAVE_KEY, null); DeckList deckList = null; if (lastSavedDeck == null) { deckList = new DeckList(); } else { deckList = lastSavedDeck.DeserializeProtoString<DeckList>(); } foreach (Slot slot in Enum.GetValues(typeof(Slot))) { CardOptions[slot] = new List<Card>(); } foreach (Card card in Importer.Singleton.Cards) { CardOptions[card.Slot].Add(card); CardChecked[card] = deckList.Cards.Contains(card.Name); CardByName[card.Name] = card; } Morphid mockMorphid = new Morphid(); mockMorphid.Morphium = 10; lastMouseOver = null; Card.Owner = mockMorphid; Card.SnapToMouse(); }
private void EndTurn(Morphid enemy) { GameState.SwapTurn(); }