Skip to content

Commit

Permalink
Squashed commit of the following:
Browse files Browse the repository at this point in the history
commit 36615a9
Author: AoElite <[email protected]>
Date:   Sat Apr 13 23:59:22 2024 -0400

    rename BadPacketsV to BadPacketsU

commit 8441187
Merge: 51b2179 e9eab8a
Author: AoElite <[email protected]>
Date:   Sat Apr 13 23:50:14 2024 -0400

    Merge pull request GrimAnticheat#1368 from ManInMyVan/bpV

    Add BadPacketsV

commit e9eab8a
Author: ManInMyVan <[email protected]>
Date:   Sat Apr 13 20:21:09 2024 -0600

    make BadPacketV experimental

commit 51b2179
Merge: 1288799 cc4954d
Author: AoElite <[email protected]>
Date:   Sat Apr 13 20:59:59 2024 -0400

    Merge pull request GrimAnticheat#1431 from 483378/2.0

    BadPacketsM: fix armor stand false flag

commit cc4954d
Author: 483378 <[email protected]>
Date:   Sun Apr 14 02:22:53 2024 +0200

    BadPacketsM: fix armor stand false flag

commit 1288799
Merge: 0928d3e 62f30df
Author: AoElite <[email protected]>
Date:   Fri Apr 12 15:03:16 2024 -0400

    Merge pull request GrimAnticheat#1430 from ManInMyVan/fix/bpM-1.7

    exempt 1.7 players in BadPacketsM

commit f9c104c
Merge: 4e3bd85 0928d3e
Author: ManInMyVan <[email protected]>
Date:   Fri Apr 12 12:53:41 2024 -0600

    Merge branch '2.0' into bpV

commit 62f30df
Author: ManInMyVan <[email protected]>
Date:   Fri Apr 12 12:40:31 2024 -0600

    exempt 1.7 players in BadPacketsM

commit 0928d3e
Merge: 9e918a3 d3fc52f
Author: AoElite <[email protected]>
Date:   Fri Apr 12 01:18:14 2024 -0400

    Merge pull request GrimAnticheat#1427 from ManInMyVan/bpM

    Add BadPacketsM

commit d3fc52f
Author: ManInMyVan <[email protected]>
Date:   Thu Apr 11 23:05:56 2024 -0600

    Update BadPacketsM.java

commit 9e918a3
Merge: 25889d9 79ab881
Author: AoElite <[email protected]>
Date:   Fri Apr 12 01:02:07 2024 -0400

    Merge pull request GrimAnticheat#1428 from ManInMyVan/Post2

    fix post exempting all ENTITY_ACTION packets for 1.8c -> 1.9s

commit 25889d9
Merge: 9c70d9e ecb13e5
Author: AoElite <[email protected]>
Date:   Fri Apr 12 01:00:54 2024 -0400

    Merge pull request GrimAnticheat#1426 from ManInMyVan/fix/InvalidPlace

    fix InvalidPlace

commit 9c70d9e
Merge: bbe86d5 568f1ff
Author: AoElite <[email protected]>
Date:   Fri Apr 12 00:59:36 2024 -0400

    Merge pull request GrimAnticheat#1405 from JamesTheFlash22/2.0

    Italian messages

commit bbe86d5
Merge: 2fda5b4 9fc46a9
Author: AoElite <[email protected]>
Date:   Fri Apr 12 00:58:13 2024 -0400

    Merge pull request GrimAnticheat#1399 from ManInMyVan/bpQ+

    Improve BadPacketsQ

commit 79ab881
Author: ManInMyVan <[email protected]>
Date:   Thu Apr 11 19:32:35 2024 -0600

    fix always exempting ENTITY_ACTION packets for 1.8c -> 1.9s

commit 2c66a03
Author: ManInMyVan <[email protected]>
Date:   Thu Apr 11 18:36:48 2024 -0600

    check shouldModifyPackets()

commit db6f887
Author: ManInMyVan <[email protected]>
Date:   Thu Apr 11 18:26:47 2024 -0600

    Add BadPacketsM

commit ecb13e5
Author: ManInMyVan <[email protected]>
Date:   Thu Apr 11 16:30:43 2024 -0600

    fix InvalidPlace

commit 2fda5b4
Merge: d6cefa7 aa3ebfe
Author: AoElite <[email protected]>
Date:   Wed Mar 27 13:33:10 2024 -0400

    Merge pull request GrimAnticheat#1409 from ManInMyVan/config

    add %experimental%

commit aa3ebfe
Author: ManInMyVan <[email protected]>
Date:   Tue Mar 26 19:54:42 2024 -0600

    add %experimental%

commit d6cefa7
Author: AoElite <[email protected]>
Date:   Sat Mar 23 16:56:34 2024 -0400

    fix bell exception

commit 568f1ff
Author: JamesTheFlash22 <[email protected]>
Date:   Sat Mar 23 19:52:51 2024 +0100

    Add files via upload

commit f68afad
Author: JamesTheFlash22 <[email protected]>
Date:   Sat Mar 23 19:51:44 2024 +0100

    Add files via upload

commit 30d7bf4
Author: JamesTheFlash22 <[email protected]>
Date:   Sat Mar 23 19:51:04 2024 +0100

    Update it.yml

commit 06f80ac
Author: JamesTheFlash22 <[email protected]>
Date:   Sat Mar 23 19:49:42 2024 +0100

    Add files via upload

commit 3a1196f
Author: JamesTheFlash22 <[email protected]>
Date:   Sat Mar 23 19:49:01 2024 +0100

    Add files via upload

commit 284ee97
Author: AoElite <[email protected]>
Date:   Mon Mar 18 13:47:47 2024 -0400

    fix yaw/pitch order in HeadRotation

commit 9fc46a9
Author: ManInMyVan <[email protected]>
Date:   Sat Mar 16 20:37:28 2024 -0600

    Update BadPacketsQ.java

commit 396837e
Author: AoElite <[email protected]>
Date:   Sat Mar 16 13:42:57 2024 -0400

    oops

commit 58a2bf1
Author: AoElite <[email protected]>
Date:   Sat Mar 16 13:35:36 2024 -0400

    bump version

commit 4b86d58
Author: AoElite <[email protected]>
Date:   Sat Mar 16 13:31:52 2024 -0400

    add max-ping-out-of-flying config option

commit 4e3bd85
Author: ManInMyVan <[email protected]>
Date:   Thu Mar 7 16:09:19 2024 -0700

    Check sequence

commit a89ce79
Author: ManInMyVan <[email protected]>
Date:   Sun Mar 3 16:20:47 2024 -0700

    do not exempt 1.9+ servers

