/
CleverSatRandomShift.cfg
82 lines (75 loc) · 1.96 KB
/
CleverSatRandomShift.cfg
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
CONTRACT_TYPE
{
name = CleverSatRandomShift
title = Move a Satellite
group = CleverSat
description = The agency have asked us to move @/targetSat into a new orbit. So, let's get on that.
genericDescription = The agency have asked us to move a satellite into a new orbit. So, let's get on that.
targetBody = @/targetBody1
synopsis = Move @/targetSat into the correct orbit
completedMessage = Well, that should hold them for a while. Until they ask us to move them again of course.
rewardFunds = Random(20000,40000)
rewardReputation = Random(1.0, 2.0)
maxSimultaneous = 1
DATA
{
type = List<VesselIdentifier>
requiredValue = false
excludeTargets = $ConstellationList.Add(Target).Where(g => Vessel(g).IsOrbiting() && Vessel(g).Orbit().Inclination() < incThreshold))
}
DATA
{
type = List<VesselIdentifier>
requiredValue = false
validTarget = $SatList.ExcludeAll(@excludeTargets)
}
DATA
{
type = double
incThreshold = Prestige() == Trivial ? 20 : Prestige() == Significant ? 90 : 180
}
DATA
{
type = Vessel
uniquenessCheck = GROUP_ALL
targetSat = @validTarget.Random()
title = Must have a satellite deployed within pre-defined orbital parameters.
}
DATA
{
type = CelestialBody
targetBody1 = @/targetSat.CelestialBody()
hidden = true
}
BEHAVIOUR
{
name = OrbitGenerator
type = OrbitGenerator
RANDOM_ORBIT
{
type = RANDOM
altitudeFactor = @/targetBody1.IsMoon() ? 0.8 : Prestige() == Trivial ? 0.1 : Prestige() == Significant ? 0.3 : 0.5
inclinationFactor = @/targetBody1 == Sun ? 0 : Prestige() == Trivial ? 0.1 : Prestige() == Significant ? 0.5 : 0.8
}
}
PARAMETER
{
type = VesselParameterGroup
vessel = @/targetSat
PARAMETER
{
name = ReachSpecificOrbit
type = ReachSpecificOrbit
index = 0
deviationWindow = Prestige() == Trivial ? 10.0 : Prestige() == Significant ? 7.0 : 5.0
}
}
REQUIREMENT
{
name = Expression
type = Expression
checkOnActiveContract = false
expression = @CleverSat:RNG <3
title = The RNG must like you.
}
}