![]() The steps are very similar to the methods above. agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=*:5005Without the star in address=*:5005 it will not work on the latest version of java Method 3: IDE as Debug Server (Local) Now you need to modify server=y option of agentlib, it must be server=n. Step 2 | Editing the Server Startup Command So, we will use jvm arguments from first method with one small modification, which described in step 2. Then you can copy "Command line arguments for remote JVM", but it's contains optional params, which you need to setup manually. In debug configuration that you've created, change "Debugger mode" from "Attach to remote JVM" to "Listen to remote JVM". Therefore, I will describe only differ of steps from method 1. If you need to debug your plugin at server startup time (for example, plugin onLoad() or onEnable() methods) you may want to use IDE as Debug Server instead of spigot server itself. You should not change it for production servers ofcourse). Edit RandomPatches config file (randompatches.toml) and set "read_timeout_seconds" based on your liking (This should only happen for the client-side when debugging a plugin.Install RandomPatches mod (allows you to edit hard-coded vanilla minecraft variables).Install Forge for the spigot server version you are developing (You can still join spigot based servers for plugin development).The client will still time out after 30 seconds, but you can overcome it with forge mod RandomPatches. To prevent your server from constantly timing out while debugging, set timeout-time to a large number. This causes your server to time out if you resume the thread after 60 seconds. IMPORTANT: The default value of timeout-time in spigot.yml is 60. If you need help make a post on the forum and if I see it I will try to help you out, *If you are using Maven this will still work, but comment out any relocations in your pom.xml when debugging* It will be easiest if you tick 'Don't show this message again' to speed the process up. The first time you do this, a message box pops up asking you to confirm you want to make the changes.That's it! You are now connected, all you have to do is press the button to the left of the configuration name (pictured in the first picture of this step, highlighted with red square) to make and reload the project including your changes.To set breaking points just click next to the line numbers. Hit the green Bug button to connect, the following console will popup in the bottom corner of your screen and show you whether if it has been successful. ![]() If your config isn't selected, please select it from the dropdown) ![]() We have just copied these from the Edit Configurations window in the previous step. Open the start_mand or start_server.bat and paste the following arguments before the '-jar spigot.jar' on the same line.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |