Jump to content

Recommended Posts

Posted

Hello All,

I'm running my own Minecraft server. I installed forge-1.7.2-10.12.0.976 using the jar installer however when I now click on forge-1.7.2-10.12.0.976-universal.jar it does not open. Did I do something wrong?

 

I guess I should say the server I'm running on is a computer I have here at my home. It's running Windows 7 64 bit. Not sure what else I can say to help get an answer. Just let me know if you have further questions.

Posted

Log is empty. I cleared the log and tried running the jar file and the log file remained blank. Now I'm running the file in the path C:\minecraft server\1.7.2. The log I looked at was latest.log in the logs folder. and I don't see a forge log file unless it is not stored in the C:\minecraft server folder.

Posted

OK, did that and looks like I'm missing libraries to run forge?

 

 

Exception in thread "main" java.lang.NoClassDefFoundError: joptsimple/OptionSpec

 

        at java.lang.Class.forName0(Native Method)

        at java.lang.Class.forName(Unknown Source)

        at cpw.mods.fml.relauncher.ServerLaunchWrapper.run(ServerLaunchWrapper.j

ava:25)

        at cpw.mods.fml.relauncher.ServerLaunchWrapper.main(ServerLaunchWrapper.

java:12)

Caused by: java.lang.ClassNotFoundException: joptsimple.OptionSpec

        at java.net.URLClassLoader$1.run(Unknown Source)

        at java.net.URLClassLoader$1.run(Unknown Source)

        at java.security.AccessController.doPrivileged(Native Method)

        at java.net.URLClassLoader.findClass(Unknown Source)

        at java.lang.ClassLoader.loadClass(Unknown Source)

        at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)

        at java.lang.ClassLoader.loadClass(Unknown Source)

        ... 4 more

 

Posted

Make sure that the minecraft server jar is named: 'minecraft_server.1.7.2.jar' exactly in the same folder as Forge's jar.

I do Forge for free, however the servers to run it arn't free, so anything is appreciated.
Consider supporting the team on Patreon

Posted

Yes it is. I even tried renaming my 1.7.2 folder, recreatign it, redownloading 1.7.2 jar from https://s3.amazonaws.com/Minecraft.Download/versions/1.7.2/minecraft_server.1.7.2.jar and then downloading the newest release of forge and copying that jar to the 1.7.2 folder. The minecraft_server.1.7.2.jar runs no problem and I can log in to it from my client side computer. However Forge is still not launching.

Posted

Same error, the only log file produced is the "latest.log" from the vanilla server.  I can't get IE or Chrome to upload it here for some reason so I'll paste its' contents at the bottom.

 

What I ran:

 

 

PS C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft> java -Xmx1G -Xms1G -jar .\forge-1.7.2-10.12.0.976-universal.jar nogui
Exception in thread "main" java.lang.NoClassDefFoundError: joptsimple/OptionSpec
        at java.lang.Class.forName0(Native Method)
        at java.lang.Class.forName(Unknown Source)
        at cpw.mods.fml.relauncher.ServerLaunchWrapper.run(ServerLaunchWrapper.java:25)
        at cpw.mods.fml.relauncher.ServerLaunchWrapper.main(ServerLaunchWrapper.java:12)
Caused by: java.lang.ClassNotFoundException: joptsimple.OptionSpec
        at java.net.URLClassLoader$1.run(Unknown Source)
        at java.net.URLClassLoader$1.run(Unknown Source)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(Unknown Source)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        ... 4 more
PS C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft>

 

 

 

Folder contents:

 

 

.minecraft folder contents:

 

PS C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft> dir

    Directory: C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft

Mode                LastWriteTime     Length Name
----                -------------     ------ ----
d----          1/1/2014  11:34 PM            libraries
d----          1/2/2014  12:08 AM            logs
d----          1/2/2014  12:09 AM            world
-a---          1/2/2014  12:08 AM        110 banned-ips.txt
-a---          1/2/2014  12:08 AM        110 banned-players.txt
-a---          1/1/2014  11:35 PM    2108271 forge-1.7.2-10.12.0.976-universal.jar
-a---          1/1/2014  11:34 PM    9163955 minecraft_server.1.7.2.jar
-a---          1/2/2014  12:08 AM          0 ops.txt
-a---          1/2/2014  12:09 AM        658 server.properties
-a---          1/2/2014  12:08 AM          0 white-list.txt

 

 

The libraries folder only contains:

 

PS C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft> dir .\libraries\net\minecraft\launchwrapper\1.9

    Directory: C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft\libraries\net\minecraft\launchwrapper\1.9

Mode                LastWriteTime     Length Name
----                -------------     ------ ----
-a---          1/1/2014  11:34 PM      33162 launchwrapper-1.9.jar

 