commit 6219fa3
Merge: d0a81f0 57b4f3a
Author: ManInMyVan <[email protected]>
Date:   Sun Mar 3 15:14:28 2024 -0700

    Merge branch 'GrimAnticheat:2.0' into bpV

commit 57b4f3a
Merge: d7b2192 14ca015
Author: AoElite <[email protected]>
Date:   Thu Feb 29 22:41:26 2024 -0500

    Merge pull request GrimAnticheat#1380 from SamB440/fix/fast-break-chunk-load

    Fix chunk loaded check in FastBreak

commit 14ca015
Author: SamB440 <[email protected]>
Date:   Thu Feb 29 13:00:46 2024 +0000

    Fix chunk loaded check in FastBreak

commit d0a81f0
Merge: 70a0317 d7b2192
Author: ManInMyVan <[email protected]>
Date:   Tue Feb 27 16:51:36 2024 -0700

    Merge branch 'GrimAnticheat:2.0' into bpV

commit 70a0317
Author: ManInMyVan <[email protected]>
Date:   Tue Feb 27 16:39:51 2024 -0700

    cancel packet

commit ab19986
Author: ManInMyVan <[email protected]>
Date:   Tue Feb 27 16:23:21 2024 -0700

    verbose

commit a1cd0d1
Author: ManInMyVan <[email protected]>
Date:   Tue Feb 27 16:09:47 2024 -0700

    Exempt 1.9+ on item check

commit d7b2192
Merge: d60c557 c6b3bf4
Author: AoElite <[email protected]>
Date:   Tue Feb 27 15:56:43 2024 -0500

    Merge pull request GrimAnticheat#1377 from SamB440/feat/mega-performance

    Performance improvements

commit d60c557
Author: AoElite <[email protected]>
Date:   Tue Feb 27 15:48:55 2024 -0500

    update packetevent settings & bump version

commit c6b3bf4
Author: SamB440 <[email protected]>
Date:   Tue Feb 27 18:59:10 2024 +0000

    Don't clone WrappedBlockState in Collisions#getCollisionBoxes

commit 34379bb
Author: SamB440 <[email protected]>
Date:   Tue Feb 27 16:43:28 2024 +0000

    Use IdentityHashMap for CollisionData

commit 5a0a04d
Merge: 8e72d9c b2bda34
Author: AoElite <[email protected]>
Date:   Tue Feb 27 11:36:49 2024 -0500

    Merge pull request GrimAnticheat#1376 from SamB440/fix/air

    Include CAVE_AIR and VOID_AIR in NONE CollisionData

commit b2bda34
Author: SamB440 <[email protected]>
Date:   Tue Feb 27 14:45:52 2024 +0000

    Include CAVE_AIR and VOID_AIR in NONE CollisionData

commit 8e72d9c
Merge: 86b9207 0d073ca
Author: AoElite <[email protected]>
Date:   Sun Feb 25 05:57:17 2024 -0500

    Merge pull request GrimAnticheat#1372 from metabrixkt/fix/kotlin-shading

    Remove Kotlin from shaded libraries

commit 86b9207
Merge: b6d2a11 9f2262e
Author: AoElite <[email protected]>
Date:   Sun Feb 25 05:56:53 2024 -0500

    Merge pull request GrimAnticheat#1361 from ManInMyVan/BadPacketsL1.7

    Improve BadPacketsL

commit d0646ca
Author: ManInMyVan <[email protected]>
Date:   Sat Feb 24 12:08:20 2024 -0700

    maintainability

commit 0d073ca
Author: metabrixkt <[email protected]>
Date:   Sat Feb 24 15:09:31 2024 +0500

    Downgrade discord-webhooks to 0.8.0

commit 9f2262e
Author: ManInMyVan <[email protected]>
Date:   Sat Feb 24 00:01:11 2024 -0700

    change comment

commit d21ab4b
Author: ManInMyVan <[email protected]>
Date:   Fri Feb 23 15:26:48 2024 -0700

    Add BadPacketsV

commit 03424ae
Author: ManInMyVan <[email protected]>
Date:   Thu Feb 22 13:33:04 2024 -0700

    Make BadPacketsL flag invalid positions on other packets and verbose

commit b6d2a11
Merge: 1893def 60f503d
Author: AoElite <[email protected]>
Date:   Wed Feb 21 21:47:39 2024 -0500

    Merge branch '2.0' of https://github.com/GrimAnticheat/Grim into 2.0

commit 1893def
Author: AoElite <[email protected]>
Date:   Wed Feb 21 21:47:22 2024 -0500

    refactor api

commit 6018a22
Author: ManInMyVan <[email protected]>
Date:   Tue Feb 20 10:53:29 2024 -0700

    readability

commit 9db1a1c
Author: ManInMyVan <[email protected]>
Date:   Mon Feb 19 12:21:27 2024 -0700

    Fix BadPacketsL exempting 1.7 players

commit 60f503d
Author: AoElite <[email protected]>
Date:   Sun Feb 18 15:40:20 2024 -0500

    Update CrashH.java

    reduce length threshold

commit 3fa22a1
Author: AoElite <[email protected]>
Date:   Mon Feb 12 19:16:08 2024 -0500

    updated dependencies & bump version

commit d2e16a8
Author: AoElite <[email protected]>
Date:   Mon Feb 12 04:24:19 2024 -0500

    update maven repository url for packetevents

commit cefaac7
Merge: 588c868 c7f6493
Author: AoElite <[email protected]>
Date:   Sun Feb 11 17:59:47 2024 -0500

    Merge branch '2.0' of https://github.com/GrimAnticheat/Grim into 2.0

commit 588c868
Author: AoElite <[email protected]>
Date:   Sun Feb 11 17:59:30 2024 -0500

    update packetevents

commit c7f6493
Merge: 33f86dc 444c44f
Author: AoElite <[email protected]>
Date:   Sun Feb 11 04:21:38 2024 -0500

    Merge pull request GrimAnticheat#1353 from GDMgmer3992/patch-1

    Update README.md

commit 444c44f
Author: GDMgamer3992 <[email protected]>
Date:   Sun Feb 11 11:32:22 2024 +0700

    Update README.md

    Grammar Correction
    Small Fixes

commit 33f86dc
Author: AoElite <[email protected]>
Date:   Fri Feb 9 21:23:28 2024 -0500

    bump version

commit 107942d
Author: AoElite <[email protected]>
Date:   Fri Feb 9 16:41:20 2024 -0500

    allow Timer setback to be adjustable

commit 151311e
Author: AoElite <[email protected]>
Date:   Fri Feb 9 16:35:56 2024 -0500

    don't reset oplevel on dimension changes

commit d1dd0d2
Author: AoElite <[email protected]>
Date:   Fri Feb 9 16:35:13 2024 -0500

    update fastutil

