Interface ITimeSkipReward
ITimeSkipReward is an IReward that grants the player their projected amount of ICurrency earnings based on the Duration specified. ITimeSkipRewards can only be claimed if there are IPayoutProjections, i.e. automated IGeneratorEntitys.
Inherited Members
Namespace: IdleKit.Gameplay
Assembly: cs.temp.dll.dll
Syntax
public interface ITimeSkipReward : IReward, IPayoutEntity, IEntity, IInjectable
Properties
TimeSkipRewardData
Returns the associated ITimeSkipRewardData.
Declaration
ITimeSkipRewardData TimeSkipRewardData { get; }
Property Value
Type | Description |
---|---|
ITimeSkipRewardData |
Methods
CalculateAndCacheRewards()
Calculates the CurrencyAmounts that this ITimeSkipReward will give and updates the cached value.
Declaration
CurrencyAmount[] CalculateAndCacheRewards()
Returns
Type | Description |
---|---|
CurrencyAmount[] |
Remarks
This should be called by the UI to get the CurrencyAmounts the user will receive when the reward is granted, and then CalculatePayouts() should give out the cached amount. This is to avoid the situation where the player sees the expected payout calculated when they select the time skip, but receives a smaller rewarded amount than expected. This could occur if a timed boost duration is less than this Duration. This opens up an exploit where the player could open the UI to get an expected payout with a timed boost active, wait till the boost duration is almost over, then receive this reward with the extra boosted payout. However, the problem from above outweighs this exploit.