Kerbal Space Program  1.12.4
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Events Macros
Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | Protected Types | Protected Member Functions | Static Protected Member Functions | Protected Attributes | Properties | List of all members
Contracts.Contract Class Reference
Inheritance diagram for Contracts.Contract:
Contracts.IContractParameterHost Contracts.Templates.CollectScience Contracts.Templates.GrandTour Contracts.Templates.OrbitalConstructionContract Contracts.Templates.PartTest Contracts.Templates.PlantFlag Contracts.Templates.RecoverAsset Contracts.Templates.RoverConstructionContract Contracts.Templates.VesselRepairContract Expansions.Serenity.Contracts.DeployedScienceContract Expansions.Serenity.Contracts.ROCScienceArmContract Expansions.Serenity.Contracts.ROCScienceRetrievalContract FinePrint.Contracts.ARMContract FinePrint.Contracts.BaseContract FinePrint.Contracts.CometSampleContract FinePrint.Contracts.ExplorationContract FinePrint.Contracts.ISRUContract FinePrint.Contracts.SatelliteContract FinePrint.Contracts.StationContract FinePrint.Contracts.SurveyContract FinePrint.Contracts.TourismContract SentinelMission.CometDetectionContract SentinelMission.SentinelContract

Public Types

enum  ContractPrestige : int { ContractPrestige.Trivial = 0, ContractPrestige.Significant = 1, ContractPrestige.Exceptional = 2 }
 
enum  DeadlineType : int { DeadlineType.Fixed, DeadlineType.Floating, DeadlineType.None }
 
enum  State : int {
  State.Generated, State.Offered, State.OfferExpired, State.Declined,
  State.Cancelled, State.Active, State.Completed, State.DeadlineExpired,
  State.Failed, State.Withdrawn
}
 
enum  Viewed : int { Viewed.Unseen = 0, Viewed.Seen = 1, Viewed.Read = 2 }
 

Public Member Functions

bool Accept ()
 
ContractParameter AddParameter (ContractParameter parameter, string id=null)
 
virtual bool CanBeCancelled ()
 If this contract can be cancelled More...
 
virtual bool CanBeDeclined ()
 If this contract can be declined More...
 
virtual bool CanBeFailed ()
 If this contract can fail More...
 
bool Cancel ()
 
bool Complete ()
 
 Contract ()
 
bool Decline ()
 
bool Fail ()
 
void GenerateFailed ()
 
ContractParameter GetParameter (int index)
 
ContractParameter GetParameter (string id)
 
ContractParameter GetParameter (System.Type type)
 
GetParameter< T > (string id=null)
 
bool IsFinished ()
 
void Kill ()
 Prepares a contract to be forcibly removed from the contract system. More...
 
virtual bool MeetRequirements ()
 Test to see if this contract type meets requirements to be able to create a contract More...
 
virtual string MissionControlTextRich ()
 
bool Offer ()
 
void ParameterStateUpdate (ContractParameter p)
 
void Register ()
 Registers all event hooks when contract is spawned in correct scene and is active More...
 
void RemoveParameter (int index)
 
void RemoveParameter (string id)
 
void RemoveParameter (System.Type type)
 
void RemoveParameter (ContractParameter parameter)
 
void Reset ()
 
void Save (ConfigNode node)
 
void SetViewed (Viewed viewed)
 Sets whether the player has either seen or read a contract in Mission Control. More...
 
void Unregister ()
 Unregisters all event hooks when contract becomes inactive or scene changes More...
 
void Update ()
 
void Withdraw ()
 

Static Public Member Functions

static Contract Generate (System.Type contractType, Contract.ContractPrestige difficulty, int seed, State state)
 Generates a new random mission More...
 
static Contract Load (Contract contract, ConfigNode node)
 

Public Attributes

bool AutoAccept
 Whether this contract is automatically accepted after being offered by the contract system. More...
 
double FundsAdvance
 The funds advance gained from accepting this mission More...
 
double FundsCompletion
 The funds gained for completing the mission More...
 
double FundsFailure
 The funds gained for failing the mission More...
 
bool IgnoresWeight
 Whether this contract ignores weight changes, always staying at default. More...
 
