Class StatChange

  • Direct Known Subclasses:
    RangeStatChange

    public class StatChange
    extends java.lang.Object
    A single stat change
    • Constructor Summary

      Constructors 
      Constructor Description
      StatChange()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected boolean canEqual​(java.lang.Object other)  
      boolean equals​(java.lang.Object o)  
      int getAbsolute()
      Absolute total of the stat after applying the boost.
      java.lang.String getFormattedRelative()
      Returns a human-readable formatted relative boost.
      java.lang.String getFormattedTheoretical()
      Returns a human-readable formatted theoretical boost.
      Positivity getPositivity()
      How beneficial this stat boost will be to the player.
      int getRelative()
      Relative change that will occur if the stat boost is applied now.
      Stat getStat()
      The stat which will be boosted (or damaged).
      int getTheoretical()
      Theoretical change that can occur before boost cap is enforced.
      int hashCode()  
      void setAbsolute​(int absolute)
      Absolute total of the stat after applying the boost.
      void setPositivity​(Positivity positivity)
      How beneficial this stat boost will be to the player.
      void setRelative​(int relative)
      Relative change that will occur if the stat boost is applied now.
      void setStat​(Stat stat)
      The stat which will be boosted (or damaged).
      void setTheoretical​(int theoretical)
      Theoretical change that can occur before boost cap is enforced.
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • StatChange

        public StatChange()
    • Method Detail

      • getFormattedRelative

        public java.lang.String getFormattedRelative()
        Returns a human-readable formatted relative boost. Should be the boost amount prefixed by "+" or "-".
        Returns:
        The formatted relative boost amount
      • getFormattedTheoretical

        public java.lang.String getFormattedTheoretical()
        Returns a human-readable formatted theoretical boost. Should be the boost amount prefixed by "+" or "-".
        Returns:
        The formatted theoretical boost amount
      • getStat

        public Stat getStat()
        The stat which will be boosted (or damaged).
      • getRelative

        public int getRelative()
        Relative change that will occur if the stat boost is applied now.
      • getTheoretical

        public int getTheoretical()
        Theoretical change that can occur before boost cap is enforced.
      • getAbsolute

        public int getAbsolute()
        Absolute total of the stat after applying the boost.
      • getPositivity

        public Positivity getPositivity()
        How beneficial this stat boost will be to the player.
      • setStat

        public void setStat​(Stat stat)
        The stat which will be boosted (or damaged).
      • setRelative

        public void setRelative​(int relative)
        Relative change that will occur if the stat boost is applied now.
      • setTheoretical

        public void setTheoretical​(int theoretical)
        Theoretical change that can occur before boost cap is enforced.
      • setAbsolute

        public void setAbsolute​(int absolute)
        Absolute total of the stat after applying the boost.
      • setPositivity

        public void setPositivity​(Positivity positivity)
        How beneficial this stat boost will be to the player.
      • equals

        public boolean equals​(java.lang.Object o)
        Overrides:
        equals in class java.lang.Object
      • canEqual

        protected boolean canEqual​(java.lang.Object other)
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object