commit 02275e1
Merge: 21d0dcf e0389d5
Author: AoElite <[email protected]>
Date:   Wed Feb 7 19:41:58 2024 -0500

    Merge branch '2.0' of https://github.com/GrimAnticheat/Grim into 2.0

commit 21d0dcf
Author: AoElite <[email protected]>
Date:   Wed Feb 7 19:41:08 2024 -0500

    bump version

commit 116fe09
Author: AoElite <[email protected]>
Date:   Wed Feb 7 19:41:00 2024 -0500

    add CrashH

commit 49baa0f
Author: AoElite <[email protected]>
Date:   Wed Feb 7 19:40:47 2024 -0500

    add hitbox data for some missing blocks

commit e0389d5
Merge: ee2d4ce 5bacedf
Author: AoElite <[email protected]>
Date:   Sat Feb 3 17:47:57 2024 -0500

    Merge pull request GrimAnticheat#1347 from HmmooodXD/2.0

    Update LICENSE Year

commit 5bacedf
Author: HmodyXD <[email protected]>
Date:   Sat Feb 3 13:44:19 2024 +0100

    Update ru.yml

commit 9c4bbe6
Author: HmodyXD <[email protected]>
Date:   Sat Feb 3 13:44:08 2024 +0100

    Update pt.yml

commit a52dd67
Author: HmodyXD <[email protected]>
Date:   Sat Feb 3 13:43:55 2024 +0100

    Update fr.yml

commit 0f8fef9
Author: HmodyXD <[email protected]>
Date:   Sat Feb 3 13:43:44 2024 +0100

    Update es.yml

commit b4abcf4
Author: HmodyXD <[email protected]>
Date:   Sat Feb 3 13:43:31 2024 +0100

    Update de.yml

commit f1d4c87
Author: HmodyXD <[email protected]>
Date:   Sat Feb 3 13:43:19 2024 +0100

    Update en.yml

commit ee2d4ce
Author: AoElite <[email protected]>
Date:   Wed Jan 24 21:34:23 2024 -0500

    bump version

commit c29fbb6
Merge: 6d134a6 9f065ea
Author: AoElite <[email protected]>
Date:   Wed Jan 24 21:28:15 2024 -0500

    Merge branch '2.0' of https://github.com/GrimAnticheat/Grim into 2.0

commit 6d134a6
Author: AoElite <[email protected]>
Date:   Wed Jan 24 21:28:04 2024 -0500

    add initial camel support

commit 9f065ea
Merge: 60cc4d7 2024c11
Author: AoElite <[email protected]>
Date:   Tue Jan 23 15:30:28 2024 -0500

    Merge pull request GrimAnticheat#1336 from gNewl/patch-2

    Include checking ghostblock abuse in portuguese translations

commit 2024c11
Author: gNewl <[email protected]>
Date:   Tue Jan 23 00:46:19 2024 -0300

    Patch Ghostblock abuse

commit 60cc4d7
Author: AoElite <[email protected]>
Date:   Mon Jan 22 19:18:26 2024 -0500

    ensure grim sent the transaction in PacketEntityReplication

commit 70f6ea0
Author: AoElite <[email protected]>
Date:   Sun Jan 21 23:47:49 2024 -0500

    clear server entity positions on world change

commit 56c7d3f
Merge: d13351f 0a36d3e
Author: AoElite <[email protected]>
Date:   Sat Jan 20 22:34:12 2024 -0500

    Merge branch '2.0' of https://github.com/GrimAnticheat/Grim into 2.0

commit d13351f
Author: AoElite <[email protected]>
Date:   Sat Jan 20 22:34:00 2024 -0500

    don't queue tasks to be run on netty thread when on the netty thread

commit 0a36d3e
Merge: 1827672 aeaebed
Author: AoElite <[email protected]>
Date:   Thu Jan 18 13:57:21 2024 -0500

    Merge pull request GrimAnticheat#1305 from gNewl/patch-1

    Add missed PR in pt.yml

commit aeaebed
Author: gNewl <[email protected]>
Date:   Thu Jan 18 15:13:54 2024 -0300

    Limit timer balance

commit 1827672
Merge: 425a66b 7d8f931
Author: AoElite <[email protected]>
Date:   Wed Jan 17 11:45:36 2024 -0500

    Merge pull request GrimAnticheat#1301 from SamB440/feat/limit-timer-balance

    Limit timer balance

commit 7d8f931
Author: SamB440 <[email protected]>
Date:   Thu Dec 28 18:39:46 2023 +0000

    Limit timer balance

commit 425a66b
Merge: bf9689f a20e267
Author: AoElite <[email protected]>
Date:   Wed Jan 17 03:48:43 2024 -0500

    Merge pull request GrimAnticheat#1148 from MachineBreaker/ghostblock-abuse

    Patch Ghostblock abuse

commit bf9689f
Merge: 586cef9 0046cdd
Author: AoElite <[email protected]>
Date:   Wed Jan 17 03:47:09 2024 -0500

    Merge pull request GrimAnticheat#1144 from gNewl/2.0

    Add Portuguese Translations

commit 586cef9
Merge: 2046fb9 518642d
Author: AoElite <[email protected]>
Date:   Wed Jan 17 03:45:21 2024 -0500

    Merge pull request GrimAnticheat#1054 from booky10/fix/piglin-wall-heads

    Fix collision data for piglin wall heads

commit 2046fb9
Merge: 70005cf d516749
Author: AoElite <[email protected]>
Date:   Wed Jan 17 03:44:34 2024 -0500

    Merge pull request GrimAnticheat#985 from UserNugget/fix-981

    Fix GrimAnticheat#981

commit 70005cf
Merge: 9660021 e7ecf96
Author: AoElite <[email protected]>
Date:   Wed Jan 17 03:39:16 2024 -0500

    Merge pull request GrimAnticheat#1285 from z7087/checkemptyplace

    Do checks for empty places and use block

commit 9660021
Author: AoElite <[email protected]>
Date:   Sat Jan 6 16:30:19 2024 -0500

    make disconnect logging look better

commit 0046cdd
Author: gNewl <[email protected]>
Date:   Thu Jan 4 17:58:48 2024 -0300

    Fuck my keyboard

commit e7ecf96
Author: z7087 <[email protected]>
Date:   Thu Jan 4 23:30:40 2024 +0800

    Do checks for empty places and use block

commit 622f52b
Author: AoElite <[email protected]>
Date:   Wed Jan 3 13:46:49 2024 -0500

    bump version

commit df36b7d
Author: AoElite <[email protected]>
Date:   Tue Jan 2 13:22:18 2024 -0500

    bump version

commit 01e3630
Author: AoElite <[email protected]>
Date:   Tue Jan 2 13:21:39 2024 -0500

    inventory fixes for 1.20.3+

