Commit graph

72 commits

Author SHA1 Message Date
Norbi Peti fdcab1acb2
Fix LPInjector and player data stuff 2020-10-25 21:49:09 +01:00
dependabot[bot] 67a66c0c44
Bump junit from 3.8.1 to 4.13.1
Bumps [junit](https://github.com/junit-team/junit4) from 3.8.1 to 4.13.1.
- [Release notes](https://github.com/junit-team/junit4/releases)
- [Changelog](https://github.com/junit-team/junit4/blob/main/doc/ReleaseNotes4.13.1.md)
- [Commits](https://github.com/junit-team/junit4/commits/r4.13.1)

Signed-off-by: dependabot[bot] <support@github.com>
2020-10-13 06:37:54 +00:00
Norbi Peti 56d13ebf9f
Update to Discord4J v3.1.1
It wasn't as complicated as I expected
2020-10-07 22:27:20 +02:00
Norbi Peti 3f2fa286fb
Attempt to use ByteBuddy directly for ServerWatcher 2020-10-07 00:52:59 +02:00
Norbi Peti cd2132ba45
Fix ServerWatcher, mcchat works 2020-09-11 22:27:22 +02:00
Norbi Peti 666f05ff12
Attempts at mocking the server, fixes 2020-09-11 01:20:12 +02:00
Norbi Peti 6b60135867
NorbiPeti has completed the challenge [Bullseye]
Using the custom event to detect player /stop as now restarts can come from there too (btw it defaults to stop unless a command is ran)
Added support for advancements in 1.16:
- Now each player gets effectively a reference to the player list for advancements, and since I simply call the method on the original object, it will pass that on, instead of my mock
- I tried calling the method that sends the reference on the mock in that case, but that just results in Mockito's version being called which means infinite recursion or something like that (I didn't get a StackOverflowError actually but the server didn't respond)
- I tried implementing the method myself but actually I never tested it because at that point I was convinced I can call the original the right way
- I had an educated guess that the mock is a subclass of the original class, so I just need to call super.method() right?
- But how do you call that reflectively? Apparently Method.invoke() will always respect overriden methods; but thanks to StackOverflow I found out about MethodHandles, and it has the perfect thing I need, findSpecial / unreflectSpecial
- Only problem is, kind of like how you can only use super.method() inside the class, you can only use the 'special' methods inside the class... So how could I make it run inside the mocked class? I have no idea since I can only supply an Answer object which has no connection to it, but apparently all the lookup() method actually does is call a constructor with the caller's class - so let's call the constructor! Which is, of course private
- So now I have a reflection call creating a Lookup object which can get a handle to the method without checking any overrides and then using that handle to call the original method with the 'this' parameter being the mock
#128
2020-07-30 01:54:58 +02:00
Norbi Peti 4ecd32f0ad
Update D4J and fix LuckPerms support 2020-05-27 15:45:14 +02:00
Norbi Peti cce7f59f4a
Fix issue with VanillaCommandListener on <1.15 2020-04-08 00:13:19 +02:00
Norbi Peti 1b747ab99f
Use command channels and fix dependencies 2020-03-15 03:10:27 +01:00
Norbi Peti 037ec3b9dd Use VCL14 for 1.15, player sender mock
Using VanillaCommandListener14 for 1.15 as well
Using a mock for the DiscordPlayerSender too, to reduce the amount of code
Made the mocks stub-only, which should lower memory usage
2020-03-11 12:00:20 +01:00
Norbi Peti 454265cd6f Update player list on (un)vanish
#120
2020-02-18 17:18:17 +01:00
Norbi Peti ffdf5a2f18 Fix custom chat PL update NPE (#124) 2020-02-17 13:02:15 +01:00
Norbi Peti d58a7e819a Some documentation and updates 2020-02-05 16:49:07 +01:00
Norbi Peti 26971459ac Rename 2020-02-04 17:44:59 +01:00
Norbi Peti 940b601061 Fixed custom chat player list update
The problem was that for some reason I created a field that was already present in the parent class and it just happened to be pretty much never used before the PL update
Also updated EssentialsX dependency
2020-02-03 13:20:38 +01:00
Norbi Peti b481bb0aa9
Fixed join msgs, vanished players in desc. and others
Update D4J
Fixed join messages appearing when they shouldn't (#119)
Only showing players who can see the channel (#91)
Fixed vanished players appearing in the channel descriptions (#120)
2019-12-27 21:14:52 +01:00
Norbi Peti 3a94b6191b
Update D4J and some bugfixes
The update fixes the numerous errors about a missing status constant
Remove test check (#114)
Improvements and checking for admin permission (#115)
It also checks for channel perms now
2019-11-28 00:16:58 +01:00
Norbi Peti 88c1d100e9
Using parent & hopefully fixed #109 2019-10-23 02:40:34 +02:00
Norbi Peti f1cec2ced1
Update to Java 10/11 & fake player remove
Apparently
2019-10-20 20:50:29 +02:00
Norbi Peti e4d5dcd0a2
Update D4J & role debug refined & fixed a )
PLW tested and confirmed working
Moved a ) to fix #105
2019-08-26 00:57:16 +02:00
Norbi Peti e88684a564
Error handling, 1.14 vanilla command support
Error handling (not today)
Added support for vanilla commands on 1.14
2019-08-14 00:53:51 +02:00
Norbi Peti 5a5f653b86
Added DC user mention tabcomplete...
But only for commands, because that's how it works now apparently
#16
Also might have made it 1.14 ready, though I switched the dependency back to 1.12
Oh it's 1.12.2...
2019-07-08 02:00:08 +02:00
Norbi Peti 5472929113
Added, 5xFixed
Added mcchat login/logout messages
Only printing timings messages if debug is on

Fixed #93
F i x e d
Fixed command handled status
Fixed debug command
Fixed error reporting limit
Fixed Discord YEEHAW
2019-05-31 00:38:28 +02:00
Norbi Peti 545b8130e0
Added timings and a line that solves everything
cb.setStoreService(new JdkStoreService());
2019-05-30 18:45:44 +02:00
Norbi Peti bf538d9bd0
LP injecting, fake player fixes
#96
LuckPerms
Added support for excluding plugins from certain events from code
Also might have fixed some message timeouts by relocating netty
2019-05-25 01:48:06 +02:00
Norbi Peti ac61225730
Update, bot cmd fix, debugging 2019-05-20 21:51:28 +02:00
Norbi Peti b396ec47b4
Some fixes, some debugging
#93
2019-05-11 00:15:50 +02:00
Norbi Peti beab400873
Some debugging, some fixes
#93
2019-05-10 21:39:25 +02:00
Norbi Peti eeb1955ebe
Bunch of fixes
#93
2019-04-25 19:52:43 +02:00
Norbi Peti d8d75c063b Started converting to new D4J
#93
2019-04-17 13:52:01 +02:00
Irinyi Kabinet Felhasználó c8680ae92c Merge branch 'master' into dev 2019-04-15 14:51:45 +02:00
Norbi Peti d2aea8559a Server ready conf, doc 2019-04-10 13:50:26 +02:00
Norbi Peti a9d4d5e9e1
Use previous version of D4J
Hopefully resolves mysterious NoSuchMethodError
2019-03-17 22:56:17 +01:00
Norbi Peti 13b168d238 Made all channels configurable
Removed Vault repo, was unused and errors now
Removed all channel fields from main class
2019-02-13 15:21:57 +01:00
Norbi Peti 1878a46041
Cleanup, organizing (MCChatListener)
Removed all sysouts
Split MCChatListener into utils, private and custom (and the existing one)
Using fixed version of Discord4J (fixes issues with local testing)
2018-12-17 21:33:55 +01:00
Norbi Peti 9527be99d1
Fixed 122 errors - by fixing the pom
Also other fixes
2018-11-22 23:11:19 +01:00
Norbi Peti d12fe961c0
No Origins 2018-11-22 01:02:20 +01:00
Norbi Peti 17887707cb
Bunch of channel stuff
#70 is technically fixed but there's another issue
#61 and #71 are definitely fixed
Allowing multiple channels to be connected
2018-11-01 01:34:36 +01:00
Norbi Peti 38ef88f10d
Add ButtonCore dependency
And remove PEX dependency
2018-07-02 15:56:36 +02:00
Norbi Peti b8814030e2
Fixes, channelcon, emoji
Limited timeout for shutdown message
Added some unconnected commands
Fixed mcchat tasks on shutdown
Added /rp as an allowed channel
Changed help texts to use /command syntax
Added channelcon remove
Added emoji parsing
2018-06-08 01:48:07 +02:00
Norbi Peti aabdd3a914
Channel connect, fixes
- To do or not to do
- Fixed args handling regarding whitespace
- Showing the help text for cmds when needed
- Fixed userinfo cmd not accepting spaces while Discord does
- Moved command registration to start, not the initializer
-- Prevents possible deadlocks according to IntelliJ
- Other fixes
2018-05-22 22:43:36 +02:00
Norbi Peti b60bf36864 Finished game roles
Still needs testing

Couldn't set GPG signing up - yet
2018-05-07 01:11:08 +02:00
Norbi Peti 42966d0feb
Removed religion making offer
For now
2018-02-14 21:07:52 +01:00
Norbi Peti f8c543017a The hack works! 2017-10-29 18:49:52 +01:00
Norbi Peti f85b56fe28 Quite big hack for hooking into all broadcasts
Right now it doesn't let anyone in.
2017-10-29 02:00:44 +02:00
Norbi Peti cda76fdb93 Fixes, added quitting fake players on disable 2017-08-06 02:23:13 +02:00
Norbi Peti fd14bf1954 FINISHED mcchat!
#12 #13
Vanilla commands are supported as well
Now it'll send the command output to the player as well, if ran on
Discord
Minecraft chat sending to Discord made async
Started using CraftBukkit
Updated Travis config according to that
2017-07-13 00:58:05 +02:00
Norbi Peti 9e85883e34 Mostly fixed permissions (now it's recursing) 2017-07-08 02:13:56 +02:00
Norbi Peti cf5aaa53fb Undid delegate, mcchat fixes, testing check
It checks if it's running in production and another copy is testing at
the moment
2017-07-04 18:04:01 +02:00