| 1 |
from focs._effects import ( |
| 2 |
AnyEmpire, |
| 3 |
Basic, |
| 4 |
EffectsGroup, |
| 5 |
HasTag, |
| 6 |
IsSource, |
| 7 |
MaxOf, |
| 8 |
OwnedBy, |
| 9 |
Planet, |
| 10 |
Population, |
| 11 |
SetVisibility, |
| 12 |
Source, |
| 13 |
ValueVisibility, |
| 14 |
VisibleToEmpire, |
| 15 |
WithinStarlaneJumps, |
| 16 |
) |
| 17 |
|
| 18 |
|
| 19 |
def PRECOGNITIVE_DETECTION(jumps: int): |
| 20 |
return [ |
| 21 |
EffectsGroup( |
| 22 |
description="PRECOGNITIVE_DETECTION_DESC", |
| 23 |
scope=Planet() |
| 24 |
& ~VisibleToEmpire(empire=Source.Owner) |
| 25 |
& ~IsSource |
| 26 |
& ~OwnedBy(empire=Source.Owner) |
| 27 |
& WithinStarlaneJumps(jumps=jumps, condition=IsSource), |
| 28 |
activation=OwnedBy(affiliation=AnyEmpire), |
| 29 |
effects=SetVisibility(empire=Source.Owner, visibility=MaxOf("Visibility", Basic, ValueVisibility)), |
| 30 |
) |
| 31 |
] |
| 32 |
|
| 33 |
|
| 34 |
def TELEPATHIC_DETECTION(jumps: int) -> list: |
| 35 |
return [ |
| 36 |
EffectsGroup( |
| 37 |
description="TELEPATHIC_DETECTION_DESC", |
| 38 |
scope=Planet() |
| 39 |
& ~Population(high=0) |
| 40 |
& ~OwnedBy(empire=Source.Owner) |
| 41 |
& ~VisibleToEmpire(empire=Source.Owner) |
| 42 |
& WithinStarlaneJumps(jumps=jumps, condition=IsSource) |
| 43 |
& ~IsSource, |
| 44 |
activation=OwnedBy(affiliation=AnyEmpire), |
| 45 |
effects=SetVisibility(empire=Source.Owner, visibility=MaxOf("Visibility", Basic, ValueVisibility)), |
| 46 |
) |
| 47 |
] |
| 48 |
|
| 49 |
|
| 50 |
def HAEMAESTHETIC_DETECTION(jumps: int) -> list: |
| 51 |
return [ |
| 52 |
EffectsGroup( |
| 53 |
description="HAEMAESTHETIC_DETECTION_DESC", |
| 54 |
scope=Planet() |
| 55 |
& ~Population(high=0) |
| 56 |
& HasTag(name="ORGANIC") |
| 57 |
& ~OwnedBy(empire=Source.Owner) |
| 58 |
& ~VisibleToEmpire(empire=Source.Owner) |
| 59 |
& WithinStarlaneJumps(jumps=jumps, condition=IsSource) |
| 60 |
& ~IsSource, |
| 61 |
activation=OwnedBy(affiliation=AnyEmpire), |
| 62 |
effects=SetVisibility(empire=Source.Owner, visibility=MaxOf("Visibility", Basic, ValueVisibility)), |
| 63 |
) |
| 64 |
] |