commit 02c3007
Author: AoElite <[email protected]>
Date:   Mon Jan 1 03:29:53 2024 -0500

    small optimization

commit ea11ec9
Author: AoElite <[email protected]>
Date:   Sun Dec 31 20:06:46 2023 -0500

    cache compensated inventory & packet entity replication getters

commit 6ede27b
Merge: 14b5983 b183c6a
Author: gNewl <[email protected]>
Date:   Sun Dec 31 21:28:50 2023 -0300

    Merge branch 'GrimAnticheat:2.0' into 2.0

commit 14b5983
Author: gNewl <[email protected]>
Date:   Sun Dec 31 21:26:30 2023 -0300

    Update pt.yml

    Fixed some stupid errors and some untranslated words

commit 0b40405
Author: gNewl <[email protected]>
Date:   Sun Dec 31 21:07:03 2023 -0300

    Update pt.yml

    Fixed some stupid past mistakes and some untranslated words

commit b183c6a
Author: AoElite <[email protected]>
Date:   Sun Dec 31 14:30:35 2023 -0500

    bump version

commit 3015cf9
Author: MWHunter <[email protected]>
Date:   Sun Dec 31 10:15:27 2023 -0600

    bump version

commit 93d89d2
Merge: e2ea6ad 11cb981
Author: MachineBreaker <[email protected]>
Date:   Sat Dec 30 11:21:16 2023 -0400

    Merge pull request GrimAnticheat#1280 from jonesdevelopment/2.0

    Use different hitbox values for 1.9+ (BadPacketsT)

commit 11cb981
Author: Michel Elkenwaat <[email protected]>
Date:   Sat Dec 30 15:06:13 2023 +0100

    fix: use different hitbox values for 1.9+

commit e2ea6ad
Author: AoElite <[email protected]>
Date:   Fri Dec 29 16:36:51 2023 -0500

    make BadPacketsR experimental

commit f863fed
Merge: e55fa8b b5e7dce
Author: AoElite <[email protected]>
Date:   Thu Dec 28 18:34:12 2023 -0500

    Merge pull request GrimAnticheat#1273 from z7087/crashG

    add CrashG

commit e55fa8b
Merge: 953ebf4 8c63a0b
Author: AoElite <[email protected]>
Date:   Thu Dec 28 18:33:31 2023 -0500

    Merge pull request GrimAnticheat#1274 from jonesdevelopment/2.0

    Implement BadPacketsT

commit 8c63a0b
Author: AoElite <[email protected]>
Date:   Thu Dec 28 18:31:28 2023 -0500

    Update BadPacketsT.java

commit 953ebf4
Author: AoElite <[email protected]>
Date:   Thu Dec 28 17:44:39 2023 -0500

    performance tweak

commit 86ac85d
Author: Michel Elkenwaat <[email protected]>
Date:   Thu Dec 28 16:15:11 2023 +0100

    feat: implement BadPacketsT

commit b5e7dce
Author: z7087 <[email protected]>
Date:   Thu Dec 28 11:29:52 2023 +0800

    add CrashG

commit 8ab62c4
Author: AoElite <[email protected]>
Date:   Wed Dec 27 18:11:20 2023 -0500

    remove experimental

commit 3203802
Author: AoElite <[email protected]>
Date:   Wed Dec 27 14:12:29 2023 -0500

    bump version

commit 0ae0d8a
Merge: 10a99fd 4c2f577
Author: AoElite <[email protected]>
Date:   Wed Dec 27 13:43:54 2023 -0500

    Merge pull request GrimAnticheat#1268 from GrimAnticheat/experimental-fastbreak-check

    Mark FastBreak as experimental

commit 10a99fd
Author: AoElite <[email protected]>
Date:   Wed Dec 27 05:34:59 2023 -0500

    InvalidPlace check

commit ab48248
Merge: edbb5b3 055e0d9
Author: AoElite <[email protected]>
Date:   Wed Dec 27 05:11:26 2023 -0500

    Merge branch '2.0' of https://github.com/GrimAnticheat/Grim into 2.0

commit edbb5b3
Author: AoElite <[email protected]>
Date:   Wed Dec 27 05:10:59 2023 -0500

    BadPacketsS

commit 4c2f577
Author: MachineBreaker <[email protected]>
Date:   Sun Dec 24 13:08:48 2023 -0400

    Mark FastBreak as experimental

    Seems to cause issues on newer versions

commit 055e0d9
Merge: 83450a2 b253bb7
Author: AoElite <[email protected]>
Date:   Wed Dec 20 14:45:13 2023 -0500

    Merge pull request GrimAnticheat#1258 from SamB440/fix/connection-state-crash

    Fix connection state crash

commit b253bb7
Author: SamB440 <[email protected]>
Date:   Wed Dec 20 17:35:34 2023 +0000

    Fix connection state crash

commit 83450a2
Merge: 649245a 13a4ee6
Author: AoElite <[email protected]>
Date:   Tue Dec 19 17:19:34 2023 -0500

    Merge pull request GrimAnticheat#1257 from Wruczek/2.0

    Fix FastBreak alert for players with nomodifypacket permission

commit 13a4ee6
Author: Wruczek <[email protected]>
Date:   Tue Dec 19 22:57:58 2023 +0100

    Fix FastBreak alert with no modify permission

commit 649245a
Merge: ce83748 d91b920
Author: AoElite <[email protected]>
Date:   Tue Dec 19 11:28:31 2023 -0500

    Merge pull request GrimAnticheat#1239 from SamB440/fix/legacy-side-connections

    Fix incorrect connecting block handling (legacy versions)

commit ce83748
Author: AoElite <[email protected]>
Date:   Fri Dec 15 11:51:28 2023 -0500

    make NegativeTimer experimental

commit 9d23406
Author: AoElite <[email protected]>
Date:   Fri Dec 15 11:51:11 2023 -0500

    remove Crash D & E from experimental

commit efd5107
Author: AoElite <[email protected]>
Date:   Wed Dec 13 19:19:58 2023 -0500

    bump version

commit 3339cdd
Author: AoElite <[email protected]>
Date:   Wed Dec 13 19:11:27 2023 -0500

    update packetevents to support 1.20.4

commit 27397f9
Merge: 2ab9b2b cc96781
Author: AoElite <[email protected]>
Date:   Sun Dec 10 13:11:05 2023 -0500

    Merge pull request GrimAnticheat#1240 from SamB440/fix/legacy-cave-vines

    Fix viaversion cave vines replacement on < 1.17

commit d91b920
Author: SamB440 <[email protected]>
Date:   Wed Dec 6 13:54:48 2023 +0000

    Fix incorrect connecting block handling (legacy versions)

