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

Hey, guys! So I ran into a small problem :) Here is some code:

On client-side, I am getting "crash-reports" folder like this:

static File path = new File(Minecraft.getMinecraft().mcDataDir, "crash-reports");

I am getting crash-reports path on client-side. And now I need to get crash-reports folder on the server. I found this: 

static File path2 = new File(MinecraftServer.getServer().getDataDirectory(), "crash-reports");

But it says that it is protected. How can I fix/do that right? Thanks a lot in advance!

5 minutes ago, TheASTRO said:

MinecraftServer.getServer()

? What version are you on? This method has not been static since Mojang changed their threading stuff a while ago...

Please clarify what exactly is protected. The method? The folder?

  • Author
Just now, V0idWa1k3r said:

? What version are you on? This method has not been static since Mojang changed their threading stuff a while ago...

Please clarify what exactly is protected. The method? The folder?

The method getDataDirectory() from the type MinecraftServer is not visible

  • Author
1 minute ago, diesieben07 said:

Again, what version are you on? And why do you need the crash-reports folder? O.o

Oops, missed the question about the version.  It is 1.7.10 and I `ve created a mod, that scans, analyses and sends some raw data towards PHP. Just for admins to get crashes and fix them :) 

  • Guest locked this topic
Guest
This topic is now closed to further replies.

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.