EventData< StateOnStateChange = new EventData<State>("OnStateChange")
 
EventData< ViewedOnViewedChange = new EventData<Viewed>("OnViewedChange")
 
float ReputationCompletion
 The reputation gain for completing the mission More...
 
float ReputationFailure
 The reputation gain for failing to complete the mission before the deadline More...
 
float ScienceCompletion
 The science gained for completing the mission More...
 
double TimeDeadline
 The time duration from when this mission was accepted until the deadline is hit More...
 
double TimeExpiry
 The time duration from when this mission was generated until it expires More...
 

Protected Types

enum  ProgressState { ProgressState.Unreached, ProgressState.Reached, ProgressState.Incomplete, ProgressState.Complete }
 

Protected Member Functions

bool AddKeywords (params string[] keywords)
 
bool AddKeywordsRequired (params string[] keywords)
 
virtual void AwardAdvance ()
 
virtual void AwardCompletion ()
 
virtual bool Generate ()
 Generates a new random mission More...
 
virtual string GetDescription ()
 Generates the human readable mission text from instance info More...
 
float GetDestinationWeight (CelestialBody body)
 
virtual string GetHashString ()
 
virtual string GetNotes ()
 Generates the human readable mission text from instance info More...
 
virtual string GetSynopsys ()
 Generates the human readable mission text from instance info More...
 
virtual string GetTitle ()
 Generates the human readable mission text from instance info More...
 
virtual List< CelestialBodyGetWeightBodies ()
 Optional celestial bodies to use when making weight changes. More...
 
virtual string MessageAccepted ()
 Overload to replace standard 'contract complete' message More...
 
virtual string MessageAdvances ()
 Appended to the MessageAccepted when a mission is accepted More...
 
virtual string MessageCancellationPenalties (double fundsPenalty, float repPenalty)
 Appended to the text when a mission is cancelled More...
 
virtual string MessageCancelled ()
 Overload to replace standard 'mission cancelled' message More...
 
virtual string MessageCompleted ()
 Overload to replace standard 'contract complete' message More...
 
virtual string MessageDeadlineExpired ()
 Overload to replace standard 'deadline expired' message More...
 
virtual string MessageFailed ()
 Overload to replace standard 'deadline expired' message More...
 
virtual string MessageFailurePenalties ()
 Appended to the text when a mission is failed More...
 
virtual string MessageOffered ()
 Overload to replace standard 'contract offered' message More...
 
virtual string MessageOfferExpired ()
 Overload to replace standard 'offer expired' message More...
 
virtual string MessageRewards ()
 Appended to the MessageCompleted text when a mission is completed More...
 
string MissionNotes ()
 
string MissionParameter (ContractParameter parameter, int indent)
 
virtual void OnAccepted ()
 
virtual void OnCancelled ()
 
virtual void OnCompleted ()
 
virtual void OnDeadlineExpired ()
 
virtual void OnDeclined ()
 
virtual void OnFailed ()
 
virtual void OnFinished ()
 
virtual void OnGenerateFailed ()
 
virtual void OnLoad (ConfigNode node)
 
virtual void OnOffered ()
 
virtual void OnOfferExpired ()
 
virtual void OnParameterStateChange (ContractParameter p)
 
virtual void OnRead ()
 
virtual void OnRegister ()
 Registers all event hooks when contract is spawned in correct scene and is active More...
 
virtual void OnReset ()
 Called to reset the contract on scene loads, vessel changes, etc, if required. More...
 
virtual void OnSave (ConfigNode node)
 
virtual void OnSeen ()
 
virtual void OnUnregister ()
 Unregisters all event hooks when contract becomes inactive or scene changes More...
 
virtual void OnUpdate ()
 Called per frame - with current time - when contract is active More...
 
virtual void OnWithdrawn ()
 
virtual void PenalizeCancellation ()
 
virtual void PenalizeFailure ()
 
void SendStateMessage (string title, string message, MessageSystemButton.MessageButtonColor color, MessageSystemButton.ButtonIcons icon)
 Sends user a text message via messaging system More...
 
void SetDeadlineDays (float days, CelestialBody body=null)
 
