Skip to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

warjort

Members
  • Joined

  • Last visited

Everything posted by warjort

  1. level.getRawBrightness(blockPos, 0) This gives you the max of the block light and the sky light. It's what gets used by vanilla for things like mob spawning or crop growth. Replace blockPos with blockPos.above() if your block does not let light through it.
  2. You are missing auto reg lib.: https://www.curseforge.com/minecraft/mc-mods/autoreglib
  3. You are going to find this very difficult. The issue is this: https://minecraft.fandom.com/wiki/Java_Edition_1.13/Flattening You can see how vanilla deals with it in for example BlockStateFlatteningFix/BlockStateFlattening but there are may other similar fixes for items, entities, block/tile entities, falling blocks, etc. See net.minecraft.datafixer.Schemas.build() where the flattening is around schema version 1451 You are going to have a number of issues (this is not a complete list): * The only real way for you to plugin into Mojang's mechanism AFAIK is to use byte code weaving * The numeric ids you have aren't guaranteed to be those used in real worlds. In 1.12 mods could conflict in their requested ids and so forge had to choose one of them to be a different number and remember the change in the world save folder * Mods would often accidently have "id shifts" where the numeric id changed across releases and so different worlds could have different ids depending which mod version they used. * A lot of 1.12 worlds (big mod packs) had issues with the 65535 numeric limit and so used mods like this to workaround it: https://www.curseforge.com/minecraft/mc-mods/jeid. While this used a format similar to 1.13 it isn't really the 1.13 format * Depending upon what your mod does, the task may be "impossible" for other reasons, e.g. there are known problems for updating modded worlds even in recent versions because of the way Mojang keeps changing the worldgen, structures being a notable problem.
  4. Your block -> ingots recipe should be minecraft:crafting_shapeless, that is the json formatting you are using. and you need separate recipes for the smelting recipe or use an item tag i.e. if this really did take multiple items (which it does not) it would be an array instead of a structure "ingredient": { "item": "denmod:ruby_ore", "item": "denmod:deepslate_ruby_ore" },
  5. The short answer is you probably can't in general because it will depend on if/how mods modify the sky rendering. Assuming vanilla rendering, try this which (I think?) shows the player's view vector and a calculation of the vector to the sun at the top of the screen. @Mod.EventBusSubscriber(modid = MODID, bus = Bus.MOD, value = Dist.CLIENT) public class ModClientEvents { @SubscribeEvent public static void registerOverlay(RegisterGuiOverlaysEvent event) { event.registerAboveAll("view_sun", (gui, poseStack, partialTick, screenWidth, screenHeight) -> { Minecraft minecraft = Minecraft.getInstance(); Entity entity = minecraft.cameraEntity; Level level = minecraft.level; float sunAngle = level.getSunAngle(partialTick) + (float) Math.PI / 2; // use -pi/2 for the moon Vec3 view = entity.getViewVector(1.0f); Vec3 sun = new Vec3(Math.cos(sunAngle), Math.sin(sunAngle), 0f); String msg = String.format(Locale.ROOT, "%.3f / %.3f / %.3f / %.3f / %.3f / %.3f / %.3f", sunAngle, view.x, view.y, view.z, sun.x, sun.y, sun.z); gui.setupOverlayRenderState(true, false, null); Font font = minecraft.font; GuiComponent.fill(poseStack, 1, 1, 3 + font.width(msg), 1 + font.lineHeight, 0x6FAFAFB0); font.draw(poseStack, msg, 2, 2, 0xE0E0E0); }); } } You can probably use this as a starting point of your calculation to see if the 2 vector's components are close in value, or maybe something more complicated (e.g. taking into account moon phases). I would guess you also want to do some kind of ray trace - entity.pick() - to see if there is a block/fluid or entity blocking the sun, and also check the weather. 🙂
  6. I can see your mod getting loaded: This says you either need to have cheat mode (or op for a server) to use the command. https://github.com/GeheimagentNr1/DimensionTeleport/blob/745206adf2b749d27d50664cb181224a6fe59595/src/main/java/de/geheimagentnr1/dimensionteleport/elements/commands/dimension_teleport/DimensionTeleportCommand.java#L40
  7. And this version of optifine doesn't work with your version of forge. You need the latest preview: https://github.com/sp614x/optifine/issues/7009#issuecomment-1228057896
  8. Caused by: org.spongepowered.asm.mixin.injection.throwables.InvalidInjectionException: Critical injection failure: @ModifyVariable annotation on valhelsia_renderModelFaceFlat could not find any targets matching 'Lnet/minecraft/client/renderer/block/ModelBlockRenderer;m_111001_(Lnet/minecraft/world/level/BlockAndTintGetter;Lnet/minecraft/world/level/block/state/BlockState;Lnet/minecraft/core/BlockPos;IIZLcom/mojang/blaze3d/vertex/PoseStack;Lcom/mojang/blaze3d/vertex/VertexConsumer;Ljava/util/List;Ljava/util/BitSet;)V' in net.minecraft.client.renderer.block.ModelBlockRenderer. Using refmap valhelsia_core.refmap.json [PREINJECT Applicator Phase -> valhelsia_core.mixins.json:client.ModelBlockRendererMixin -> Prepare Injections -> -> localvar$blj000$valhelsia_renderModelFaceFlat(ILnet/minecraft/world/level/BlockAndTintGetter;Lnet/minecraft/world/level/block/state/BlockState;Lnet/minecraft/core/BlockPos;)I -> Parse] This is valhelsia core. It is probably conflicting with another mod doing the same thing? Make sure you have the latest version then contact the mod author.
  9. I don't advise you to downgrade. That will be a "ten times" more difficult task than trying to find compatible mods with the latest versions. You should just remove the mods if the mod authors are not updating their mods. That is unless there is a reason why you can't do that, e.g. you have an existing world that uses the mod's blocks in your builds.
  10. BTW: Please don't paste logs into the forums. That makes it difficult to search and the log you are posting is not the debug.log so it doesn't have all information.
  11. [29Aug2022 17:12:03.332] [Worker-Main-3/ERROR] [net.minecraftforge.fml.javafmlmod.FMLModContainer/]: Exception caught during firing event: GOGGLES Index: 1 Listeners: 0: NORMAL 1: net.minecraftforge.eventbus.EventBus$$Lambda$3063/0x0000000800c3f0d0@32a371b5 java.lang.NoSuchFieldError: GOGGLES at TRANSFORMER/[email protected]/com.luis.createcurios.goggle.Render.register(Render.java:14) This is this error: https://forums.minecraftforge.net/topic/115979-create-curios-createcurios-encountered-an-error-during-the-sided_setup-event-phase-javalangnosuchfielderror-goggles/#comment-512597
  12. https://docs.minecraftforge.net/en/latest/items/#advanced-items If you still don't understand, you should find something that helps you learn java. This is basic stuff.
  13. There is no Item.getRegistryName() in 1.18 Anyway, you added your method to a random class. You need to make your own custom Item class for this. You can't use the generic "new Item()" public class MyItem extends Item { public MyItem(Properties p_41383_) { super(p_41383_); } @Override public boolean onEntityItemUpdate(ItemStack stack, ItemEntity entity) { // etc.
  14. Please don't paste text as images. Which version is this? https://forums.minecraftforge.net/topic/91712-supported-version-directory/
  15. You don't post this. It will be in the same place as where you downloaded the installer jar. The error is usually caused by having an old version of java, make sure you have it updated to a recent version. It can also be caused by broken entries in your operating system's hosts file.
  16. You should also note, that this method is called on both the client and the server. Depending upon what processing you want to do, you will need to check entity.level.isClientSide
  17. In your Item class implementation.
  18. You seem to have fixed the placebo problem? Your problem now is you have createaddition which wants a version 1.18-0.6.x but the version of flywheel is 0.6.5 with no "1.18-" You need to talk to the mod author about this.
  19. If it's your own item you can override IForgeItem.onEntityItemUpdate() for your item and do whatever you like. e.g. @Override public boolean onEntityItemUpdate(ItemStack stack, ItemEntity entity) { if (entity.isInWater()) { // Do stuff } return false; }
  20. Can you post your logs/debug.log so we can see what mods you actually have. It still says you have the wrong version of flywheel and placebo. This probably means you have mods that want conflicting versions of these mods. You also installed forge-40.1.68 which is not the latest version, 40.1.74, but I don't think that is causing this problem.
  21. You also have 3 mods that are not compatible with forge 40.1.59, you should try the latest version 40.1.74 And you are probably missing placebo or have a mod that wants a different version of placebo to what you have installed.
  22. Something is misconfigured. It is using 1.19 mod loader but with forge/minecraft 1.18 [23:49:58] [main/INFO] [cp.mo.mo.Launcher/MODLAUNCHER]: ModLauncher running: args [--launchTarget, forgeclientuserdev, --version, MOD_DEV, --assetIndex, 1.18, --assetsDir, C:\Users\Nick\.gradle\caches\forge_gradle\assets, --gameDir, ., --fml.forgeVersion, 40.0.40, --fml.mcVersion, 1.18.2, --fml.forgeGroup, net.minecraftforge, --fml.mcpVersion, 20220404.173914, -mixin.config=reignofnether.mixins.json] [23:49:58] [main/INFO] [cp.mo.mo.Launcher/MODLAUNCHER]: ModLauncher 10.0.8+10.0.8+main.0ef7e830 starting: java version 17.0.2 by Eclipse Adoptium; OS Windows 10 arch amd64 version 10.0 How are you launching this? If it is from inside intellij check your launch configs to see if they make sense. You should also try reloading/importing the project into your ide to make it is not using old/cached information somewhere. If that fails, you will probably need to put your project on github so we can look at it in more detail.
  23. Mod File: /home/falxie_/.local/share/PolyMC/instances/Construct/.minecraft/mods/Chimes-1.1.2-1.18.2.jar Failure message: Chimes (chimes) has failed to load correctly java.lang.reflect.InvocationTargetException: null Mod Version: 1.1.2 Mod Issue URL: NOT PROVIDED Exception message: java.util.ConcurrentModificationException Stacktrace: at java.util.HashMap$HashIterator.nextNode(HashMap.java:1597) ~[?:?] {} at java.util.HashMap$EntryIterator.next(HashMap.java:1630) ~[?:?] {} at java.util.HashMap$EntryIterator.next(HashMap.java:1628) ~[?:?] {} at net.minecraftforge.common.ForgeConfigSpec.correct(ForgeConfigSpec.java:251) ~[forge-1.18.2-40.1.73-universal.jar%23214!/:?] {re:classloading} at net.minecraftforge.common.ForgeConfigSpec.isCorrect(ForgeConfigSpec.java:146) ~[forge-1.18.2-40.1.73-universal.jar%23214!/:?] {re:classloading} at net.minecraftforge.common.ForgeConfigSpec.setConfig(ForgeConfigSpec.java:83) ~[forge-1.18.2-40.1.73-universal.jar%23214!/:?] {re:classloading} at com.nick.chimes.client.ChimesSettings.<clinit>(ChimesSettings.java:34) ~[Chimes-1.1.2-1.18.2.jar%2388!/:1.0] {re:classloading} at com.nick.chimes.Chimes.<init>(Chimes.java:61) ~[Chimes-1.1.2-1.18.2.jar%2388!/:1.0] {re:classloading} Looks like an issue with chimes doing something strange with its config in its mod class initialisation. Check you have the latest version then contact the mod author.
  24. Posting your logs/debug.log might give more information?

Important Information

By using this site, you agree to our Terms of Use.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.