Interface IExchangeRateMultiplier
Allows an exchange rate to be calculated between two IExchangeable objects.
Namespace: IdleKit.Gameplay
Assembly: cs.temp.dll.dll
Syntax
public interface IExchangeRateMultiplier : IEntity, IInjectable
Properties
ExchangeRateMultiplierData
The data used by the IExchangeRateMultiplier entity.
Declaration
IExchangeRateMultiplierData ExchangeRateMultiplierData { get; }
Property Value
| Type | Description |
|---|---|
| IExchangeRateMultiplierData |
Methods
GetExchangeInputAmount(IExchangeable, IExchangeable, Double)
Calculates the required input amount to perform an exchange of the two different IExchangeable
objects that yields the requiredAmount.
Declaration
double GetExchangeInputAmount(IExchangeable inputExchangeable, IExchangeable outputExchangeable, double requiredAmount)
Parameters
| Type | Name | Description |
|---|---|---|
| IExchangeable | inputExchangeable | |
| IExchangeable | outputExchangeable | |
| Double | requiredAmount |
Returns
| Type | Description |
|---|---|
| Double |
GetRate(IExchangeable, IExchangeable)
Calculates an exchange rate based on the values of two different IExchangeable objects, taking into account Multiplier
Declaration
double GetRate(IExchangeable inputExchangeable, IExchangeable outputExchangeable)
Parameters
| Type | Name | Description |
|---|---|---|
| IExchangeable | inputExchangeable | |
| IExchangeable | outputExchangeable |
Returns
| Type | Description |
|---|---|
| Double | The value of |