Class NeoForgePlatformHelper

java.lang.Object
com.mrbysco.lunar.platform.NeoForgePlatformHelper
All Implemented Interfaces:
IPlatformHelper

public class NeoForgePlatformHelper extends Object implements IPlatformHelper
  • Constructor Details

    • NeoForgePlatformHelper

      public NeoForgePlatformHelper()
  • Method Details

    • syncEvent

      public void syncEvent(net.minecraft.world.level.Level level, ILunarEvent event)
      Description copied from interface: IPlatformHelper
      Syncing the lunar event to the clients.
      Specified by:
      syncEvent in interface IPlatformHelper
      Parameters:
      level - The level to get the players from
      event - The event that gets synced
    • syncEvent

      public void syncEvent(net.minecraft.server.level.ServerPlayer player, ILunarEvent event)
      Description copied from interface: IPlatformHelper
      Syncing the lunar event to a specific client.
      Specified by:
      syncEvent in interface IPlatformHelper
      Parameters:
      player - The player it gets synced to
      event - The event that gets synced
    • getLunarChance

      public float getLunarChance()
      Description copied from interface: IPlatformHelper
      Returns the configured chance of a Lunar Event happening.
      Specified by:
      getLunarChance in interface IPlatformHelper
      Returns:
      the Lunar Event Chance
    • getBloodMoonWeight

      public int getBloodMoonWeight()
      Description copied from interface: IPlatformHelper
      Returns the configured weight of the Blood Moon event.
      Specified by:
      getBloodMoonWeight in interface IPlatformHelper
      Returns:
      the Blood Moon Weight
    • getCrimsonMoonWeight

      public int getCrimsonMoonWeight()
      Description copied from interface: IPlatformHelper
      Returns the configured weight of the Crimson Moon event.
      Specified by:
      getCrimsonMoonWeight in interface IPlatformHelper
      Returns:
      the Crimson Moon Weight
    • getMinerMoonWeight

      public int getMinerMoonWeight()
      Description copied from interface: IPlatformHelper
      Returns the configured weight of the Miner Moon event.
      Specified by:
      getMinerMoonWeight in interface IPlatformHelper
      Returns:
      the Miner Moon Weight
    • getWhiteMoonWeight

      public int getWhiteMoonWeight()
      Description copied from interface: IPlatformHelper
      Returns the configured weight of the White Moon event.
      Specified by:
      getWhiteMoonWeight in interface IPlatformHelper
      Returns:
      the White Moon Weight
    • getBigMoonWeight

      public int getBigMoonWeight()
      Description copied from interface: IPlatformHelper
      Returns the configured weight of the Big Moon event.
      Specified by:
      getBigMoonWeight in interface IPlatformHelper
      Returns:
      the Big Moon Weight
    • getTinyMoonWeight

      public int getTinyMoonWeight()
      Description copied from interface: IPlatformHelper
      Returns the configured weight of the Tiny Moon event.
      Specified by:
      getTinyMoonWeight in interface IPlatformHelper
      Returns:
      the Tiny Moon Weight
    • getBadOmenMoonWeight

      public int getBadOmenMoonWeight()
      Description copied from interface: IPlatformHelper
      Returns the configured weight of the Bad Omen Moon event.
      Specified by:
      getBadOmenMoonWeight in interface IPlatformHelper
      Returns:
      the Bad Omen Moon Weight
    • getHeroMoonWeight

      public int getHeroMoonWeight()
      Description copied from interface: IPlatformHelper
      Returns the configured weight of the Hero Moon event.
      Specified by:
      getHeroMoonWeight in interface IPlatformHelper
      Returns:
      the Hero Moon Weight
    • getEclipseMoonWeight

      public int getEclipseMoonWeight()
      Description copied from interface: IPlatformHelper
      Returns the configured weight of the Eclipse Moon event.
      Specified by:
      getEclipseMoonWeight in interface IPlatformHelper
      Returns:
      the Eclipse Moon Weight
    • getCrimsonReplacementMap

      public Map<net.minecraft.resources.ResourceLocation,net.minecraft.resources.ResourceLocation> getCrimsonReplacementMap()
      Description copied from interface: IPlatformHelper
      Returns the configured Crimson Replacement Map to be used during the Crimson Moon event
      Specified by:
      getCrimsonReplacementMap in interface IPlatformHelper
      Returns:
      the configured Crimson Replacement Map.
    • canSleepIn

      public boolean canSleepIn(net.minecraft.resources.ResourceLocation moonID)
      Description copied from interface: IPlatformHelper
      Checks if sleeping is allowed during the given moon event.
      Specified by:
      canSleepIn in interface IPlatformHelper
      Parameters:
      moonID - the moon event to check
      Returns:
      true if sleeping is allowed, false otherwise