commit 2ab9b2b
Merge: 2a534bf 0ea68dd
Author: AoElite <[email protected]>
Date:   Fri Dec 8 12:07:20 2023 -0500

    Merge pull request GrimAnticheat#1237 from SamB440/fix/disconnect-log

    Fix disconnect log message

commit cc96781
Author: SamB440 <[email protected]>
Date:   Wed Dec 6 14:16:04 2023 +0000

    Fix viaversion cave vines replacement on < 1.17

commit 0ea68dd
Author: SamB440 <[email protected]>
Date:   Tue Dec 5 15:53:42 2023 +0000

    Fix disconnect log message

commit 2a534bf
Merge: 3f65645 42775fd
Author: AoElite <[email protected]>
Date:   Sat Dec 2 17:42:22 2023 -0500

    Merge pull request GrimAnticheat#1234 from SamB440/fix/set-slot-bounds

    Readd slot bounds check but within player's inventory range

commit 42775fd
Author: SamB440 <[email protected]>
Date:   Sat Dec 2 13:40:29 2023 +0000

    Readd slot bounds check but within player's inventory range

commit d981cd9
Merge: b9c695b 3f65645
Author: gNewl <[email protected]>
Date:   Sat Dec 2 10:10:11 2023 -0300

    Merge branch 'GrimAnticheat:2.0' into 2.0

commit 3f65645
Merge: f24eba9 da8e639
Author: AoElite <[email protected]>
Date:   Sat Nov 25 18:57:16 2023 -0500

    Merge branch '2.0' of https://github.com/GrimAnticheat/Grim into 2.0

commit f24eba9
Author: AoElite <[email protected]>
Date:   Sat Nov 25 18:57:03 2023 -0500

    dead players don't send positions

commit da8e639
Merge: f5565df bfa95ce
Author: AoElite <[email protected]>
Date:   Thu Nov 23 11:23:38 2023 -0500

    Merge pull request GrimAnticheat#1227 from SamB440/fix/horse-jump

    Only reset horse jump when on ground

commit f5565df
Merge: 2f49a90 e31aee5
Author: AoElite <[email protected]>
Date:   Thu Nov 23 11:22:15 2023 -0500

    Merge pull request GrimAnticheat#1224 from SamB440/fix/inventory-slot-set

    Fix setting slots in player inventory

commit bfa95ce
Author: SamB440 <[email protected]>
Date:   Thu Nov 23 14:17:31 2023 +0000

    Only reset horse jump when on ground

commit 2f49a90
Author: AoElite <[email protected]>
Date:   Thu Nov 23 04:56:52 2023 -0500

    ignore spectators for BadPacketsR

commit 56882b3
Merge: b21d972 7c58dc7
Author: AoElite <[email protected]>
Date:   Wed Nov 22 20:38:46 2023 -0500

    Merge branch '2.0' of https://github.com/GrimAnticheat/Grim into 2.0

commit b21d972
Author: AoElite <[email protected]>
Date:   Wed Nov 22 20:38:36 2023 -0500

    check for valid transactions for post

commit af52b0e
Author: AoElite <[email protected]>
Date:   Wed Nov 22 20:35:35 2023 -0500

    tweak BadPacketsR

commit e31aee5
Author: SamB440 <[email protected]>
Date:   Wed Nov 22 13:22:06 2023 +0000

    Fix setting slots in player inventory

commit 7c58dc7
Merge: edc1596 925f352
Author: AoElite <[email protected]>
Date:   Wed Nov 22 06:14:52 2023 -0500

    Merge pull request GrimAnticheat#1222 from GrimAnticheat/2.0-slime-size-fix

    Don't let people set slime sizes to smaller than 1

commit 925f352
Author: MachineBreaker <[email protected]>
Date:   Wed Nov 22 06:13:08 2023 -0400

    Don't let people set slime sizes to smaller than 1

    Backported from 3.0

commit edc1596
Author: AoElite <[email protected]>
Date:   Tue Nov 21 20:21:23 2023 -0500

    bump version, add grim version to super debug log

commit 18e326c
Merge: 9ffac94 2dd46eb
Author: AoElite <[email protected]>
Date:   Tue Nov 21 20:19:48 2023 -0500

    Merge pull request GrimAnticheat#1221 from MachineBreaker/2.0-reach-check

    Improve Reach check

commit 9ffac94
Author: AoElite <[email protected]>
Date:   Tue Nov 21 20:05:17 2023 -0500

    recoded BadPacketsR

commit 2dd46eb
Author: MachineBreaker <[email protected]>
Date:   Tue Nov 21 12:48:14 2023 -0400

    Improve Reach check

    Backported from Grim 3.0

commit 3457c2f
Author: AoElite <[email protected]>
Date:   Tue Nov 21 10:37:34 2023 -0500

    fix InvalidA vehicle false

commit 14e4015
Merge: bc699fc c4d598a
Author: AoElite <[email protected]>
Date:   Tue Nov 21 10:01:20 2023 -0500

    Merge pull request GrimAnticheat#1220 from MachineBreaker/patch-13

    Add missing packet type for BadPacketsR

commit c4d598a
Author: MachineBreaker <[email protected]>
Date:   Tue Nov 21 11:00:05 2023 -0400

    Add missing packet type for BadPacketsR

commit bc699fc
Merge: 9355c6a de8ed60
Author: AoElite <[email protected]>
Date:   Tue Nov 21 08:39:21 2023 -0500

    Merge pull request GrimAnticheat#1219 from MachineBreaker/2.0-postcheck-fix

    Fix PostCheck falses

commit de8ed60
Author: MachineBreaker <[email protected]>
Date:   Tue Nov 21 09:35:41 2023 -0400

    Fix PostCheck falses

    Backported from Grim 3.0

commit 9355c6a
Author: AoElite <[email protected]>
Date:   Tue Nov 21 08:12:33 2023 -0500

    remove multiLib & use our own util, so we can compile with Java 8

commit 8560d82
Author: AoElite <[email protected]>
Date:   Tue Nov 21 07:51:05 2023 -0500

    bump version

commit 41df730
Merge: 0543de2 ba314b7
Author: AoElite <[email protected]>
Date:   Tue Nov 21 07:44:05 2023 -0500

    Merge pull request GrimAnticheat#1218 from MachineBreaker/2.0-packet-canceller-check

    Check for basic packet canceller

commit ba314b7
Author: MachineBreaker <[email protected]>
Date:   Tue Nov 21 08:38:29 2023 -0400

    Check for basic packet canceller

    Fixes GrimAnticheat#1215
    Done by AoElite

commit 0543de2
Author: AoElite <[email protected]>
Date:   Fri Nov 17 08:46:17 2023 -0500

    fix brands for 1.20.2 clients

commit b9c695b
Merge: b5c86e9 919bd4f
Author: gNewl <[email protected]>
Date:   Wed Nov 15 19:55:08 2023 -0300

    Merge branch 'GrimAnticheat:2.0' into 2.0