.. plus

 

PS C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft> dir .\libraries\org\ow2\asm\asm-all\4.1

    Directory: C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft\libraries\org\ow2\asm\asm-all\4.1

Mode                LastWriteTime     Length Name
----                -------------     ------ ----
-a---          1/1/2014  11:34 PM     214592 asm-all-4.1.jar

 

.. plus

 

PS C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft> dir .\libraries\org\scala-lang\scala-compiler\2.10.2

    Directory: C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft\libraries\org\scala-lang\scala-compiler\2.10.2

Mode                LastWriteTime     Length Name
----                -------------     ------ ----
-a---          1/1/2014  11:35 PM   14541812 scala-compiler-2.10.2.jar

 

.. and

 

PS C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft> dir .\libraries\org\scala-lang\scala-library\2.10.2

    Directory: C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft\libraries\org\scala-lang\scala-library\2.10.2

Mode                LastWriteTime     Length Name
----                -------------     ------ ----
-a---          1/1/2014  11:34 PM    7218347 scala-library-2.10.2.jar

 

 

The World folder contains:

 

PS C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft> dir world

    Directory: C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft\world

Mode                LastWriteTime     Length Name
----                -------------     ------ ----
d----          1/2/2014  12:08 AM            data
d----          1/2/2014  12:08 AM            DIM-1
d----          1/2/2014  12:08 AM            DIM1
d----          1/2/2014  12:08 AM            players
d----          1/2/2014  12:08 AM            region
-a---          1/2/2014  12:09 AM        411 level.dat
-a---          1/2/2014  12:09 AM        411 level.dat_old
-a---          1/2/2014  12:08 AM          8 session.lock

 

 

I have a hunch you don't care what's in the sub folders under world but let me know if you do.

 

 

I've tried 9.76, 9.81 and 9.82: same error.  I've used the jar installer and the Win installer.  I've been pointing the installers at empty folders and letting the installer download the server jar as well as the forge jar.  My server is Windows 2012 SP1 running Java 7 r45 w/ 32 and 64 bit variants installed.  I run the minecraft server once before running forge.  The server runs fine and my client can connect to it.  When I run the forge jar using the java command shown above I get the output above.  I've been running Forge servers for about a year-ish now.  (since about 1.32-ish of MC)

 

Thanks for your attention!

 

 

Latest.log contents:

 

 

[00:08:55] [server thread/INFO]: Starting minecraft server version 1.7.2
[00:08:55] [server thread/INFO]: Loading properties
[00:08:55] [server thread/INFO]: Default game type: SURVIVAL
[00:08:55] [server thread/INFO]: Generating keypair
[00:08:56] [server thread/INFO]: Starting Minecraft server on *:25566
[00:08:56] [server thread/WARN]: Failed to load operators list: java.io.FileNotFoundException: .\ops.txt (The system cannot find the file specified)
[00:08:56] [server thread/WARN]: Failed to load white-list: java.io.FileNotFoundException: .\white-list.txt (The system cannot find the file specified)
[00:08:56] [server thread/INFO]: Preparing level "world"
[00:08:57] [server thread/INFO]: Preparing start region for level 0
[00:08:58] [server thread/INFO]: Preparing spawn area: 2%
[00:08:59] [server thread/INFO]: Preparing spawn area: 4%
[00:09:00] [server thread/INFO]: Preparing spawn area: 7%
[00:09:01] [server thread/INFO]: Preparing spawn area: 8%
[00:09:02] [server thread/INFO]: Preparing spawn area: 11%
[00:09:03] [server thread/INFO]: Preparing spawn area: 16%
[00:09:05] [server thread/INFO]: Preparing spawn area: 19%
[00:09:06] [server thread/INFO]: Preparing spawn area: 21%
[00:09:07] [server thread/INFO]: Preparing spawn area: 26%
[00:09:08] [server thread/INFO]: Preparing spawn area: 31%
[00:09:09] [server thread/INFO]: Preparing spawn area: 35%
[00:09:10] [server thread/INFO]: Preparing spawn area: 39%
[00:09:11] [server thread/INFO]: Preparing spawn area: 43%
[00:09:12] [server thread/INFO]: Preparing spawn area: 46%
[00:09:13] [server thread/INFO]: Preparing spawn area: 48%
[00:09:14] [server thread/INFO]: Preparing spawn area: 53%
[00:09:15] [server thread/INFO]: Preparing spawn area: 58%
[00:09:16] [server thread/INFO]: Preparing spawn area: 63%
[00:09:17] [server thread/INFO]: Preparing spawn area: 67%
[00:09:19] [server thread/INFO]: Preparing spawn area: 72%
[00:09:20] [server thread/INFO]: Preparing spawn area: 74%
[00:09:21] [server thread/INFO]: Preparing spawn area: 78%
[00:09:22] [server thread/INFO]: Preparing spawn area: 83%
[00:09:23] [server thread/INFO]: Preparing spawn area: 88%
[00:09:24] [server thread/INFO]: Preparing spawn area: 91%
[00:09:26] [server thread/INFO]: Preparing spawn area: 94%
[00:09:27] [server thread/INFO]: Preparing spawn area: 99%
[00:09:27] [server thread/INFO]: Done (30.633s)! For help, type "help" or "?"
[00:09:42] [server thread/INFO]: Stopping the server
[00:09:42] [server thread/INFO]: Stopping server
[00:09:42] [server thread/INFO]: Saving players
[00:09:42] [server thread/INFO]: Saving worlds
[00:09:42] [server thread/INFO]: Saving chunks for level 'world'/Overworld
[00:09:42] [server thread/INFO]: Saving chunks for level 'world'/Nether
[00:09:42] [server thread/INFO]: Saving chunks for level 'world'/The End

 

