Contracts

class ContractManager

Contracts manager. Obtained by calling contract_manager().

std::set<std::string> types()

A list of all contract types.

Game Scenes:All
std::vector<Contract> all_contracts()

A list of all contracts.

Game Scenes:All
std::vector<Contract> active_contracts()

A list of all active contracts.

Game Scenes:All
std::vector<Contract> offered_contracts()

A list of all offered, but unaccepted, contracts.

Game Scenes:All
std::vector<Contract> completed_contracts()

A list of all completed contracts.

Game Scenes:All
std::vector<Contract> failed_contracts()

A list of all failed contracts.

Game Scenes:All
class Contract

A contract. Can be accessed using contract_manager().

std::string type()

Type of the contract.

Game Scenes:All
std::string title()

Title of the contract.

Game Scenes:All
std::string description()

Description of the contract.

Game Scenes:All
std::string notes()

Notes for the contract.

Game Scenes:All
std::string synopsis()

Synopsis for the contract.

Game Scenes:All
std::vector<std::string> keywords()

Keywords for the contract.

Game Scenes:All
ContractState state()

State of the contract.

Game Scenes:All
bool seen()

Whether the contract has been seen.

Game Scenes:All
bool read()

Whether the contract has been read.

Game Scenes:All
bool active()

Whether the contract is active.

Game Scenes:All
bool failed()

Whether the contract has been failed.

Game Scenes:All
bool can_be_canceled()

Whether the contract can be canceled.

Game Scenes:All
bool can_be_declined()

Whether the contract can be declined.

Game Scenes:All
bool can_be_failed()

Whether the contract can be failed.

Game Scenes:All
void accept()

Accept an offered contract.

Game Scenes:All
void cancel()

Cancel an active contract.

Game Scenes:All
void decline()

Decline an offered contract.

Game Scenes:All
double funds_advance()

Funds received when accepting the contract.

Game Scenes:All
double funds_completion()

Funds received on completion of the contract.

Game Scenes:All
double funds_failure()

Funds lost if the contract is failed.

Game Scenes:All
double reputation_completion()

Reputation gained on completion of the contract.

Game Scenes:All
double reputation_failure()

Reputation lost if the contract is failed.

Game Scenes:All
double science_completion()

Science gained on completion of the contract.

Game Scenes:All
std::vector<ContractParameter> parameters()

Parameters for the contract.

Game Scenes:All
enum struct ContractState

The state of a contract. See Contract::state().

enumerator active

The contract is active.

enumerator canceled

The contract has been canceled.

enumerator completed

The contract has been completed.

enumerator deadline_expired

The deadline for the contract has expired.

enumerator declined

The contract has been declined.

enumerator failed

The contract has been failed.

enumerator generated

The contract has been generated.

enumerator offered

The contract has been offered to the player.

enumerator offer_expired

The contract was offered to the player, but the offer expired.

enumerator withdrawn

The contract has been withdrawn.

class ContractParameter

A contract parameter. See Contract::parameters().

std::string title()

Title of the parameter.

Game Scenes:All
std::string notes()

Notes for the parameter.

Game Scenes:All
std::vector<ContractParameter> children()

Child contract parameters.

Game Scenes:All
bool completed()

Whether the parameter has been completed.

Game Scenes:All
bool failed()

Whether the parameter has been failed.

Game Scenes:All
bool optional()

Whether the contract parameter is optional.

Game Scenes:All
double funds_completion()

Funds received on completion of the contract parameter.

Game Scenes:All
double funds_failure()

Funds lost if the contract parameter is failed.

Game Scenes:All
double reputation_completion()

Reputation gained on completion of the contract parameter.

Game Scenes:All
double reputation_failure()

Reputation lost if the contract parameter is failed.

Game Scenes:All
double science_completion()

Science gained on completion of the contract parameter.

Game Scenes:All