public override void Enter() { ucif = SetSubscription <UseCardInfo>(TriggerType.UseCardAfter, 1); nCharStatus.KaleidoScope cs = new nCharStatus.KaleidoScope(); cs.skill = this; character.charStatusControl.EnterStatus(cs); }
// Update is called once per frame void Update() { if (Input.GetKeyDown(KeyCode.B)) { UseCardInfo uc = GetTriggerInfo <UseCardInfo>(); //Debug.Log(uc.test); DamageInfo dif = GetTriggerInfo <DamageInfo>(); //Debug.Log(dif.test); } }
public void UseCard(CardData card) { Debug.Log("Use Card!!!!!!!!"); FieldManager.instance.currentActionCharacter.ReduceEnergy(card.cardCost); if (FieldManager.instance.currentActionCharacter.magicPoint >= card.oriMagicConsume) { FieldManager.instance.CharMagicEffect(FieldManager.instance.currentActionCharacter, card.oriMagicConsume); card.magicCheck = true; } if (FieldManager.instance.currentActionCharacter == card.linkChar && card.linkChar != null) { card.linkCheck = true; } if (card.exhasutCount >= 1) { CardInfo cardif = TriggerManager.instance.GetTriggerInfo <CardInfo>(); cardif.SetInfo(card); cardif.GoTrigger(TriggerType.CardExhaust); } UseCardInfo cif = TriggerManager.instance.GetTriggerInfo <UseCardInfo>(); cif.SetInfo(card); cif.GoTrigger(TriggerType.UseCardCheck); cif.GoTrigger(TriggerType.UseCardAfter); OrderManager.instance.AddOrder(new sysOrder.UseCardOrder(card)); OrderManager.instance.AddOrder(new sysOrder.CharMoveOrder()); cif.GoTrigger(TriggerType.UseCardBefore); //OrderManager.instance.AddOrder(new sysOrder.DiscardOrder(card)); if (card.exhasutCount >= 1) { DiscardHandCard(card, true); } else { DiscardHandCard(card); } }
public override void Enter() { cif = SetSubscription <UseCardInfo>(TriggerType.UseCardCheck, 1); //FieldManager.instance.overloadNum += energyNum; }