void SetDeadlineYears (float years, CelestialBody body=null)
 
void SetExpiry ()
 
void SetExpiry (int minDays, int maxDays)
 
void SetExpiry (float minDays, float maxDays)
 
void SetFunds (float advance, float completion, CelestialBody body=null)
 
void SetFunds (float advance, float completion, float failure, CelestialBody body=null)
 
void SetReputation (float completion, float failure, CelestialBody body=null)
 
void SetReputation (float completion, CelestialBody body=null)
 
void SetScience (float completion, CelestialBody body=null)
 
void SetState (State newState)
 
CelestialBody WeightedBodyChoice (IList< CelestialBody > bodies, System.Random generator=null)
 

Static Protected Member Functions

static int CountBodies_Complete (bool includeKerbin, bool includeSun, string nodeComplete)
 
static int CountBodies_Reached (bool includeKerbin, bool includeSun)
 
static List< CelestialBodyGetBodies (bool includeKerbin, bool includeSun)
 
static List< CelestialBodyGetBodies (string nodeName, ProgressState nodeState, System.Func< CelestialBody, bool > where=null)
 
static List< CelestialBodyGetBodies (ProgressState bodyState, System.Func< CelestialBody, bool > where=null)
 
static List< CelestialBodyGetBodies (ProgressState bodyState, string nodeName, ProgressState nodeState, System.Func< CelestialBody, bool > where=null)
 
static List< CelestialBodyGetBodies_Complete (bool includeKerbin, bool includeSun, string complete)
 
static List< CelestialBodyGetBodies_InComplete (bool includeKerbin, bool includeSun, string notComplete)
 
static List< CelestialBodyGetBodies_NextUnreached (int depth, System.Func< CelestialBody, bool > where=null)
 
static List< CelestialBodyGetBodies_NotReached (bool includeKerbin, bool includeSun)
 
static List< CelestialBodyGetBodies_Reached (bool includeKerbin, bool includeSun)
 

Protected Attributes

Agent agent = null
 
double dateAccepted
 
double dateDeadline
 
double dateExpire
 
double dateFinished
 
Contract.DeadlineType deadlineType = DeadlineType.Floating
 
Contract.DeadlineType expiryType = DeadlineType.Floating
 
Contract.ContractPrestige prestige
 

Properties

Agent Agent [get]
 Space agency or organisation that is requesting this mission More...
 
IEnumerable< ContractParameterAllParameters [get]
 
System.Guid ContractGuid [get]
 Globally unique mission identifier (will be unique even for two contracts considered to be repeats (matching ContractIDs)) More...
 
long ContractID [get]
 Unique mission identifier (combines mission name and parameters) More...
 
static int contractsInExistance [get, set]
 
State ContractState [get]
 
Viewed ContractViewed [get]
 
double DateAccepted [get]
 
double DateDeadline [get]
 
double DateExpire [get]
 
double DateFinished [get]
 
string Description [get]
 
static double GameTime [get]
 
List< string > Keywords [get]
 Keywords which help to score agent suitability for this contract More...
 
List< string > KeywordsRequired [get]
 Keywords which MUST be matched by a mentality in order for agents/mentalities to be valid eg. A mentality which DOES NOT positively score these have these will fail verification (excludes others) More...
 
string LocalizedContractState [get]
 
int MissionSeed [get]
 The seed that was used to generate the mission More...
 
string Notes [get]
 
int ParameterCount [get]
 
IContractParameterHost Parent [get]
 
Contract.ContractPrestige Prestige [get]
 Difficulty that this contract was generated for More...
 
Contract Root [get]
 
string Synopsys [get]
 
ContractParameter this[int index] [get]
 
ContractParameter this[string id] [get]
 
ContractParameter this[System.Type type] [get]
 
string Title [get]
 
- Properties inherited from Contracts.IContractParameterHost
int ParameterCount [get]
 
IContractParameterHost Parent [get]
 
Contract Root [get]
 
ContractParameter this[int index] [get]
 
ContractParameter this[string id] [get]
 
ContractParameter this[System.Type type] [get]
 
string Title [get]
 

