mirror of https://github.com/kami-blue/client
Apply suggestions from code review
This commit is contained in:
parent
61a358c546
commit
7a03990a93
|
@ -322,6 +322,7 @@ internal object CrystalAura : Module(
|
|||
val side = getClosestVisibleSide(pos) ?: EnumFacing.UP
|
||||
return CPacketPlayerTryUseItemOnBlock(pos, side, hand, 0.5f, placeOffset, 0.5f)
|
||||
}
|
||||
|
||||
private fun SafeClientEvent.packetExplode(entityID: Int, pos: BlockPos, vec3d: Vec3d) {
|
||||
if (!preExplode()) return
|
||||
|
||||
|
@ -566,4 +567,4 @@ internal object CrystalAura : Module(
|
|||
lastLookAt = CombatManager.target?.positionVector ?: Vec3d.ZERO
|
||||
}
|
||||
/* End of rotation */
|
||||
}
|
||||
}
|
||||
|
|
|
@ -141,8 +141,6 @@ fun SafeClientEvent.getClosestVisibleSide(pos: BlockPos): EnumFacing? {
|
|||
|
||||
/**
|
||||
* Get the "visible" sides related to player's eye position
|
||||
*
|
||||
* Reverse engineered from HauseMaster's anti cheat plugin
|
||||
*/
|
||||
fun SafeClientEvent.getVisibleSides(pos: BlockPos, assumeAirAsFullBox: Boolean = false): Set<EnumFacing> {
|
||||
val visibleSides = EnumSet.noneOf(EnumFacing::class.java)
|
||||
|
|
Loading…
Reference in New Issue