Posted

https://github.com/MinecraftForge/ForgeGradle/commit/76e15702b3e5554c78431f6bd3ef1237d96b9abf#diff-f41c2684049bbd8087a600e914f92586R293

Apparently, it was broken for the first few builds.

Just run with java -cp minecraft_server.1.7.2.jar -jar {forgejar}

That'll work untill the next build which will have the fixed path.

I do Forge for free, however the servers to run it arn't free, so anything is appreciated.
Consider supporting the team on Patreon

Posted

https://github.com/MinecraftForge/ForgeGradle/commit/76e15702b3e5554c78431f6bd3ef1237d96b9abf#diff-f41c2684049bbd8087a600e914f92586R293

Apparently, it was broken for the first few builds.

Just run with java -cp minecraft_server.1.7.2.jar -jar {forgejar}

That'll work untill the next build which will have the fixed path.

 

Ran it fleshed out with what I think you intended to be filled in and got the same output:

 

PS C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft> java -Xmx1G -Xms1G -cp .\minecraft_server.1.7.2.jar -jar .\forge-1.7.2-10.12.0.976-universal.jar nogui
Exception in thread "main" java.lang.NoClassDefFoundError: joptsimple/OptionSpec
        at java.lang.Class.forName0(Native Method)
        at java.lang.Class.forName(Unknown Source)
        at cpw.mods.fml.relauncher.ServerLaunchWrapper.run(ServerLaunchWrapper.java:25)
        at cpw.mods.fml.relauncher.ServerLaunchWrapper.main(ServerLaunchWrapper.java:12)
Caused by: java.lang.ClassNotFoundException: joptsimple.OptionSpec
        at java.net.URLClassLoader$1.run(Unknown Source)
        at java.net.URLClassLoader$1.run(Unknown Source)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(Unknown Source)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        ... 4 more
PS C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft>

 

There are no new logs under "/logs" and no Forge output.

Posted

Getting the same thing with Forge 982.

 

Noted when I ran the vanilla 1.7.2 server (which spawned fine), I waited for the server to completely generate the world and idle..  I typed "stop" to shut it down cleanly and allow me to run Forge and I was greeted with this shut down "appender" error:  (look at the end of the boot log pasted below)

 