Member Enumeration Documentation

Enumerator
Trivial 
Significant 
Exceptional 
Enumerator
Fixed 
Floating 
None 
Enumerator
Unreached 
Reached 
Incomplete 
Complete 
Enumerator
Generated 
Offered 
OfferExpired 
Declined 
Cancelled 
Active 
Completed 
DeadlineExpired 
Failed 
Withdrawn 
Enumerator
Unseen 
Seen 
Read 

Constructor & Destructor Documentation

Contracts.Contract.Contract ( )
inline

Member Function Documentation

bool Contracts.Contract.Accept ( )
inline
bool Contracts.Contract.AddKeywords ( params string[]  keywords)
inlineprotected
bool Contracts.Contract.AddKeywordsRequired ( params string[]  keywords)
inlineprotected
ContractParameter Contracts.Contract.AddParameter ( ContractParameter  parameter,
string  id = null 
)
inline
virtual void Contracts.Contract.AwardAdvance ( )
inlineprotectedvirtual
virtual void Contracts.Contract.AwardCompletion ( )
inlineprotectedvirtual
virtual bool Contracts.Contract.CanBeCancelled ( )
inlinevirtual
virtual bool Contracts.Contract.CanBeDeclined ( )
inlinevirtual
virtual bool Contracts.Contract.CanBeFailed ( )
inlinevirtual

If this contract can fail

Reimplemented in FinePrint.Contracts.ExplorationContract.

bool Contracts.Contract.Cancel ( )
inline
bool Contracts.Contract.Complete ( )
inline
static int Contracts.Contract.CountBodies_Complete ( bool  includeKerbin,
bool  includeSun,
string  nodeComplete 
)
inlinestaticprotected
static int Contracts.Contract.CountBodies_Reached ( bool  includeKerbin,
bool  includeSun 
)
inlinestaticprotected
bool Contracts.Contract.Decline ( )
inline
bool Contracts.Contract.Fail ( )
inline
virtual bool Contracts.Contract.Generate ( )
inlineprotectedvirtual
static Contract Contracts.Contract.Generate ( System.Type  contractType,
Contract.ContractPrestige  difficulty,
int  seed,
State  state 
)
inlinestatic

Generates a new random mission

< set up initial contract generation

< check to see if contract type requirements are met - if not, discard

< generate the contract - if contract somehow generates as invalid then discard

< grab a suitable agent

< if no suitable agent is found then discard

< create the contract's unique id from it's parameters

void Contracts.Contract.GenerateFailed ( )
inline
static List<CelestialBody> Contracts.Contract.GetBodies ( bool  includeKerbin,
bool  includeSun 
)
inlinestaticprotected
static List<CelestialBody> Contracts.Contract.GetBodies ( string  nodeName,
ProgressState  nodeState,
System.Func< CelestialBody, bool >  where = null 
)
inlinestaticprotected
static List<CelestialBody> Contracts.Contract.GetBodies ( ProgressState  bodyState,
System.Func< CelestialBody, bool >  where = null 
)
inlinestaticprotected
static List<CelestialBody> Contracts.Contract.GetBodies ( ProgressState  bodyState,
string  nodeName,
ProgressState  nodeState,
System.Func< CelestialBody, bool >  where = null 
)
inlinestaticprotected
static List<CelestialBody> Contracts.Contract.GetBodies_Complete ( bool  includeKerbin,
bool  includeSun,
string  complete 
)
inlinestaticprotected
static List<CelestialBody> Contracts.Contract.GetBodies_InComplete ( bool  includeKerbin,
bool  includeSun,
string  notComplete 
)
inlinestaticprotected
static List<CelestialBody> Contracts.Contract.GetBodies_NextUnreached ( int  depth,
System.Func< CelestialBody, bool >  where = null 
)
inlinestaticprotected
static List<CelestialBody> Contracts.Contract.GetBodies_NotReached ( bool  includeKerbin,
bool  includeSun 
)
inlinestaticprotected
static List<CelestialBody> Contracts.Contract.GetBodies_Reached ( bool  includeKerbin,
bool  includeSun 
)
inlinestaticprotected
virtual string Contracts.Contract.GetDescription ( )
inlineprotectedvirtual
float Contracts.Contract.GetDestinationWeight ( CelestialBody  body)
inlineprotected
virtual string Contracts.Contract.GetHashString ( )
inlineprotectedvirtual
virtual string Contracts.Contract.GetNotes ( )
inlineprotectedvirtual

