@asd-dsa
hmm actually in some cases (when the arrow is heading to the player's head/foot) it has a big possibility of not triggering it (should be able to fix it by checking intersection between 2 bbox).
Iirc it should have a horizontal speed mode, but it is annoying to lock the view.
The code is spaghetti, but I would try to improve it when I have time. (Probably in a few days)
Best posts made by commandblock2
-
RE: [Request] Arrow avoidance script (like Enderman)
-
RE: [Request] Arrow avoidance script (like Enderman)
@asd-dsa
Yes but the challenging part is to make it theblink
way. This is definitely fine and good work.blink
teleport is kind of holding the movement packets and sending them in a instant, but the currentsetPosition
is more like the clip thing (some ac may flag you for speed).
If you want to have it this way you might have to calculate the positions of the position packets in advance (and probably lower the timer(< 1) after dodging the arrow in case the ac flags you for timer).btw we can make the tp direction perpendicular to the velocity of the incoming arrow, and see left/right is closer. (This would be easier than
blink
and already inhorizontalSpeed
mode). Alsoleft
/right
variable in that part might not be reallyleft
/right
, it could be opposite.Anyway the scripts was originally for trolling only, never thought someone would need it but I am happy to see someone actually used it.
Also +1 for the effort. -
RE: [Request] Arrow avoidance script (like Enderman)
@asd-dsa
I see, the version you used is the cross version. The script was designed for none cross version 1.8. Quite surprising it was still working with other mode. If you want to use that you might need to have extra modification since the cross version has some changes in scriptAPI.
Edit: But according to this exception, it seemed to be the one in render3D which should cause the whole script (anymode and the prediction) to break
Edit: nvm I was dumb this exception shouldn't affect might be other exception -
RE: [Request] Arrow avoidance script (like Enderman)
@asd-dsa
it doesn't sound like some problem with your version, I think it's very much probably my fault. Will later look into it -
RE: How to tell a module is on or off?
@chodeman
What I have been trying to do is to changeScreenShotHelper.saveScreenshot(this.mcDataDir, this.displayWidth, this.displayHeight, this.framebufferMc)
to js.
Since it is in
net/minecraft/client/Minecraft.java
, the type ofthis
isMinecraft
(akanet.minecraft.client.Minecraft
). And the instance ofMinecraft
is exposed asmc
in scriptAPI.
So we change allthis
tomc
.
ButframebufferMc
is not public so you cannot access it from a script.
So we accessing a private variable using reflection.
However the name offramebufferMc
is notframebufferMc
.
See about obfuscation.
You will have to use the Searge name(field_147124_at
) to access variable and functions.
The filemcp-stable_22.srg
have the mappings from MCP name to Searge name.
The reason you can use MCP name to in normal scriptAPI is because they did this.But with Core.lib you don't have to do that anymore.
@CzechHek
THANK YOU BASED HEK. Don't have to look for srg name anymore.
And that should even solved the problem of using script in development environment, going to try it later. -
RE: [Request] Arrow avoidance script (like Enderman)
@asd-dsa
quite weird, works on my machine. But usually in this case you can look into the logs to see if the script is spamming exception. The log should be at .minecraft/logs/latest.log
Idk if it only works on my build.
Edit: the snippet I posted in the last post was only to tell you what the new code is for, still recommended to pull the full script from github. This what has been changed actually. -
RE: Help writing a custom prison mining script
A way to path find from /mine to the mining location
This could be a bit much work to do. U might have to write a path finding algorithm like A*. However I do have a A* in my
reachaura
branch. Could be hell if u try to write it in js.A 'legit' mining mode (I know how to activate modules via script so I might just use nuker)
Look for
RotationUtils.faceBlock
method inNuker.kt
in LB's src (cross_version
here), it would be a bit different with/withoutcross_version
.Check if inventory is full
Maybe look at the inventory related module of LB and Hek's InventoryManger. Shouldn't be as hard as A*.
Interact/Right Click NPC
There is a packet for that and u can find the usage in
KillAura.kt
.Text related operation
https://github.com/CzechHek/Core/blob/master/Scripts/Deprecated/BasicLogin.js
-
RE: BlockBBEvent in scripts?
@idk-my-name
Indeed there is noonBlockBB
provided.
Before this someone showed me the matrix fly (rewinside + jump, patched) made by aftery in scriptapi(obf), it would be almost impossible to implement without blockBB. I didn't figure out back then
It took me a long time to finally figured out a way to subscribe to arbitrary event in scriptAPI with reflection andJava.extend
.
Hint:Java.extend(Listenable, Consumer, { handleEvents: function() { return true}, accept: function(e) { } })
and this.
-
RE: How to tell a module is on or off?
@commandblock2
do this.minecraft/LiquidBounce-1.8 $ grep framebufferMc mcp-stable_22.srg FD: net/minecraft/client/Minecraft/framebufferMc net/minecraft/client/Minecraft/field_147124_at
and get
field_147124_at
.
then you have thisScreenShotHelper = Java.type("net.minecraft.util.ScreenShotHelper") function screenShot() { framebufferMcField = mc.class.getDeclaredField("field_147124_at") framebufferMcField.setAccessible(true) framebufferMc = framebufferMcField.get(mc) //with Core.lib you only need 1 line //framebufferMc = getField(mc, "field_147124_at").get(mc) ScreenShotHelper.saveScreenshot(mc.mcDataDir, mc.displayWidth, mc.displayHeight, framebufferMc); }
-
RE: [Request] Arrow avoidance script (like Enderman)
@asd-dsa
now the script is updated with horizontaltp and horizontalmotion. The direction is perpendicular to arrow trajectory.But there is not yet a check for tp into blocks, and still sometimes you could get shot. Might just going to look into
FallingPlayer
/Projectiles
for reference.Edit: hmm the it should be same as Projectiles but still strange, maybe later then.
the related code is here, but that is spaghetti anyway. you might want to give time the sin/cos since I think it might be a bit long.
if (dodgeMode.get() == "HorizontalTp") { mc.thePlayer.setPosition(mc.thePlayer.posX + Math.sin(Math.toRadians(rot.yaw)), mc.thePlayer.posY, mc.thePlayer.posZ + Math.cos(Math.toRadians(rot.yaw))) dodging = null return } if (dodgeMode.get() == "HorizontalMotion") { mc.thePlayer.motionX = Math.sin(Math.toRadians(rot.yaw)) // * 0.5 // or something like that mc.thePlayer.motionZ = Math.cos(Math.toRadians(rot.yaw)) dodging = null return }
Latest posts made by commandblock2
-
RE: [JS]TeleportAura 0.5demo(By Mumy)(updated)
@yorik100 is it capable of doing hclip? like the mineplex phase lmao, that would require you to cancel the S08 if you know where exactly the server would send you the S08
-
RE: Verus hitbox
@batata said in Verus hitbox:
case "C03 Cancel":
if(e.getPacket() instanceof C02PacketUseEntity) {
if(mc.thePlayer.ticksExisted % 3 != 0) {
e.cancelEvent();
idk, try thiscase "C03 Cancel": if(e.getPacket() instanceof C02PacketUseEntity && e.getPacket().getAction() == C02PacketUseEntity.Action.INTERACT_AT) { // INTERACT_AT or INTERACT or idk e.cancelEvent();
-
RE: Verus hitbox
@batata
idk if verus will detect if you just cancel the C02 interact packet but not the C08/C07 packet. you won't even need to disable hitbox if that works -
RE: Please help meeee i need a script
@max-0
indeed there is a possibility, but it is likely no one will look into it, but if you can it would be too much to do in the scriptapi and very much likely would have a worse performance, if you just modify the src instead it would be much easier in this case -
RE: please stop using random liquidbounce forks. (also fact of the day 6)
@aftery I can't tell if this is a bait, because I don't know anything specific about it. But I still wonder what it has
-
RE: Config for Killaura
@lol_-i_know_that_you_see_this
No wonder, I guess thethis.rotationYaw
should be smt likeRotationManager.currentRotation
orRotationManager.serverRotation
's yaw -
RE: [Tutorial]How to debug your scripts in IntelliJ IDEA
Intellij idea
Ultimate
only -
RE: Config for Killaura
@lol_-i_know_that_you_see_this
I was saying theAtom One Dark Theme
. But yes, white theme sometimes hurt eyes. -
RE: Config for Killaura
@lol_-i_know_that_you_see_this
Everyone is using one dark lmao