commit d516749
Author: UserNugget <[email protected]>
Date:   Thu Sep 28 09:22:10 2023 +0300

    Include missing change from initial commit

commit b5c86e9
Author: gNewl <[email protected]>
Date:   Sun Sep 24 15:18:28 2023 -0300

    Updated translations to be compatible with the last commit.

commit 14df3e3
Author: gNewl <[email protected]>
Date:   Sun Sep 24 15:18:06 2023 -0300

    Updated translations to be compatible with the last commits and fixed some grammatical errors.

commit a20e267
Author: noobi <[email protected]>
Date:   Sun Sep 24 20:16:06 2023 +0200

    Reduce isChunkLoaded calls

commit 799da6d
Merge: d336c9c 16f2e54
Author: gNewl <[email protected]>
Date:   Sun Sep 24 14:57:46 2023 -0300

    Merge branch 'GrimAnticheat:2.0' into 2.0

commit 09dd9cb
Merge: 6ce4961 16f2e54
Author: noobi <[email protected]>
Date:   Sun Sep 24 17:42:30 2023 +0200

    Merge branch '2.0' into ghostblock-abuse

    # Conflicts:
    #	src/main/java/ac/grim/grimac/manager/CheckManager.java

commit 6ce4961
Author: noobi <[email protected]>
Date:   Sun Sep 24 17:29:46 2023 +0200

    Hotfix isChunkLoaded x2

commit 1ec4e3a
Author: noobi <[email protected]>
Date:   Sun Sep 24 17:23:03 2023 +0200

    Hotfix isChunkLoaded

commit d336c9c
Merge: dcba224 22862d1
Author: gNewl <[email protected]>
Date:   Sun Sep 17 10:33:02 2023 -0300

    Merge branch 'GrimAnticheat:2.0' into 2.0

commit 2bc7ade
Author: UserNugget <[email protected]>
Date:   Sat Sep 16 14:43:36 2023 +0300

    Simulate an intermediate state if a player is riding a boat, but not moving

    Packet is using inputs, calculated in that way:

    {
      int steeringForward = 0;

      // steering will be 0 if "movingForward" and "movingBackwards" will be true
      if (movingForward) steeringForward += 1;
      if (movingBackwards) steeringForward -= 1;

      if (sneaking) steeringForward *= 0.98;
    }

    But at the same time, a boat is using `movingForward` and `movingBackwards` directly, ignoring `steeringForward`, so the player still can control it while the packet shows that player is standing

    Fixes GrimAnticheat#981

commit 03d87ce
Author: noobi <[email protected]>
Date:   Wed Sep 13 19:17:11 2023 +0200

    Adjust german comments

commit c1111f1
Author: noobi <[email protected]>
Date:   Mon Sep 11 02:40:31 2023 +0200

    Only resync when no exception

commit 2be7cbe
Author: noobi <[email protected]>
Date:   Mon Sep 11 01:57:28 2023 +0200

    Correct max limit value

commit 19307d6
Author: noobi <[email protected]>
Date:   Mon Sep 11 01:55:46 2023 +0200

    Better usage of variable name to

commit 2cc4184
Author: noobi <[email protected]>
Date:   Mon Sep 11 01:53:57 2023 +0200

    Forgot to actually make it defaultly disabled

commit e95ad14
Author: noobi <[email protected]>
Date:   Mon Sep 11 01:52:49 2023 +0200

    Make distance configureable, implement try catch and ignore exception, disable by default and remove experimental, check if chunk loaded

commit a823ccd
Author: noobi <[email protected]>
Date:   Sun Sep 10 15:46:10 2023 +0200

    Update en.yml

commit ea4de77
Author: noobi <[email protected]>
Date:   Sun Sep 10 15:27:05 2023 +0200

    Fix format once more

commit 44172ac
Author: noobi <[email protected]>
Date:   Sun Sep 10 15:26:12 2023 +0200

    Reuse block coordinates, fix format, add more comments to config

commit 036b476
Author: noobi <[email protected]>
Date:   Sun Sep 10 07:25:11 2023 +0200

    Make experimental

commit f55763a
Author: noobi <[email protected]>
Date:   Sun Sep 10 07:10:38 2023 +0200

    Readd newline in configs (removed by accident)

commit 19a569f
Author: noobi <[email protected]>
Date:   Sun Sep 10 07:09:03 2023 +0200

    Implement GhostBlockMitigation

commit dcba224
Author: gNewl <[email protected]>
Date:   Thu Sep 7 19:03:01 2023 -0300

    Added Portuguese Translations

commit 2a24348
Author: gNewl <[email protected]>
Date:   Thu Sep 7 19:02:30 2023 -0300

    Added Portuguese Translations

commit 248a16d
Author: gNewl <[email protected]>
Date:   Thu Sep 7 19:01:55 2023 -0300

    Added Portuguese Translations

commit 523b677
Author: gNewl <[email protected]>
Date:   Thu Sep 7 19:00:08 2023 -0300

    Added Portuguese Translations

commit 518642d
Author: booky10 <[email protected]>
Date:   Fri Jun 16 12:12:02 2023 +0200

    Fix collision data for piglin wall heads
  • Loading branch information
