Interface IResearchEffect

All Known Implementing Classes:
GlobalResearchEffect

public interface IResearchEffect
The effect of research.
  • Method Summary

    Modifier and Type
    Method
    Description
    double
    Get the absolute effect of the research.
    net.minecraft.resources.ResourceLocation
    Getter for the ID of the effect.
    net.minecraft.network.chat.contents.TranslatableContents
    Human-readable effect description, or a translation key.
    Get the ModResearchEffects.ResearchEffectEntry for this Research Effect.
    net.minecraft.network.chat.contents.TranslatableContents
    Human-readable effect subtitle description, or a translation key.
    boolean
    overrides(@NotNull IResearchEffect other)
    Does this effect override another effect with the same id?
    net.minecraft.nbt.CompoundTag
    Write the ResearchEffect's traits to NBT, to simplify serialization for client-viewable data.
  • Method Details

    • getRegistryEntry

      Get the ModResearchEffects.ResearchEffectEntry for this Research Effect.
      Returns:
      a registry entry.
    • getId

      net.minecraft.resources.ResourceLocation getId()
      Getter for the ID of the effect.
      Returns:
      the effect id as a ResourceLocation.
    • getName

      net.minecraft.network.chat.contents.TranslatableContents getName()
      Human-readable effect description, or a translation key.
      Returns:
      the desc.
    • getSubtitle

      net.minecraft.network.chat.contents.TranslatableContents getSubtitle()
      Human-readable effect subtitle description, or a translation key.
      Returns:
      the Subtitle desc.
    • getEffect

      double getEffect()
      Get the absolute effect of the research.
      Returns:
      the effect.
    • overrides

      boolean overrides(@NotNull @NotNull IResearchEffect other)
      Does this effect override another effect with the same id?
      Parameters:
      other - the effect to check.
      Returns:
      true if so, generally meaning a higher magnitude effect.
    • writeToNBT

      net.minecraft.nbt.CompoundTag writeToNBT()
      Write the ResearchEffect's traits to NBT, to simplify serialization for client-viewable data.
      Returns:
      an NBT file containing at least the necessary traits to reassemble user-visible traits of the effect.