feat(AutoMount): Add AutoMount module#240
feat(AutoMount): Add AutoMount module#240IceTank wants to merge 3 commits intolambda-client:1.21.11from
Conversation
|
Not tested yet |
|
Works now |
src/main/kotlin/com/lambda/module/modules/movement/AutoMount.kt
Outdated
Show resolved
Hide resolved
src/main/kotlin/com/lambda/module/modules/movement/AutoMount.kt
Outdated
Show resolved
Hide resolved
src/main/kotlin/com/lambda/module/modules/movement/AutoMount.kt
Outdated
Show resolved
Hide resolved
src/main/kotlin/com/lambda/module/modules/movement/AutoMount.kt
Outdated
Show resolved
Hide resolved
src/main/kotlin/com/lambda/module/modules/movement/AutoMount.kt
Outdated
Show resolved
Hide resolved
| transitive-accessible field net/minecraft/registry/SimpleRegistry frozen Z | ||
|
|
||
| # AutoMount | ||
| accessible method net/minecraft/entity/Entity canAddPassenger (Lnet/minecraft/entity/Entity;)Z |
There was a problem hiding this comment.
this can just be placed under the # Entity group
| if (autoMountEntities && player.vehicle == null) { | ||
| runSafeAutomated { | ||
| val entity = fastEntitySearch<Entity>(10.0) { | ||
| autoMountEntityList.contains(it.type) && canRide(it) && it.findRotation(range, player.eyePos) != null |
There was a problem hiding this comment.
I think its best to have a rotation setting as currently this checks if its possible for a valid rotation but doesnt perform it.
There was a problem hiding this comment.
That is only to check if the entity is within range as all the other checks I tried didn't work
There was a problem hiding this comment.
yeah but this module wont work on grim tho? Might as well have an option for rotations as you already have the logic for getting the rotation
src/main/kotlin/com/lambda/module/modules/movement/AutoMount.kt
Outdated
Show resolved
Hide resolved
| } | ||
|
|
||
| private fun SafeContext.interactEntity(entity: Entity) { | ||
| mc.networkHandler?.sendPacket(PlayerInteractEntityC2SPacket.interactAt(entity, false, Hand.MAIN_HAND, Vec3d(0.5, 0.5, 0.5))) |
There was a problem hiding this comment.
ideally we should fill the parameters with accurate data like player.isSneaking instead of false
There was a problem hiding this comment.
This would cause the module to fail to mount entities while the player is sneaking
There was a problem hiding this comment.
could this potentially cause anticheat conflicts tho? Maybe a setting for override sneak or something
src/main/kotlin/com/lambda/module/modules/movement/AutoMount.kt
Outdated
Show resolved
Hide resolved
|
oh yeah, also use connection inside of SafeContext rather than mc.networkHandler |
Add AutoMount module to automatically mount or remount entities