Record Class AddEntityToSameBiomesModifier

java.lang.Object
java.lang.Record
com.mrbysco.camocreepers.modifier.AddEntityToSameBiomesModifier
All Implemented Interfaces:
net.neoforged.neoforge.common.world.BiomeModifier

public record AddEntityToSameBiomesModifier(net.minecraft.world.entity.EntityType<?> originalType, net.minecraft.world.entity.EntityType<?> newType, int weight, int minGroup, int maxGroup) extends Record implements net.neoforged.neoforge.common.world.BiomeModifier
  • Nested Class Summary

    Nested classes/interfaces inherited from interface net.neoforged.neoforge.common.world.BiomeModifier

    net.neoforged.neoforge.common.world.BiomeModifier.Phase
  • Field Summary

    Fields inherited from interface net.neoforged.neoforge.common.world.BiomeModifier

    DIRECT_CODEC, LIST_CODEC, REFERENCE_CODEC
  • Constructor Summary

    Constructors
    Constructor
    Description
    AddEntityToSameBiomesModifier(net.minecraft.world.entity.EntityType<?> originalType, net.minecraft.world.entity.EntityType<?> newType, int weight, int minGroup, int maxGroup)
    Creates an instance of a AddEntityToSameBiomesModifier record class.
  • Method Summary

    Modifier and Type
    Method
    Description
    com.mojang.serialization.MapCodec<? extends net.neoforged.neoforge.common.world.BiomeModifier>
     
    final boolean
    Indicates whether some other object is "equal to" this one.
    final int
    Returns a hash code value for this object.
    int
    Returns the value of the maxGroup record component.
    int
    Returns the value of the minGroup record component.
    void
    modify(net.minecraft.core.Holder<net.minecraft.world.level.biome.Biome> biome, net.neoforged.neoforge.common.world.BiomeModifier.Phase phase, net.neoforged.neoforge.common.world.ModifiableBiomeInfo.BiomeInfo.Builder builder)
     
    net.minecraft.world.entity.EntityType<?>
    Returns the value of the newType record component.
    net.minecraft.world.entity.EntityType<?>
    Returns the value of the originalType record component.
    final String
    Returns a string representation of this record class.
    int
    Returns the value of the weight record component.

    Methods inherited from class Object

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

    • AddEntityToSameBiomesModifier

      public AddEntityToSameBiomesModifier(net.minecraft.world.entity.EntityType<?> originalType, net.minecraft.world.entity.EntityType<?> newType, int weight, int minGroup, int maxGroup)
      Creates an instance of a AddEntityToSameBiomesModifier record class.
      Parameters:
      originalType - the value for the originalType record component
      newType - the value for the newType record component
      weight - the value for the weight record component
      minGroup - the value for the minGroup record component
      maxGroup - the value for the maxGroup record component
  • Method Details

    • modify

      public void modify(net.minecraft.core.Holder<net.minecraft.world.level.biome.Biome> biome, net.neoforged.neoforge.common.world.BiomeModifier.Phase phase, net.neoforged.neoforge.common.world.ModifiableBiomeInfo.BiomeInfo.Builder builder)
      Specified by:
      modify in interface net.neoforged.neoforge.common.world.BiomeModifier
    • codec

      public com.mojang.serialization.MapCodec<? extends net.neoforged.neoforge.common.world.BiomeModifier> codec()
      Specified by:
      codec in interface net.neoforged.neoforge.common.world.BiomeModifier
    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared with Objects::equals(Object,Object); primitive components are compared with the compare method from their corresponding wrapper classes.
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • originalType

      public net.minecraft.world.entity.EntityType<?> originalType()
      Returns the value of the originalType record component.
      Returns:
      the value of the originalType record component
    • newType

      public net.minecraft.world.entity.EntityType<?> newType()
      Returns the value of the newType record component.
      Returns:
      the value of the newType record component
    • weight

      public int weight()
      Returns the value of the weight record component.
      Returns:
      the value of the weight record component
    • minGroup

      public int minGroup()
      Returns the value of the minGroup record component.
      Returns:
      the value of the minGroup record component
    • maxGroup

      public int maxGroup()
      Returns the value of the maxGroup record component.
      Returns:
      the value of the maxGroup record component