Generates the human readable mission text from instance info

Reimplemented in FinePrint.Contracts.SurveyContract, Contracts.Templates.RecoverAsset, FinePrint.Contracts.TourismContract, and Contracts.Templates.GrandTour.

ContractParameter Contracts.Contract.GetParameter ( int  index)
inline
ContractParameter Contracts.Contract.GetParameter ( string  id)
inline
ContractParameter Contracts.Contract.GetParameter ( System.Type  type)
inline
T Contracts.Contract.GetParameter< T > ( string  id = null)
inline

Implements Contracts.IContractParameterHost.

Type Constraints
T :ContractParameter 
virtual string Contracts.Contract.GetSynopsys ( )
inlineprotectedvirtual
virtual string Contracts.Contract.GetTitle ( )
inlineprotectedvirtual
virtual List<CelestialBody> Contracts.Contract.GetWeightBodies ( )
inlineprotectedvirtual
bool Contracts.Contract.IsFinished ( )
inline
void Contracts.Contract.Kill ( )
inline

Prepares a contract to be forcibly removed from the contract system.

static Contract Contracts.Contract.Load ( Contract  contract,
ConfigNode  node 
)
inlinestatic

< values

< parameters

virtual bool Contracts.Contract.MeetRequirements ( )
inlinevirtual
virtual string Contracts.Contract.MessageAccepted ( )
inlineprotectedvirtual

Overload to replace standard 'contract complete' message

Returns
virtual string Contracts.Contract.MessageAdvances ( )
inlineprotectedvirtual

Appended to the MessageAccepted when a mission is accepted

virtual string Contracts.Contract.MessageCancellationPenalties ( double  fundsPenalty,
float  repPenalty 
)
inlineprotectedvirtual

Appended to the text when a mission is cancelled

virtual string Contracts.Contract.MessageCancelled ( )
inlineprotectedvirtual

Overload to replace standard 'mission cancelled' message

Returns

Reimplemented in Contracts.Templates.RecoverAsset, and FinePrint.Contracts.TourismContract.

virtual string Contracts.Contract.MessageCompleted ( )
inlineprotectedvirtual
virtual string Contracts.Contract.MessageDeadlineExpired ( )
inlineprotectedvirtual

Overload to replace standard 'deadline expired' message

Returns

Reimplemented in Contracts.Templates.RecoverAsset, and FinePrint.Contracts.TourismContract.

virtual string Contracts.Contract.MessageFailed ( )
inlineprotectedvirtual

Overload to replace standard 'deadline expired' message

Returns

Reimplemented in Contracts.Templates.RecoverAsset, and FinePrint.Contracts.TourismContract.

virtual string Contracts.Contract.MessageFailurePenalties ( )
inlineprotectedvirtual

Appended to the text when a mission is failed

virtual string Contracts.Contract.MessageOffered ( )
inlineprotectedvirtual

Overload to replace standard 'contract offered' message

Returns
virtual string Contracts.Contract.MessageOfferExpired ( )
inlineprotectedvirtual

Overload to replace standard 'offer expired' message

Returns
virtual string Contracts.Contract.MessageRewards ( )
inlineprotectedvirtual

Appended to the MessageCompleted text when a mission is completed

