OpticFusion1 / MCAntiMalware

Anti-Malware for minecraft
https://www.spigotmc.org/resources/spigot-anti-malware-detects-over-200-malicious-plugins.64982/
GNU General Public License v3.0
287 stars 29 forks source link

[FEATURE REQUEST] Take separate server arguments after -- #616

Closed ion1 closed 1 year ago

ion1 commented 1 year ago

Is your feature request related to a problem? Please describe. I am trying to run a Minecraft server through MCAntiMalware. Currently it seems I have to convert the server arguments into a single argument with , as a separator.

Describe the solution you'd like It would be more convenient to run

java -jar MCAntiMalware.jar --serverJar path/to/paper.jar -- \
  --nogui \
  --plugins path/to/plugins \
  --world-dir path/to/world \
  --config path/to/config \
  ...

(following the popular -- convention) than the current

java -jar MCAntiMalware.jar --serverJar path/to/paper.jar --serverArguments \
  --nogui,--plugins,path/to/plugins,--world-dir,path/to/world,--config,path/to/config,...

Describe alternatives you've considered The alternative is to keep the current behavior.

Additional context N/A

OpticFusion1 commented 1 year ago

This is not easy to implement I'm afraid. I do have a WIP paper fork however. It is currently not made for 1.19.3, nor does it have the complete set of features or detections but the current version is https://drive.google.com/file/d/11DHiZ0F2-zwGmybXbVAzPXmBzFiAH2O4/view?usp=share_link

ion1 commented 1 year ago

I'm not knowledgeable with Java, but it seems the jopt-simple library supports it through options.nonOptionArguments().

OpticFusion1 commented 1 year ago

I do custom parsing to handle server stuff separately because of how hacky I have to make supporting the servers, I've had issues in the past when using other methods

OpticFusion1 commented 1 year ago

This functionality has been removed in 15.6 in favor of using the paper fork. Latest version (1.19.3) is this https://drive.google.com/file/d/1IFYP_FneuX3hmL17cjJu4n9YNcli1bFr/view?usp=share_link

Closed.