Last active [hidden]
Actually, though it's "impossible", so to speak, to have custom commands, I know a way you could offer custom commands without altering the jar file at all.
I'm not too well versed on ASM class transformers, as I only started programming with them a few weeks ago, but I believe you could inject classes into a certain runtime instance using these and modify existing opcodes and instructions. I'm very familiar with Java bytecode, so if @CraftyMyner you decide to do this, I could help if needed.
If the objectweb2 ASM library doesn't have the functionality to do this, however, I think it's possible to use a lower level language like C / C++ with the JNI to inject bytecode into loaded classes.
Anyway, you would just need to transform the channel reader pipeline class, inject code at the beginning of channelRead0, and you would have custom commands without modifying the jar itself, since the transformation will happen from an external codebase.
-Stone__Warrior :)
im surprised the command-y vanilla servers don't do this
Edit: Upon further research, it appears that you can use the ow2 asm library if you use the -javaagent option in your ProcessBuilder call (if you're using Java to do the panel / server starter).
I would argue that this would be considered modifying the jar as you are manipulating the bytecode in the running process. A much easier way to do this would be to just use some front-end proxy that parses all the incoming and outgoing packets. There is already quite of few of proxies these out there with api's to manage chat commands and other packets. My issue with these is that they add some level of lag to your connection as well as an update from mojang could render the system completely useless requiring a lot of work to fix. Not to mention the stretch it would be calling it vanilla.
There might be an in-game method to fix the issue of accidental tp. TPA's could have their timeouts reduced so that scrolling up in chat would not put you at risk of clicking someone's tpa request. A secondary confirm message could be added, forcing the user to confirm each tp.
There are also panel ways to deal with the tpa issue like making the tpa use ".tp <player>" and ".accept" but I'm not sure how this would go over.
The server will now let you know when you reach vote streak milestones like 5, 10, 15...
It will also let you know how many days you have left to get the loot crate.
Good idea, ill see what i can do.
Triggered by:
vote stats?
have i voted today?
vote streak?
how many votes do i have in a row?
It's not because they dont have a score, its because they dont show up on the tab list if they are in spectator.
Too much spam, I think I might have an idea though.
"tpa" and "cmd" have been added.
Spectators don't have scores displayed and players without a score set show as 0.
I’ll make aliase commands for each trigger when I get home.
Spectators stand out like a sore thumb when scores are shown in the list.
I have an idea.