Class ValueShifterUtil

java.lang.Object
com.fs.starfarer.api.util.ValueShifterUtil
All Implemented Interfaces:
ValueShifterAPI

public class ValueShifterUtil extends Object implements ValueShifterAPI
  • Field Details

    • base

      protected float base
    • curr

      protected float curr
    • useSquareOfProgress

      protected boolean useSquareOfProgress
    • averageShift

      protected transient float averageShift
    • data

  • Constructor Details

    • ValueShifterUtil

      public ValueShifterUtil(float base)
  • Method Details

    • isUseSquareOfProgress

      public boolean isUseSquareOfProgress()
    • setUseSquareOfProgress

      public void setUseSquareOfProgress(boolean useSquareOfProgress)
    • isShifted

      public boolean isShifted()
    • getBase

      public float getBase()
      Specified by:
      getBase in interface ValueShifterAPI
    • setBase

      public void setBase(float base)
      Specified by:
      setBase in interface ValueShifterAPI
    • getCurr

      public float getCurr()
      Specified by:
      getCurr in interface ValueShifterAPI
    • shift

      public void shift(Object source, float to, float durIn, float durOut, float shift)
      Description copied from interface: ValueShifterAPI
      Durations are in seconds, NOT days.
      Specified by:
      shift in interface ValueShifterAPI
    • advance

      public void advance(float amount)
      Specified by:
      advance in interface ValueShifterAPI
    • updateCurr

      protected void updateCurr()
    • getAverageShift

      public float getAverageShift()
    • getShiftProgress

      public float getShiftProgress(Object key)
    • main

      public static void main(String[] args)