PS C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft> java -jar .\minecraft_server.1.7.2.jar nogui
[17:48:51] [server thread/INFO]: Starting minecraft server version 1.7.2
[17:48:51] [server thread/INFO]: Loading properties
[17:48:51] [server thread/INFO]: Default game type: SURVIVAL
[17:48:51] [server thread/INFO]: Generating keypair
[17:48:51] [server thread/INFO]: Starting Minecraft server on *:25566
[17:48:52] [server thread/WARN]: Failed to load operators list: java.io.FileNotFoundException: .\ops.txt (The system ca
not find the file specified)
[17:48:52] [server thread/WARN]: Failed to load white-list: java.io.FileNotFoundException: .\white-list.txt (The system
cannot find the file specified)
[17:48:52] [server thread/INFO]: Preparing level "world"
[17:48:53] [server thread/INFO]: Preparing start region for level 0
[17:48:54] [server thread/INFO]: Preparing spawn area: 2%
[17:48:55] [server thread/INFO]: Preparing spawn area: 5%
[17:48:56] [server thread/INFO]: Preparing spawn area: 6%
[17:48:57] [server thread/INFO]: Preparing spawn area: 10%
[17:48:58] [server thread/INFO]: Preparing spawn area: 13%
[17:48:59] [server thread/INFO]: Preparing spawn area: 16%
[17:49:00] [server thread/INFO]: Preparing spawn area: 20%
[17:49:01] [server thread/INFO]: Preparing spawn area: 22%
[17:49:02] [server thread/INFO]: Preparing spawn area: 26%
[17:49:03] [server thread/INFO]: Preparing spawn area: 30%
[17:49:04] [server thread/INFO]: Preparing spawn area: 35%
[17:49:05] [server thread/INFO]: Preparing spawn area: 43%
[17:49:06] [server thread/INFO]: Preparing spawn area: 47%
[17:49:07] [server thread/INFO]: Preparing spawn area: 53%
[17:49:09] [server thread/INFO]: Preparing spawn area: 58%
[17:49:10] [server thread/INFO]: Preparing spawn area: 64%
[17:49:11] [server thread/INFO]: Preparing spawn area: 67%
[17:49:12] [server thread/INFO]: Preparing spawn area: 73%
[17:49:13] [server thread/INFO]: Preparing spawn area: 74%
[17:49:15] [server thread/INFO]: Preparing spawn area: 77%
[17:49:16] [server thread/INFO]: Preparing spawn area: 82%
[17:49:18] [server thread/INFO]: Preparing spawn area: 83%
[17:49:19] [server thread/INFO]: Preparing spawn area: 87%
[17:49:20] [server thread/INFO]: Preparing spawn area: 92%
[17:49:21] [server thread/INFO]: Preparing spawn area: 97%
[17:49:21] [server thread/INFO]: Done (29.532s)! For help, type "help" or "?"
list
[17:49:28] [server thread/INFO]: There are 0/20 players online:
[17:49:28] [server thread/INFO]:
stop
[17:49:30] [server thread/INFO]: Stopping the server
[17:49:30] [server thread/INFO]: Stopping server
[17:49:30] [server thread/INFO]: Saving players
[17:49:30] [server thread/INFO]: Saving worlds
[17:49:30] [server thread/INFO]: Saving chunks for level 'world'/Overworld
[17:49:31] [server thread/INFO]: Saving chunks for level 'world'/Nether
[17:49:31] [server thread/INFO]: Saving chunks for level 'world'/The End
[17:49:34] [server Shutdown Thread/INFO]: Stopping server
2014-01-02 17:49:34,236 ERROR Attempted to append to non-started appender ServerGuiConsole
Exception in thread "Server Shutdown Thread" org.apache.logging.log4j.core.appender.AppenderLoggingException: Attempted
to append to non-started appender ServerGuiConsole
        at org.apache.logging.log4j.core.config.AppenderControl.callAppender(AppenderControl.java:89)
        at org.apache.logging.log4j.core.config.LoggerConfig.callAppenders(LoggerConfig.java:425)
        at org.apache.logging.log4j.core.config.LoggerConfig.log(LoggerConfig.java:406)
        at org.apache.logging.log4j.core.config.LoggerConfig.log(LoggerConfig.java:367)
        at org.apache.logging.log4j.core.Logger.log(Logger.java:110)
        at org.apache.logging.log4j.spi.AbstractLogger.info(AbstractLogger.java:1011)
        at net.minecraft.server.MinecraftServer.n(SourceFile:287)

 

Posted

Seems to still be an issue with 10.12.0.985

 

 

 

PS E:\asd> java -jar .\forge-1.7.2-10.12.0.985-universal.jar

Exception in thread "main" java.lang.NoClassDefFoundError: joptsimple/OptionSpec

        at java.lang.Class.forName0(Native Method)

        at java.lang.Class.forName(Unknown Source)

        at cpw.mods.fml.relauncher.ServerLaunchWrapper.run(ServerLaunchWrapper.java:25)

        at cpw.mods.fml.relauncher.ServerLaunchWrapper.main(ServerLaunchWrapper.java:12)

Caused by: java.lang.ClassNotFoundException: joptsimple.OptionSpec

        at java.net.URLClassLoader$1.run(Unknown Source)

        at java.net.URLClassLoader$1.run(Unknown Source)

        at java.security.AccessController.doPrivileged(Native Method)

        at java.net.URLClassLoader.findClass(Unknown Source)

        at java.lang.ClassLoader.loadClass(Unknown Source)

        at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)

        at java.lang.ClassLoader.loadClass(Unknown Source)

        ... 4 more

PS E:\asd> ls

 

 

    Directory: E:\asd

 

 

Mode                LastWriteTime    Length Name

----                -------------    ------ ----

d----        03.01.2014    13:41            libraries

-a---        03.01.2014    13:12    2120962 forge-1.7.2-10.12.0.985-universal.jar

-a---        03.01.2014    13:12    9163955 minecraft_server.1.7.2.jar

 

PS E:\asd>

 

 

 

Tried with -cp minecraft_server.1.7.2.jar, with same result.

 

The same happens in windows and linux...

 

Client is working fine..

Posted