FloLoFlo committed Apr 14, 2024
1 parent 433a6c8 commit 1c3ad19
Show file tree
Hide file tree
Showing 22 changed files with 465 additions and 58 deletions.
2 changes: 1 addition & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ plugins {


group = "ac.grim.grimac"
version = "2.3.60"
version = "2.3.61"
description = "Libre simulation anticheat designed for 1.20 with 1.8-1.20 support, powered by PacketEvents 2.0."
java.sourceCompatibility = JavaVersion.VERSION_1_8
java.targetCompatibility = JavaVersion.VERSION_1_8
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
package ac.grim.grimac.checks.impl.badpackets;

import ac.grim.grimac.checks.Check;
import ac.grim.grimac.checks.CheckData;
import ac.grim.grimac.checks.type.PacketCheck;
import ac.grim.grimac.player.GrimPlayer;
import ac.grim.grimac.utils.data.packetentity.PacketEntity;
import com.github.retrooper.packetevents.event.PacketReceiveEvent;
import com.github.retrooper.packetevents.protocol.entity.type.EntityTypes;
import com.github.retrooper.packetevents.protocol.packettype.PacketType;
import com.github.retrooper.packetevents.protocol.player.ClientVersion;
import com.github.retrooper.packetevents.wrapper.play.client.WrapperPlayClientInteractEntity;

@CheckData(name = "BadPacketsM", experimental = true)
public class BadPacketsM extends Check implements PacketCheck {
public BadPacketsM(final GrimPlayer player) {
super(player);
}

// 1.7 players do not send INTERACT_AT, so we cannot check them
private final boolean exempt = player.getClientVersion().isOlderThanOrEquals(ClientVersion.V_1_7_10);
private boolean sentInteractAt = false;

@Override
public void onPacketReceive(PacketReceiveEvent event) {
if (event.getPacketType() == PacketType.Play.Client.INTERACT_ENTITY) {
if (exempt) return;

WrapperPlayClientInteractEntity wrapper = new WrapperPlayClientInteractEntity(event);

PacketEntity entity = player.compensatedEntities.entityMap.get(wrapper.getEntityId());

// For armor stands, vanilla clients send:
// - when renaming the armor stand or in spectator mode: INTERACT_AT + INTERACT
// - in all other cases: only INTERACT
// Just exempt armor stands to be safe
if(entity != null && entity.type == EntityTypes.ARMOR_STAND) return;

switch (wrapper.getAction()) {
// INTERACT_AT then INTERACT
case INTERACT:
if (!sentInteractAt) {
if (flagAndAlert("Missed Interact-At") && shouldModifyPackets()) {
event.setCancelled(true);
player.onPacketCancel();
}
}
sentInteractAt = false;
break;
case INTERACT_AT:
if (sentInteractAt) {
if (flagAndAlert("Missed Interact") && shouldModifyPackets()) {
event.setCancelled(true);
player.onPacketCancel();
}
}
sentInteractAt = true;
break;
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -20,16 +20,12 @@ public void onPacketReceive(PacketReceiveEvent event) {
if (event.getPacketType() == Client.ENTITY_ACTION) {
WrapperPlayClientEntityAction wrapper = new WrapperPlayClientEntityAction(event);

if (wrapper.getAction() == Action.START_JUMPING_WITH_HORSE) {
if (wrapper.getJumpBoost() < 0 || wrapper.getJumpBoost() > 100) {
if (flag()) {
alert("b=" + wrapper.getJumpBoost()); // Ban
if (shouldModifyPackets()) {
event.setCancelled(true);
}
}
if (wrapper.getJumpBoost() < 0 || wrapper.getJumpBoost() > 100 || wrapper.getEntityId() != player.entityID || (wrapper.getAction() != Action.START_JUMPING_WITH_HORSE && wrapper.getJumpBoost() != 0)) {
if (flagAndAlert("boost=" + wrapper.getJumpBoost() + ", action=" + wrapper.getAction() + ", entity=" + wrapper.getEntityId()) && shouldModifyPackets()) {
event.setCancelled(true);
player.onPacketCancel();
}
}
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
package ac.grim.grimac.checks.impl.badpackets;

import ac.grim.grimac.checks.Check;
import ac.grim.grimac.checks.CheckData;
import ac.grim.grimac.checks.type.PacketCheck;
import ac.grim.grimac.player.GrimPlayer;
import com.github.retrooper.packetevents.event.PacketReceiveEvent;
import com.github.retrooper.packetevents.protocol.packettype.PacketType;
import com.github.retrooper.packetevents.protocol.player.ClientVersion;
import com.github.retrooper.packetevents.protocol.world.BlockFace;
import com.github.retrooper.packetevents.util.Vector3f;
import com.github.retrooper.packetevents.util.Vector3i;
import com.github.retrooper.packetevents.wrapper.play.client.WrapperPlayClientPlayerBlockPlacement;

@CheckData(name = "BadPacketsU", experimental = true)
public class BadPacketsU extends Check implements PacketCheck {
public BadPacketsU(GrimPlayer player) {
super(player);
}

@Override
public void onPacketReceive(final PacketReceiveEvent event) {
if (event.getPacketType() == PacketType.Play.Client.PLAYER_BLOCK_PLACEMENT) {
final WrapperPlayClientPlayerBlockPlacement packet = new WrapperPlayClientPlayerBlockPlacement(event);
// BlockFace.OTHER is USE_ITEM for pre 1.9
if (packet.getFace() == BlockFace.OTHER) {

// This packet is always sent at (-1, -1, -1) at (0, 0, 0) on the block
// except y gets wrapped?
final int expectedY = player.getClientVersion().isNewerThanOrEquals(ClientVersion.V_1_8) ? 4095 : 255;

// never sent when not holding anything
final boolean failedItemCheck = packet.getItemStack().isPresent() && packet.getItemStack().get().isEmpty()
// ViaVersion can sometimes cause this part of the check to false
&& player.getClientVersion().isOlderThan(ClientVersion.V_1_9);

final Vector3i pos = packet.getBlockPosition();
final Vector3f cursor = packet.getCursorPosition();

if (failedItemCheck
|| pos.x != -1
|| pos.y != expectedY
|| pos.z != -1
|| cursor.x != 0
|| cursor.y != 0
|| cursor.z != 0
|| packet.getSequence() != 0
) {
final String verbose = String.format(
"xyz=%s, %s, %s, cursor=%s, %s, %s, item=%s, sequence=%s",
pos.x, pos.y, pos.z, cursor.x, cursor.y, cursor.z, !failedItemCheck, packet.getSequence()
);
if (flagAndAlert(verbose) && shouldModifyPackets()) {
player.onPacketCancel();
event.setCancelled(true);
}
}
}
}
}
}
4 changes: 2 additions & 2 deletions src/main/java/ac/grim/grimac/checks/impl/post/PostCheck.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
import com.github.retrooper.packetevents.protocol.packettype.PacketType;
import com.github.retrooper.packetevents.protocol.packettype.PacketTypeCommon;
import com.github.retrooper.packetevents.protocol.player.ClientVersion;
import com.github.retrooper.packetevents.wrapper.play.client.WrapperPlayClientEntityAction;
import com.github.retrooper.packetevents.wrapper.play.client.WrapperPlayClientPlayerFlying;
import com.github.retrooper.packetevents.wrapper.play.server.WrapperPlayServerEntityAnimation;

Expand Down Expand Up @@ -99,8 +100,7 @@ public void onPacketReceive(final PacketReceiveEvent event) {
&& isExemptFromSwingingCheck < player.lastTransactionReceived.get()) { // Exempt when the server sends animations because viaversion
if (sentFlying) post.add(event.getPacketType());
} else if (ENTITY_ACTION.equals(packetType) // ViaRewind sends START_FALL_FLYING packets async for 1.8 clients on 1.9+ servers
&& ((player.getClientVersion().isNewerThanOrEquals(ClientVersion.V_1_9) // ViaRewind doesn't 1.9 players
|| PacketEvents.getAPI().getServerManager().getVersion().isOlderThanOrEquals(ServerVersion.V_1_8_8)))) { // No elytras
&& (player.getClientVersion().isNewerThanOrEquals(ClientVersion.V_1_9) || new WrapperPlayClientEntityAction(event).getAction() != WrapperPlayClientEntityAction.Action.START_FLYING_WITH_ELYTRA)) {
// https://github.com/GrimAnticheat/Grim/issues/824
if (player.getClientVersion().isNewerThanOrEquals(ClientVersion.V_1_19_3) && player.compensatedEntities.getSelf().getRiding() != null) {
return;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,38 +1,25 @@
package ac.grim.grimac.checks.impl.scaffolding;

import ac.grim.grimac.checks.Check;
import ac.grim.grimac.checks.CheckData;
import ac.grim.grimac.checks.type.PacketCheck;
import ac.grim.grimac.checks.type.BlockPlaceCheck;
import ac.grim.grimac.player.GrimPlayer;
import com.github.retrooper.packetevents.event.PacketReceiveEvent;
import com.github.retrooper.packetevents.protocol.packettype.PacketType;
import ac.grim.grimac.utils.anticheat.update.BlockPlace;
import com.github.retrooper.packetevents.util.Vector3f;
import com.github.retrooper.packetevents.wrapper.play.client.WrapperPlayClientPlayerBlockPlacement;

@CheckData(name = "InvalidPlace")
public class InvalidPlace extends Check implements PacketCheck {

public class InvalidPlace extends BlockPlaceCheck {
public InvalidPlace(GrimPlayer player) {
super(player);
}

@Override
public void onPacketReceive(PacketReceiveEvent event) {
if (event.getPacketType() == PacketType.Play.Client.PLAYER_BLOCK_PLACEMENT) {
WrapperPlayClientPlayerBlockPlacement wrapper = new WrapperPlayClientPlayerBlockPlacement(event);
Vector3f cursor = wrapper.getCursorPosition();
if (cursor == null) return;
if (invalid(cursor.getX()) || invalid(cursor.getY()) || invalid(cursor.getZ())) {
if (flag() && shouldModifyPackets()) {
event.setCancelled(true);
player.onPacketCancel();
}
public void onBlockPlace(final BlockPlace place) {
Vector3f cursor = place.getCursor();
if (cursor == null) return;
if (!Float.isFinite(cursor.getX()) || !Float.isFinite(cursor.getY()) || !Float.isFinite(cursor.getZ())) {
if (flagAndAlert() && shouldModifyPackets() && shouldCancel()) {
place.resync();
}
}
}

private boolean invalid(float value) {
return Float.isInfinite(value) || Float.isNaN(value);
}

}
4 changes: 3 additions & 1 deletion src/main/java/ac/grim/grimac/manager/CheckManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -80,13 +80,14 @@ public CheckManager(GrimPlayer player) {
.put(BadPacketsJ.class, new BadPacketsJ(player))
.put(BadPacketsK.class, new BadPacketsK(player))
.put(BadPacketsL.class, new BadPacketsL(player))
.put(BadPacketsM.class, new BadPacketsM(player))
.put(BadPacketsN.class, new BadPacketsN(player))
.put(BadPacketsP.class, new BadPacketsP(player))
.put(BadPacketsQ.class, new BadPacketsQ(player))
.put(BadPacketsR.class, new BadPacketsR(player))
.put(BadPacketsS.class, new BadPacketsS(player))
.put(BadPacketsT.class, new BadPacketsT(player))
.put(InvalidPlace.class, new InvalidPlace(player))
.put(BadPacketsU.class, new BadPacketsU(player))
.put(FastBreak.class, new FastBreak(player))
.put(TransactionOrder.class, new TransactionOrder(player))
.put(NoSlowB.class, new NoSlowB(player))
Expand Down Expand Up @@ -126,6 +127,7 @@ public CheckManager(GrimPlayer player) {
.build();

blockPlaceCheck = new ImmutableClassToInstanceMap.Builder<BlockPlaceCheck>()
.put(InvalidPlace.class, new InvalidPlace(player))
.put(AirLiquidPlace.class, new AirLiquidPlace(player))
.put(FarPlace.class, new FarPlace(player))
.put(FabricatedPlace.class, new FabricatedPlace(player))
Expand Down
17 changes: 11 additions & 6 deletions src/main/java/ac/grim/grimac/manager/PunishmentManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
public class PunishmentManager {
GrimPlayer player;
List<PunishGroup> groups = new ArrayList<>();
String experimentalSymbol = "*";

public PunishmentManager(GrimPlayer player) {
this.player = player;
Expand All @@ -29,6 +30,7 @@ public PunishmentManager(GrimPlayer player) {
public void reload() {
DynamicConfig config = GrimAPI.INSTANCE.getConfigManager().getConfig();
List<String> punish = config.getStringListElse("Punishments", new ArrayList<>());
experimentalSymbol = config.getStringElse("experimental-symbol", "*");

try {
groups.clear();
Expand Down Expand Up @@ -93,12 +95,15 @@ private String replaceAlertPlaceholders(String original, PunishGroup group, Chec
// Streams are slow but this isn't a hot path... it's fine.
String vl = group.violations.values().stream().filter((e) -> e == check).count() + "";

original = original.replace("[alert]", alertString);
original = original.replace("[proxy]", alertString);
original = original.replace("%check_name%", check.getCheckName());
original = original.replace("%vl%", vl);
original = original.replace("%verbose%", verbose);
original = MessageUtil.format(original);
original = MessageUtil.format(original
.replace("[alert]", alertString)
.replace("[proxy]", alertString)
.replace("%check_name%", check.getCheckName())
.replace("%experimental%", check.isExperimental() ? experimentalSymbol : "")
.replace("%vl%", vl)
.replace("%verbose%", verbose)
);

original = GrimAPI.INSTANCE.getExternalAPI().replaceVariables(player, original, true);

return original;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
import lombok.Getter;
import lombok.Setter;
import org.bukkit.util.Vector;
import org.jetbrains.annotations.Nullable;

import java.util.ArrayList;
import java.util.Arrays;
Expand All @@ -57,7 +58,7 @@ public class BlockPlace {
@Getter
StateType material;
@Getter
HitData hitData;
@Nullable HitData hitData;
@Setter
BlockFace face;
@Getter
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ public static boolean consumesPlace(GrimPlayer player, WrappedBlockState state,

private static boolean goodBellHit(WrappedBlockState bell, BlockPlace place) {
BlockFace direction = place.getDirection();
return isProperHit(bell, direction, place.getHitData().getRelativeBlockHitLocation().getY());
return place.getHitData() != null && isProperHit(bell, direction, place.getHitData().getRelativeBlockHitLocation().getY());
}

private static boolean isProperHit(WrappedBlockState bell, BlockFace direction, double p_49742_) {
Expand Down
Loading

0 comments on commit 1c3ad19

Please sign in to comment.