Class Contaminant

java.lang.Object
com.petrolpark.contamination.Contaminant

public class Contaminant extends Object
  • Field Details

    • CODEC

      public static final com.mojang.serialization.Codec<Contaminant> CODEC
    • preservationProportion

      public final double preservationProportion
    • color

      public final int color
    • absentColor

      public final int absentColor
    • children

      protected Set<Contaminant> children
    • parents

      protected Set<Contaminant> parents
    • rl

      protected net.minecraft.resources.ResourceLocation rl
    • descriptionId

      protected String descriptionId
    • absentDescriptionId

      protected String absentDescriptionId
    • childrenView

      protected Set<Contaminant> childrenView
    • parentsView

      protected Set<Contaminant> parentsView
  • Constructor Details

    • Contaminant

      public Contaminant(double preservationProportion, int color, int absentColor, List<net.minecraft.resources.ResourceLocation> childResourceLocations)
  • Method Details

    • get

      public static Contaminant get(net.minecraft.resources.ResourceLocation resourceLocation)
    • getFromIntrinsicTag

      public static Contaminant getFromIntrinsicTag(net.minecraft.tags.TagKey<?> tagKey)
    • getFromShowIfAbsentTag

      public static Contaminant getFromShowIfAbsentTag(net.minecraft.tags.TagKey<?> tagKey)
    • getFromTag

      public static Contaminant getFromTag(net.minecraft.tags.TagKey<?> tagKey, String pathSuffix)
    • getPreservationProportion

      public double getPreservationProportion()
    • isPreserved

      public boolean isPreserved(double proportion)
    • getColor

      public int getColor()
    • getAbsentColor

      public int getAbsentColor()
    • getChildren

      public Set<Contaminant> getChildren()
      All Contaminants (not just direct children) which any Contamination automatically has if they have this Contaminant.
    • getParents

      public Set<Contaminant> getParents()
      Any Contaminants (not just direct parents) which, if a Contamination has, will also belong to that Contamination.
    • getLocation

      public net.minecraft.resources.ResourceLocation getLocation()
    • compareTo

      public int compareTo(Contaminant contaminant)
    • getName

      public net.minecraft.network.chat.Component getName()
    • getNameColored

      public net.minecraft.network.chat.Component getNameColored()
    • getAbsentName

      public net.minecraft.network.chat.Component getAbsentName()
    • getAbsentNameColored

      public net.minecraft.network.chat.Component getAbsentNameColored()