I updated to forge 1.7.2.10.12.0.991 and still not successful launching minecraft server with forge. Error that comes up when I run the bat file I created is:

 

Exception in thread "main" java.lang.NoClassDefFoundError: joptsimple/OptionSpec

 

        at java.lang.Class.forName0(Native Method)

        at java.lang.Class.forName(Unknown Source)

        at cpw.mods.fml.relauncher.ServerLaunchWrapper.run(ServerLaunchWrapper.j

ava:25)

        at cpw.mods.fml.relauncher.ServerLaunchWrapper.main(ServerLaunchWrapper.

java:12)

Caused by: java.lang.ClassNotFoundException: joptsimple.OptionSpec

        at java.net.URLClassLoader$1.run(Unknown Source)

        at java.net.URLClassLoader$1.run(Unknown Source)

        at java.security.AccessController.doPrivileged(Native Method)

        at java.net.URLClassLoader.findClass(Unknown Source)

        at java.lang.ClassLoader.loadClass(Unknown Source)

        at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)

        at java.lang.ClassLoader.loadClass(Unknown Source)

        ... 4 more

Press any key to continue . . .

 

 

Bat file simple does the following:

 

@echo off

java -Xms1000M -Xmx1000M -jar forge-1.7.2-10.12.0.991-universal.jar nogui

pause

 

 

And I can run the server using the above bat file but pointing to minecraft_server.1.7.2.jar just fine

Posted

Fucking son of a bitch abrar broke it again -.-

Either way the problem is this:

minecraft_server.1.7.2.jar is not in the class path

The solution:

Add minecraft_server.1.7.2.jar to the class path.

If you can't do that you shouldn't be hosting servers.

 

If you can't figure that out, then just rename 'minecraft_server.1.7.2.jar' to 'minecraft_server.1.7.2' Abrar deleted the '.jar' when he moved my code, it's been fixed but something fubared it again.

I do Forge for free, however the servers to run it arn't free, so anything is appreciated.
Consider supporting the team on Patreon

Posted

Fucking son of a bitch abrar broke it again -.-

Either way the problem is this:

minecraft_server.1.7.2.jar is not in the class path

The solution:

Add minecraft_server.1.7.2.jar to the class path.

If you can't do that you shouldn't be hosting servers.

 

If you can't figure that out, then just rename 'minecraft_server.1.7.2.jar' to 'minecraft_server.1.7.2' Abrar deleted the '.jar' when he moved my code, it's been fixed but something fubared it again.

 

