Jump 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.

Featured Replies

Posted

The world in question is currently in a ZIP inside my JAR file. Is it possible to extract it and teleport the player to it? I've been thinking about extracting it to the saves folder, but I have no idea how to get the path to the player's .minecraft folder in-code.

Maybe you could generate a specific Dimension of the wanted world (or all) into the new World. How this could be done, no Idea. But you could have a look at different world-generator Mod sources. This helps me often when I'm modding

If my English is not perfect it is not my fault! It's the fault of my teacher, parents, friends and google translator!

You can get the world saves folder quite easily:

 

DimensionManager.getCurrentSaveRootDirectory();

That gives you the current world's folder, so one level up is the "saves" directory, and one level above that is the main ".minecraft" directory. As for unzipping it, the standard java.util.zip package contains the classes/methods you need to extract files.

 

Unloading the current world and loading the new one, though... that's beyond my scope of knowledge.

Whatever Minecraft needs, it is most likely not yet another tool tier.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

Important Information

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

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.