virtual string Contracts.Contract.MissionControlTextRich ( )
inlinevirtual
string Contracts.Contract.MissionNotes ( )
inlineprotected
string Contracts.Contract.MissionParameter ( ContractParameter  parameter,
int  indent 
)
inlineprotected
bool Contracts.Contract.Offer ( )
inline
virtual void Contracts.Contract.OnAccepted ( )
inlineprotectedvirtual
virtual void Contracts.Contract.OnCancelled ( )
inlineprotectedvirtual
virtual void Contracts.Contract.OnCompleted ( )
inlineprotectedvirtual
virtual void Contracts.Contract.OnDeadlineExpired ( )
inlineprotectedvirtual
virtual void Contracts.Contract.OnDeclined ( )
inlineprotectedvirtual
virtual void Contracts.Contract.OnFailed ( )
inlineprotectedvirtual
virtual void Contracts.Contract.OnFinished ( )
inlineprotectedvirtual
virtual void Contracts.Contract.OnGenerateFailed ( )
inlineprotectedvirtual
virtual void Contracts.Contract.OnLoad ( ConfigNode  node)
inlineprotectedvirtual
virtual void Contracts.Contract.OnOffered ( )
inlineprotectedvirtual
virtual void Contracts.Contract.OnOfferExpired ( )
inlineprotectedvirtual
virtual void Contracts.Contract.OnParameterStateChange ( ContractParameter  p)
inlineprotectedvirtual
virtual void Contracts.Contract.OnRead ( )
inlineprotectedvirtual
virtual void Contracts.Contract.OnRegister ( )
inlineprotectedvirtual
virtual void Contracts.Contract.OnReset ( )
inlineprotectedvirtual

Called to reset the contract on scene loads, vessel changes, etc, if required.

virtual void Contracts.Contract.OnSave ( ConfigNode  node)
inlineprotectedvirtual
virtual void Contracts.Contract.OnSeen ( )
inlineprotectedvirtual
virtual void Contracts.Contract.OnUnregister ( )
inlineprotectedvirtual
virtual void Contracts.Contract.OnUpdate ( )
inlineprotectedvirtual

Called per frame - with current time - when contract is active

virtual void Contracts.Contract.OnWithdrawn ( )
inlineprotectedvirtual
void Contracts.Contract.ParameterStateUpdate ( ContractParameter  p)
inline
virtual void Contracts.Contract.PenalizeCancellation ( )
inlineprotectedvirtual
virtual void Contracts.Contract.PenalizeFailure ( )
inlineprotectedvirtual
void Contracts.Contract.Register ( )
inline

Registers all event hooks when contract is spawned in correct scene and is active

void Contracts.Contract.RemoveParameter ( int  index)
inline
void Contracts.Contract.RemoveParameter ( string  id)
inline
void Contracts.Contract.RemoveParameter ( System.Type  type)
inline
void Contracts.Contract.RemoveParameter ( ContractParameter  parameter)
inline
void Contracts.Contract.Reset ( )
inline
void Contracts.Contract.Save ( ConfigNode  node)
inline
void Contracts.Contract.SendStateMessage ( string  title,
string  message,
MessageSystemButton.MessageButtonColor  color,
MessageSystemButton.ButtonIcons  icon 
)
inlineprotected

Sends user a text message via messaging system

void Contracts.Contract.SetDeadlineDays ( float  days,
CelestialBody  body = null 
)
inlineprotected
void Contracts.Contract.SetDeadlineYears ( float  years,
CelestialBody  body = null 
)
inlineprotected
void Contracts.Contract.SetExpiry ( )
inlineprotected
void Contracts.Contract.SetExpiry ( int  minDays,
int  maxDays 
)
inlineprotected
void Contracts.Contract.SetExpiry ( float  minDays,
float  maxDays 
)
inlineprotected
void Contracts.Contract.SetFunds ( float  advance,
float  completion,
CelestialBody  body = null 
)
inlineprotected
void Contracts.Contract.SetFunds ( float  advance,
float  completion,
float  failure,
CelestialBody  body = null 
)
inlineprotected
void Contracts.Contract.SetReputation ( float  completion,
float  failure,
CelestialBody  body = null 
)
inlineprotected
void Contracts.Contract.SetReputation ( float  completion,
CelestialBody  body = null 
)
inlineprotected
void Contracts.Contract.SetScience ( float  completion,
CelestialBody  body = null 
)
inlineprotected
void Contracts.Contract.SetState ( State  newState)
inlineprotected

< SendStateMessage("Contract Cancelled", MessageCancelled() + StateMsgAddition(MessagePenalties()), MessageSystemButton.MessageButtonColor.GREEN, MessageSystemButton.ButtonIcons.MESSAGE);