From the same directory the server and forge jars are in:  (they should default to current folder for classpath even if it's not supplied)

 

PS C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft> java -Xmx1G -Xms1G -classpath 'C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft\minecraft_server.1.7.2.jar' -jar .\forge-1.7.2-10.12.0.993-universal.jar nogui
Exception in thread "main" java.lang.NoClassDefFoundError: joptsimple/OptionSpec
        at java.lang.Class.forName0(Native Method)
        at java.lang.Class.forName(Unknown Source)
        at cpw.mods.fml.relauncher.ServerLaunchWrapper.run(ServerLaunchWrapper.java:25)
        at cpw.mods.fml.relauncher.ServerLaunchWrapper.main(ServerLaunchWrapper.java:12)
Caused by: java.lang.ClassNotFoundException: joptsimple.OptionSpec
        at java.net.URLClassLoader$1.run(Unknown Source)
        at java.net.URLClassLoader$1.run(Unknown Source)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(Unknown Source)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        ... 4 more

 

I even tried renaming the server jar:

 

PS C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft> ren .\minecraft_server.1.7.2.jar .\minecraft_server.1.7.2
PS C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft> dir

    Directory: C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft

Mode                LastWriteTime     Length Name
----                -------------     ------ ----
d----          1/5/2014   7:20 PM            libraries
d----          1/5/2014   7:24 PM            logs
d----          1/5/2014   7:24 PM            world
-a---          1/5/2014   7:24 PM        109 banned-ips.txt
-a---          1/5/2014   7:24 PM        109 banned-players.txt
-a---          1/5/2014   7:20 PM    2125733 forge-1.7.2-10.12.0.993-universal.jar
-a---          1/5/2014   7:20 PM    9163955 minecraft_server.1.7.2
-a---          1/5/2014   7:24 PM          0 ops.txt
-a---          1/5/2014   7:24 PM        656 server.properties
-a---          1/5/2014   7:24 PM          0 white-list.txt


PS C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft> java -Xmx1G -Xms1G -jar .\forge-1.7.2-10.12.0.993-universal.jar nogui
Exception in thread "main" java.lang.NoClassDefFoundError: joptsimple/OptionSpec
        at java.lang.Class.forName0(Native Method)
        at java.lang.Class.forName(Unknown Source)
        at cpw.mods.fml.relauncher.ServerLaunchWrapper.run(ServerLaunchWrapper.java:25)
        at cpw.mods.fml.relauncher.ServerLaunchWrapper.main(ServerLaunchWrapper.java:12)
Caused by: java.lang.ClassNotFoundException: joptsimple.OptionSpec
        at java.net.URLClassLoader$1.run(Unknown Source)
        at java.net.URLClassLoader$1.run(Unknown Source)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(Unknown Source)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        ... 4 more

 

And I can still run the minecraft 1.7.2 server file just fine by itself without Forge.  This same issue has been happening for a half dozen tested versions for me from 976 through 993.

 

I appreciate the product and the hints at solution but I'd don't appreciate the aspersion.  I've supplied the classpath in multiple ways (explicitly and by running it from the current folder the jars reside in) and it has not resolved the issue.  I also tried renaming the server jar as suggested to remove the ".jar" and that too did not change the outcome.

 

Posted

-.-

How about this

Make sure that you have BOTH minecraft_server.1.7.2 AND minecraft_server.1.7.2.jar in the folder

That way when you use a broken version it'll work

And when you use the fixed versions (993) it'll work.

 

I do Forge for free, however the servers to run it arn't free, so anything is appreciated.
Consider supporting the team on Patreon

Posted

-.-

How about this

Make sure that you have BOTH minecraft_server.1.7.2 AND minecraft_server.1.7.2.jar in the folder

That way when you use a broken version it'll work

And when you use the fixed versions (993) it'll work.

 

I'm using 993 above and still have the error.  I wonder if I'm experiencing what you're suspecting.

 

(with and without .jar on server file)

 

 

 

PS C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft> cp .\minecraft_server.1.7.2.jar .\minecraft_server.1.7.2

PS C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft> dir

    Directory: C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft

Mode                LastWriteTime     Length Name
----                -------------     ------ ----
d----          1/5/2014   7:20 PM            libraries
d----          1/5/2014   7:24 PM            logs
d----          1/5/2014   7:24 PM            world
-a---          1/5/2014   7:24 PM        109 banned-ips.txt
-a---          1/5/2014   7:24 PM        109 banned-players.txt
-a---          1/5/2014   7:20 PM    2125733 forge-1.7.2-10.12.0.993-universal.jar
-a---          1/5/2014   7:20 PM    9163955 minecraft_server.1.7.2
-a---          1/5/2014   7:20 PM    9163955 minecraft_server.1.7.2.jar
-a---          1/5/2014   7:24 PM          0 ops.txt
-a---          1/5/2014   7:24 PM        656 server.properties
-a---          1/5/2014   7:24 PM          0 white-list.txt

 

PS C:\Users\minecraft\AppData\Roaming\Minecrafts\1.7.2 Forge\.minecraft> java -Xmx1G -Xms1G -jar .\forge-1.7.2-10.12.0.993-universal.jar nogui
Exception in thread "main" java.lang.NoClassDefFoundError: joptsimple/OptionSpec
        at java.lang.Class.forName0(Native Method)
        at java.lang.Class.forName(Unknown Source)
        at cpw.mods.fml.relauncher.ServerLaunchWrapper.run(ServerLaunchWrapper.java:25)
        at cpw.mods.fml.relauncher.ServerLaunchWrapper.main(ServerLaunchWrapper.java:12)
Caused by: java.lang.ClassNotFoundException: joptsimple.OptionSpec
        at java.net.URLClassLoader$1.run(Unknown Source)
        at java.net.URLClassLoader$1.run(Unknown Source)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.net.URLClassLoader.findClass(Unknown Source)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        ... 4 more

 

 

 

Posted

Humm, somehow jopt dissapeared from the server jar.. Use 994 it has it fixed, and i've tested fully.

Got to love one broken thing hiding another...

I do Forge for free, however the servers to run it arn't free, so anything is appreciated.
Consider supporting the team on Patreon

Posted

Humm, somehow jopt dissapeared from the server jar.. Use 994 it has it fixed, and i've tested fully.

Got to love one broken thing hiding another...

 

Confirmed:  994 runs fine and 1.7.2 clients w/ 994 Forge connect fine.

 

Thank you for following through on this!

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

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



  • Recently Browsing

    • No registered users viewing this page.
  • Posts

    • Version 1.19 - Forge 41.0.63 I want to create a wolf entity that I can ride, so far it seems to be working, but the problem is that when I get on the wolf, I can’t control it. I then discovered that the issue is that the server doesn’t detect that I’m riding the wolf, so I’m struggling with synchronization. However, it seems to not be working properly. As I understand it, the server receives the packet but doesn’t register it correctly. I’m a bit new to Java, and I’ll try to provide all the relevant code and prints *The comments and prints are translated by chatgpt since they were originally in Spanish* Thank you very much in advance No player is mounted, or the passenger is not a player. No player is mounted, or the passenger is not a player. No player is mounted, or the passenger is not a player. No player is mounted, or the passenger is not a player. No player is mounted, or the passenger is not a player. MountableWolfEntity package com.vals.valscraft.entity; import com.vals.valscraft.network.MountSyncPacket; import com.vals.valscraft.network.NetworkHandler; import net.minecraft.client.Minecraft; import net.minecraft.network.syncher.EntityDataAccessor; import net.minecraft.network.syncher.EntityDataSerializers; import net.minecraft.network.syncher.SynchedEntityData; import net.minecraft.server.MinecraftServer; import net.minecraft.server.level.ServerPlayer; import net.minecraft.world.entity.EntityType; import net.minecraft.world.entity.Mob; import net.minecraft.world.entity.ai.attributes.AttributeSupplier; import net.minecraft.world.entity.ai.attributes.Attributes; import net.minecraft.world.entity.animal.Wolf; import net.minecraft.world.entity.player.Player; import net.minecraft.world.entity.Entity; import net.minecraft.world.InteractionHand; import net.minecraft.world.InteractionResult; import net.minecraft.world.item.ItemStack; import net.minecraft.world.item.Items; import net.minecraft.world.level.Level; import net.minecraft.world.phys.Vec3; import net.minecraftforge.event.TickEvent; import net.minecraftforge.eventbus.api.SubscribeEvent; import net.minecraftforge.network.PacketDistributor; public class MountableWolfEntity extends Wolf { private boolean hasSaddle; private static final EntityDataAccessor<Byte> DATA_ID_FLAGS = SynchedEntityData.defineId(MountableWolfEntity.class, EntityDataSerializers.BYTE); public MountableWolfEntity(EntityType<? extends Wolf> type, Level level) { super(type, level); this.hasSaddle = false; } @Override protected void defineSynchedData() { super.defineSynchedData(); this.entityData.define(DATA_ID_FLAGS, (byte)0); } public static AttributeSupplier.Builder createAttributes() { return Wolf.createAttributes() .add(Attributes.MAX_HEALTH, 20.0) .add(Attributes.MOVEMENT_SPEED, 0.3); } @Override public InteractionResult mobInteract(Player player, InteractionHand hand) { ItemStack itemstack = player.getItemInHand(hand); if (itemstack.getItem() == Items.SADDLE && !this.hasSaddle()) { if (!player.isCreative()) { itemstack.shrink(1); } this.setSaddle(true); return InteractionResult.SUCCESS; } else if (!level.isClientSide && this.hasSaddle()) { player.startRiding(this); MountSyncPacket packet = new MountSyncPacket(true); // 'true' means the player is mounted NetworkHandler.CHANNEL.sendToServer(packet); // Ensure the server handles the packet return InteractionResult.SUCCESS; } return InteractionResult.PASS; } @Override public void travel(Vec3 travelVector) { if (this.isVehicle() && this.getControllingPassenger() instanceof Player) { System.out.println("The wolf has a passenger."); System.out.println("The passenger is a player."); Player player = (Player) this.getControllingPassenger(); // Ensure the player is the controller this.setYRot(player.getYRot()); this.yRotO = this.getYRot(); this.setXRot(player.getXRot() * 0.5F); this.setRot(this.getYRot(), this.getXRot()); this.yBodyRot = this.getYRot(); this.yHeadRot = this.yBodyRot; float forward = player.zza; float strafe = player.xxa; if (forward <= 0.0F) { forward *= 0.25F; } this.flyingSpeed = this.getSpeed() * 0.1F; this.setSpeed((float) this.getAttributeValue(Attributes.MOVEMENT_SPEED) * 1.5F); this.setDeltaMovement(new Vec3(strafe, travelVector.y, forward).scale(this.getSpeed())); this.calculateEntityAnimation(this, false); } else { // The wolf does not have a passenger or the passenger is not a player System.out.println("No player is mounted, or the passenger is not a player."); super.travel(travelVector); } } public boolean hasSaddle() { return this.hasSaddle; } public void setSaddle(boolean hasSaddle) { this.hasSaddle = hasSaddle; } @Override protected void dropEquipment() { super.dropEquipment(); if (this.hasSaddle()) { this.spawnAtLocation(Items.SADDLE); this.setSaddle(false); } } @SubscribeEvent public static void onServerTick(TickEvent.ServerTickEvent event) { if (event.phase == TickEvent.Phase.START) { MinecraftServer server = net.minecraftforge.server.ServerLifecycleHooks.getCurrentServer(); if (server != null) { for (ServerPlayer player : server.getPlayerList().getPlayers()) { if (player.isPassenger() && player.getVehicle() instanceof MountableWolfEntity) { MountableWolfEntity wolf = (MountableWolfEntity) player.getVehicle(); System.out.println("Tick: " + player.getName().getString() + " is correctly mounted on " + wolf); } } } } } private boolean lastMountedState = false; @Override public void tick() { super.tick(); if (!this.level.isClientSide) { // Only on the server boolean isMounted = this.isVehicle() && this.getControllingPassenger() instanceof Player; // Only print if the state changed if (isMounted != lastMountedState) { if (isMounted) { Player player = (Player) this.getControllingPassenger(); // Verify the passenger is a player System.out.println("Server: Player " + player.getName().getString() + " is now mounted."); } else { System.out.println("Server: The wolf no longer has a passenger."); } lastMountedState = isMounted; } } } @Override public void addPassenger(Entity passenger) { super.addPassenger(passenger); if (passenger instanceof Player) { Player player = (Player) passenger; if (!this.level.isClientSide && player instanceof ServerPlayer) { // Send the packet to the server to indicate the player is mounted NetworkHandler.CHANNEL.send(PacketDistributor.PLAYER.with(() -> (ServerPlayer) player), new MountSyncPacket(true)); } } } @Override public void removePassenger(Entity passenger) { super.removePassenger(passenger); if (passenger instanceof Player) { Player player = (Player) passenger; if (!this.level.isClientSide && player instanceof ServerPlayer) { // Send the packet to the server to indicate the player is no longer mounted NetworkHandler.CHANNEL.send(PacketDistributor.PLAYER.with(() -> (ServerPlayer) player), new MountSyncPacket(false)); } } } @Override public boolean isControlledByLocalInstance() { Entity entity = this.getControllingPassenger(); return entity instanceof Player; } @Override public void positionRider(Entity passenger) { if (this.hasPassenger(passenger)) { double xOffset = Math.cos(Math.toRadians(this.getYRot() + 90)) * 0.4; double zOffset = Math.sin(Math.toRadians(this.getYRot() + 90)) * 0.4; passenger.setPos(this.getX() + xOffset, this.getY() + this.getPassengersRidingOffset() + passenger.getMyRidingOffset(), this.getZ() + zOffset); } } } MountSyncPacket package com.vals.valscraft.network; import com.vals.valscraft.entity.MountableWolfEntity; import net.minecraft.network.FriendlyByteBuf; import net.minecraft.server.level.ServerLevel; import net.minecraft.server.level.ServerPlayer; import net.minecraft.world.entity.Entity; import net.minecraft.world.entity.player.Player; import net.minecraftforge.network.NetworkEvent; import java.util.function.Supplier; public class MountSyncPacket { private final boolean isMounted; public MountSyncPacket(boolean isMounted) { this.isMounted = isMounted; } public void encode(FriendlyByteBuf buffer) { buffer.writeBoolean(isMounted); } public static MountSyncPacket decode(FriendlyByteBuf buffer) { return new MountSyncPacket(buffer.readBoolean()); } public void handle(NetworkEvent.Context context) { context.enqueueWork(() -> { ServerPlayer player = context.getSender(); // Get the player from the context if (player != null) { // Verifies if the player has dismounted if (!isMounted) { Entity vehicle = player.getVehicle(); if (vehicle instanceof MountableWolfEntity wolf) { // Logic to remove the player as a passenger wolf.removePassenger(player); System.out.println("Server: Player " + player.getName().getString() + " is no longer mounted."); } } } }); context.setPacketHandled(true); // Marks the packet as handled } } networkHandler package com.vals.valscraft.network; import com.vals.valscraft.valscraft; import net.minecraft.resources.ResourceLocation; import net.minecraftforge.network.NetworkRegistry; import net.minecraftforge.network.simple.SimpleChannel; import net.minecraftforge.network.NetworkEvent; import java.util.function.Supplier; public class NetworkHandler { private static final String PROTOCOL_VERSION = "1"; public static final SimpleChannel CHANNEL = NetworkRegistry.newSimpleChannel( new ResourceLocation(valscraft.MODID, "main"), () -> PROTOCOL_VERSION, PROTOCOL_VERSION::equals, PROTOCOL_VERSION::equals ); public static void init() { int packetId = 0; // Register the mount synchronization packet CHANNEL.registerMessage( packetId++, MountSyncPacket.class, MountSyncPacket::encode, MountSyncPacket::decode, (msg, context) -> msg.handle(context.get()) // Get the context with context.get() ); } }  
    • Do you use features of inventory profiles next (ipnext) or is there a change without it?
    • Remove rubidium - you are already using embeddium, which is a fork of rubidium
  • Topics

  • Who's Online (See full list)

    • There are no registered users currently online
×
×
  • Create New...

Important Information

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