Elin Decompiled Documentation EA 23.102 Nightly
Loading...
Searching...
No Matches
TraitCoreDefense.cs
Go to the documentation of this file.
1public class TraitCoreDefense : Trait
2{
3 public override bool CanBeDestroyed => false;
4
5 public override bool CanOnlyCarry => true;
6
7 public override bool CanPutAway => false;
8
9 public override bool IsLightOn => true;
10
11 public override void TrySetAct(ActPlan p)
12 {
14 if (ev == null)
15 {
16 return;
17 }
18 if (ev.wave % 5 != 0 && !ev.retreated)
19 {
20 p.TrySetAct("actWarhorn", delegate
21 {
22 ev.Horn_Next();
23 return true;
24 });
25 }
26 if (ev.CanRetreat && !ev.retreated)
27 {
28 p.TrySetAct("actEvacDefense", delegate
29 {
30 ev.Horn_Retreat();
31 return true;
32 });
33 }
34 if (ev.CanCallAlly)
35 {
36 p.TrySetAct("actCallAlly", delegate
37 {
38 ev.Horn_Ally();
39 return true;
40 });
41 }
42 }
43}
bool TrySetAct(string lang, Func< bool > onPerform, Card tc, CursorInfo cursor=null, int dist=1, bool isHostileAct=false, bool localAct=true, bool canRepeat=false)
Definition: ActPlan.cs:344
Definition: EClass.cs:5
static Zone _zone
Definition: EClass.cs:20
override bool CanOnlyCarry
override void TrySetAct(ActPlan p)
override bool IsLightOn
override bool CanBeDestroyed
override bool CanPutAway
Definition: Trait.cs:7
ZoneEventManager events
Definition: Zone.cs:40