void Contracts.Contract.SetViewed ( Viewed  viewed)
inline

Sets whether the player has either seen or read a contract in Mission Control.

Parameters
viewedThe new viewed state - can only go up.
void Contracts.Contract.Unregister ( )
inline

Unregisters all event hooks when contract becomes inactive or scene changes

void Contracts.Contract.Update ( )
inline
CelestialBody Contracts.Contract.WeightedBodyChoice ( IList< CelestialBody bodies,
System.Random  generator = null 
)
inlineprotected
void Contracts.Contract.Withdraw ( )
inline

Member Data Documentation

Agent Contracts.Contract.agent = null
protected
bool Contracts.Contract.AutoAccept

Whether this contract is automatically accepted after being offered by the contract system.

double Contracts.Contract.dateAccepted
protected
double Contracts.Contract.dateDeadline
protected
double Contracts.Contract.dateExpire
protected
double Contracts.Contract.dateFinished
protected
Contract.DeadlineType Contracts.Contract.deadlineType = DeadlineType.Floating
protected
Contract.DeadlineType Contracts.Contract.expiryType = DeadlineType.Floating
protected
double Contracts.Contract.FundsAdvance

The funds advance gained from accepting this mission

double Contracts.Contract.FundsCompletion

The funds gained for completing the mission

double Contracts.Contract.FundsFailure

The funds gained for failing the mission

bool Contracts.Contract.IgnoresWeight

Whether this contract ignores weight changes, always staying at default.

EventData<State> Contracts.Contract.OnStateChange = new EventData<State>("OnStateChange")
EventData<Viewed> Contracts.Contract.OnViewedChange = new EventData<Viewed>("OnViewedChange")
Contract.ContractPrestige Contracts.Contract.prestige
protected
float Contracts.Contract.ReputationCompletion

The reputation gain for completing the mission

float Contracts.Contract.ReputationFailure

The reputation gain for failing to complete the mission before the deadline

float Contracts.Contract.ScienceCompletion

The science gained for completing the mission

double Contracts.Contract.TimeDeadline

The time duration from when this mission was accepted until the deadline is hit

double Contracts.Contract.TimeExpiry

The time duration from when this mission was generated until it expires

Property Documentation

Agent Contracts.Contract.Agent
get

Space agency or organisation that is requesting this mission

IEnumerable<ContractParameter> Contracts.Contract.AllParameters
get
System.Guid Contracts.Contract.ContractGuid
get

Globally unique mission identifier (will be unique even for two contracts considered to be repeats (matching ContractIDs))

long Contracts.Contract.ContractID
get

Unique mission identifier (combines mission name and parameters)

int Contracts.Contract.contractsInExistance
staticgetset
State Contracts.Contract.ContractState
get
Viewed Contracts.Contract.ContractViewed
get
double Contracts.Contract.DateAccepted
get
double Contracts.Contract.DateDeadline
get
double Contracts.Contract.DateExpire
get
double Contracts.Contract.DateFinished
get
string Contracts.Contract.Description
get
double Contracts.Contract.GameTime
staticgetprotected
List<string> Contracts.Contract.Keywords
get

Keywords which help to score agent suitability for this contract

List<string> Contracts.Contract.KeywordsRequired
get

Keywords which MUST be matched by a mentality in order for agents/mentalities to be valid eg. A mentality which DOES NOT positively score these have these will fail verification (excludes others)

string Contracts.Contract.LocalizedContractState
get
int Contracts.Contract.MissionSeed
get

The seed that was used to generate the mission

string Contracts.Contract.Notes
get
int Contracts.Contract.ParameterCount
get
IContractParameterHost Contracts.Contract.Parent
get
Contract.ContractPrestige Contracts.Contract.Prestige
get

Difficulty that this contract was generated for

Contract Contracts.Contract.Root
get
string Contracts.Contract.Synopsys
get
ContractParameter Contracts.Contract.this[int index]
get
ContractParameter Contracts.Contract.this[string id]
get
ContractParameter Contracts.Contract.this[System.Type type]
get
string Contracts.Contract.Title
get

The documentation for this class was generated from the following file: