Show / Hide Table of Contents

Class SettlementInfluence

Handles settlement influence for a given settlement.

Inheritance
System.Object
SettlementInfluence
Implements
IThreadSafeSubscriptions
ISubscriptions<ThreadSafeSubscriptions>
ISubscriptions
IController
IViewController
IHasUniversalID
System.ComponentModel.INotifyPropertyChanged
Namespace: Eco.Gameplay.Settlements.Internal
Assembly: Eco.Gameplay.dll
Syntax
public sealed class SettlementInfluence : Object, IThreadSafeSubscriptions, ISubscriptions<ThreadSafeSubscriptions>, ISubscriptions, IController, IViewController, IHasUniversalID, INotifyPropertyChanged

Constructors

SettlementInfluence()

Declaration
public SettlementInfluence()

Properties

Color

Declaration
public Color Color { get; set; }
Property Value
Type Description
Color

ControllerID

Declaration
public ref int ControllerID { get; }
Property Value
Type Description
System.Int32

InfluencePoints

Declaration
public IReadOnlySet<RadPoint> InfluencePoints { get; }
Property Value
Type Description
System.Collections.Generic.IReadOnlySet<RadPoint>

InfluencePointsNowOrWhenFounded

If founded, returns the cached influence points. If not, returns what the initial influence will be when founded.

Declaration
public IEnumerable<RadPoint> InfluencePointsNowOrWhenFounded { get; }
Property Value
Type Description
System.Collections.Generic.IEnumerable<RadPoint>

Influencer

Declaration
public IInfluencer Influencer { get; }
Property Value
Type Description
IInfluencer

InfluenceTimerRunOut

Declaration
public static ThreadSafeAction<IInfluencer> InfluenceTimerRunOut { get; }
Property Value
Type Description
ThreadSafeAction<IInfluencer>

InfluenceWholeWorld

Declaration
public bool InfluenceWholeWorld { get; set; }
Property Value
Type Description
System.Boolean

InfluencingDeeds

Declaration
public IReadOnlySet<Deed> InfluencingDeeds { get; }
Property Value
Type Description
System.Collections.Generic.IReadOnlySet<Deed>

Subscriptions

Declaration
public ref ThreadSafeSubscriptions Subscriptions { get; }
Property Value
Type Description
ThreadSafeSubscriptions

Methods

InfluencePointOnceFounded()

Gives the influence point of the settlement once it's founded, which is the passed position with the given influence radius for our type.

Declaration
public RadPoint InfluencePointOnceFounded()
Returns
Type Description
RadPoint

Initialize(IInfluencer, Vector3i, SettlementType, Boolean, Func<Boolean>, Func<IEnumerable<Deed>>, SettlementCachedData, Func<Deed>)

Declaration
public void Initialize(IInfluencer influencer, Vector3i pos, SettlementType type, bool isFounded, Func<bool> settlementEnabled, Func<IEnumerable<Deed>> getInfluencingDeeds, SettlementCachedData cachedData, Func<Deed> sourceDeed)
Parameters
Type Name Description
IInfluencer influencer
Vector3i pos
SettlementType type
System.Boolean isFounded
System.Func<System.Boolean> settlementEnabled
System.Func<System.Collections.Generic.IEnumerable<Deed>> getInfluencingDeeds
SettlementCachedData cachedData
System.Func<Deed> sourceDeed

MakeInfluence()

Declaration
public Influence MakeInfluence()
Returns
Type Description
Influence

ParentFounded(Vector3i)

Get called whenever the parent influencer get gounded.

Declaration
public void ParentFounded(Vector3i foundingPosition)
Parameters
Type Name Description
Vector3i foundingPosition

ParentUnfounded()

Declaration
public void ParentUnfounded()

Tick()

This will get called constantly and will take care of checking whether there's a deed that has just became invalid or not.

Declaration
public void Tick()

UpdateInfluencePoints()

Calling this will make sure to update the cached influence points.

Declaration
public void UpdateInfluencePoints()

Events

PropertyChanged

Declaration
public event PropertyChangedEventHandler PropertyChanged
Event Type
Type Description
System.ComponentModel.PropertyChangedEventHandler

Implements

IThreadSafeSubscriptions
ISubscriptions<TSubscriptionsList>
ISubscriptions
IController
IViewController
IHasUniversalID
System.ComponentModel.INotifyPropertyChanged

Extension Methods

TagUtils.TagNames(Object, Boolean)
TagUtils.TagDisplayNames(Object, Boolean)
ClientSetViewExtensions.SetClassOfProperty(Object, Player, String, String, Int32)
TypeTooltipExtensions.UILinkGeneric(Object)
☀
☾
In This Article
Back to top
Copyright (c) Strange Loop Games 2021
☀
☾