Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

1.11.2 Elytra Boost Freezing (fireworks, rockets) #347

Closed
MidnightSugar opened this Issue Dec 21, 2016 · 35 comments

Comments

Projects
None yet
10 participants
@MidnightSugar
Copy link

MidnightSugar commented Dec 21, 2016

[####] Short description of the issue.
When firework rockets are used to boost elytras, they are frozen in place, causing very odd flight.

Complete output of the ncp version command (please prefer text here).

21.12 18:04:12 [Server] INFO ---- Version information ----
21.12 18:04:12 [Server] INFO #### Server ####
21.12 18:04:12 [Server] INFO git-Spigot-7d78b81-a867313 MC: 1.11.2
21.12 18:04:12 [Server] INFO detected: 1.11.2
21.12 18:04:12 [Server] INFO #### NoCheatPlus ####
21.12 18:04:12 [Server] INFO Plugin: 3.15.0-SNAPSHOT-sMD5NET-b1046
21.12 18:04:12 [Server] INFO MCAccess: 1.4.5-1.11|? / CB-Reflect
21.12 18:04:12 [Server] INFO Features:
21.12 18:04:12 [Server] INFO blocks: BlocksMC1_4 | BlocksMC1_5 | BlocksMC1_6_1 | BlocksMC1_7_2 | BlocksMC1_8 | BlocksMC1_9 | BlocksMC1_10 | BlocksMC1_11
21.12 18:04:12 [Server] INFO checks: FastConsume | Gutenberg | HotFixFallingBlockPortalEnter | AttackFrequency | FlyingFrequency | KeepAliveFrequency
21.12 18:04:12 [Server] INFO defaults: pvpKnockBackVelocity
21.12 18:04:12 [Server] INFO packet-listeners: UseEntityAdapter | MovingFlying | OutgoingPosition | KeepAliveAdapter | SoundDistance
21.12 18:04:12 [Server] INFO Hooks: AllViolationsNCP 1.0 | mcMMOcncp 2.3
21.12 18:04:12 [Server] INFO #### Related Plugins ####
21.12 18:04:12 [Server] INFO CompatNoCheatPlus v6.6.3-SNAPSHOT-sMD5NET-b86 | ProtocolLib v4.2.0

How to reproduce the issue (is it random / always happens / side conditions)?

Use rockets while gliding with the elytra. It always happens. I tried using the default configuration for the latest version of NCP, and people couldn't fly with elytras at all.

Have you made any (noteworthy) changes to the default configuration of NCP?

I use the latest version of the config here:
http://www.mc-market.org/resources/475/
I do not have permission to post the config here.

Do you run any other special plugins that affect game mechanics next to NC+ (adding skills, machines, adding/changing blocks, other anti cheating)?

I have no other plugins that affect elytras.

Provide additional information, such as error/debug/violation logs. (For reproducible issues with moving consider: https://github.com/NoCheatPlus/Docs/wiki/Debugging#on-the-fly-debug-output-for-individual-players) Use GitHub gists or http://pastebin.com/ or similar for huge logs, or attach a (zip-) file here. For image uploads, please prefer a site that allows viewing without JavaScript, you can upload file attachments for issues right here.

https://gist.github.com/MidnightSugar/78ee65d56a99998849b9487f0fe73220

@Sikatsu

This comment has been minimized.

Copy link

Sikatsu commented Dec 22, 2016

Same issue.

@FirstReplay

This comment has been minimized.

Copy link

FirstReplay commented Dec 26, 2016

Yep, awaiting 1.11.2 compatibility.

@asofold

This comment has been minimized.

Copy link
Member

asofold commented Dec 27, 2016

Not sure how to detect when fireworks are active for a player, at present. Any hints, anyone?

@asofold

This comment has been minimized.

Copy link
Member

asofold commented Dec 29, 2016

@jonesdj1 Are you 100% sure? In that case what happens with the fireworks (entity?) server-side? Usually it would have to take it's ordinary course and be visible to others, or it just gets removed and display is client side only. In the latter case, the removal needs some type of server side packet.

All in all i am convinced that there is something the server can notice, at least for the case that other players can see the elytra+fireworks wearing player (includes seeing the fireworks effect with the elytra).

SO....

  • Can other players see the same effect for elytra+fireworks?

(If yes, we need to know which packet/nbt/whatever is exchanged.)

@Janmm14

This comment has been minimized.

Copy link

Janmm14 commented Dec 29, 2016

@asofold I think it might cause a PlayerInteractEvent to appear.

@asofold

This comment has been minimized.

Copy link
Member

asofold commented Dec 30, 2016

Can players see another player using elytra + fireworks? This would be proof of something being sent... one of my guesses would be some nbt tag/content sent with the elytra item, so it propagates to other players too. But we need to know first, if you can see another player using elytra + fireworks ...

@Chnkr

This comment has been minimized.

Copy link

Chnkr commented Dec 30, 2016

The latest protocol version had some NBT changes related to fireworks, so i would guess that is the case

@WhiteNoizes

This comment has been minimized.

Copy link

WhiteNoizes commented Dec 30, 2016

elrocket
@asofold
Yes bro, I have just tested it, other players can see when you use the rocket boost ( the partical trial )
Hope this helps

@asofold

This comment has been minimized.

Copy link
Member

asofold commented Dec 31, 2016

"Perfect". Now we need someone to detect/know/find-out what makes it appear so.

With nbt being a strong hint, one could log all nbt content for players with elytra and possibly for fireworks too, for reference.

@Chnkr

This comment has been minimized.

Copy link

Chnkr commented Dec 31, 2016

@asofold https://matsv.nl/PAaaS/ you can view the protocol changes between 1.11 and 1.11.2 here. There seems to be a extra integer field being added, which could be interesting to look at.

@asofold asofold changed the title 1.11.2 Elytra Boost Freezing 1.11.2 Elytra Boost Freezing (fireworks, rockets) Jan 8, 2017

@DmitryRendov

This comment has been minimized.

Copy link

DmitryRendov commented Jan 9, 2017

Hello guys, is this still not solved? Im getting lots of CreativeFly notifications when users are trying fireworks. Thank you! Great job and great plugin anyway...

@asofold

This comment has been minimized.

Copy link
Member

asofold commented Jan 10, 2017

Doesn't setting horizontal (and if necessary ascend) speeds work for the elytra model?

That should be MUCH preferred over deactivating the entire creativefly check.

@FirstReplay

This comment has been minimized.

Copy link

FirstReplay commented Jan 13, 2017

The problem is that while fireworks are causing false-positives, there are current (1.10-1.11.2) working modules in hacked clients like Impact and Wurst that allow endless elytra flying, hovering, insane speeds and vertical movement all on NCP 1054, ProtocolLib 346 and Paper 1029. I think finding a cure for both is a fairly difficult task.

@bigpresh

This comment has been minimized.

Copy link

bigpresh commented Jan 15, 2017

Right, I've verified that a PlayerInteractEvent fires when a player uses a firework to boost, and that event.getMaterial() returns FIREWORK - so it's definitely possible, server-side, to detect that they're using a firework on an air block. I imagine combining that with a check that they're in the air and have Elytra equipped should be enough to know that they're using a firework to boost their Elytra flight, and that it should be allowed?

@asofold

This comment has been minimized.

Copy link
Member

asofold commented Jan 15, 2017

@bigpresh That looks good, i'll check that then.

@bigpresh

This comment has been minimized.

Copy link

bigpresh commented Jan 15, 2017

Please let me know if I can help in any way!

As a temporary workaround I was considering using NCPHookManager to catch the survivalfly violation events, and check if the user is flying with Elytra and holding a rocket, and cancel NCP's action if so. Or, better still, also hook PlayerInteractEvent and remember the last time the user fired a rocket, and only cancel the NCP action if they've fired a rocket recently enough, in order to prevent a hacked client to provide continuous boosting without using up fireworks, only holding them.

I'm not much of a Java coder though, to be honest!

@asofold

This comment has been minimized.

Copy link
Member

asofold commented Jan 15, 2017

You could use the hook manager, test if the player is wearing elytra, and cancel the violation processing (and possibly subtract the addedVL from the MovingData.survivalFlyVL) - you could also monitor the speed yourself and NCP has some past move tracking, so you could relate moves to past moves for reference...

i assume i'll get something done around monday/tuesday, so it'll probably not pay.

@bigpresh

This comment has been minimized.

Copy link

bigpresh commented Jan 15, 2017

Yeah, I don't really want to go to all that work bodging around it if you think you'll be able to have NCP working with Elytra boost in the near future - I'm not that desperate for it, we've held off 1.11.2 for a good while, and even if I upgrade tonight like I was considering, it's just a new feature that players didn't have before, it's not game-breaking.

If I can be of any help in testing etc, let me know, and good luck :)

@asofold

This comment has been minimized.

Copy link
Member

asofold commented Jan 17, 2017

Thank you, i'll make a distinct attempt on tuesday :). With the interact event it'll be much easier.

@asofold

This comment has been minimized.

Copy link
Member

asofold commented Jan 22, 2017

Sorry, got stuck the week, and i have a stupid device with a fan emitting stupid noise here now.

If i don't turn 100% mad, i'll do this right after the fall damage issue, supposedly coming monday/tuesday (didn't specify which tuesday, last time).

@bigpresh

This comment has been minimized.

Copy link

bigpresh commented Jan 22, 2017

:)

@asofold

This comment has been minimized.

Copy link
Member

asofold commented Jan 24, 2017

Basic fumbling reveals, this appears to be a PlayerInteractEvent (ok...) just as you mentioned, but in cancelled state, with useItemInHand() returning Result.DEFAULT. Setting it to DENY seems to cancel the boost.

So this is entirely doable with Bukkit, i'll need to access some duration property (assume Bukkit has that), then allow some extra speed to any direction with minimum physics/friction/max-speeds applied. For the latter i am hesitating what kind of effect to use (velocity doesn't seem appropriate, thinking ahead of generic effects perhaps, or most likely another type of effect done with an integer and a double for starters. Thus perhaps this wednesday is a realistic estimate for a development build containing some support for the boost feature.

@asofold

This comment has been minimized.

Copy link
Member

asofold commented Jan 25, 2017

Very close now. Getting power is easy, flight duration is something like (20 + power) ticks. One can fly up with it and faster horizontal (descend isn't doing that much).

@bigpresh

This comment has been minimized.

Copy link

bigpresh commented Jan 26, 2017

Awesome! :) As mentioned, if you'd like assistance testing let me know, I'd be happy to throw a dev build on my test server and try it out.

@ScuroK

This comment has been minimized.

Copy link

ScuroK commented Jan 28, 2017

@asofold are you able to fix it?

@asofold

This comment has been minimized.

Copy link
Member

asofold commented Jan 28, 2017

Yes, i've been having a slight cold and had to rearrange some things. I'm still/now at it.

Implementation-wise, few things are missing, which will still need testing and balancing. This sunday i'll certainly have a dev build with the first version of it.

  • Modeling the effect in data + invalidation mechanics (rather simple).
  • Adding the altered physics to creativefly (not difficult, but needs testing and repetition to find suitable paramters).
@ScuroK

This comment has been minimized.

Copy link

ScuroK commented Jan 29, 2017

You are awesome!!!! No rush <3 be well soon :)

@asofold

This comment has been minimized.

Copy link
Member

asofold commented Feb 1, 2017

Did the latest build(s) do something on that account? (CAREFUL with production / auto banning :))

I let it allow the vdist part (more). There may still be all sorts of edges left.

@ScuroK

This comment has been minimized.

Copy link

ScuroK commented Feb 2, 2017

@asofold
I just did some testing and it seems much much better now! I did not use the standard config but i still can see someimpprovement! :) ^^ thx alot!

just some bug after i hit a tree but im not sure if its related. no big deal

@DmitryRendov

This comment has been minimized.

Copy link

DmitryRendov commented Feb 2, 2017

@asofold the same for me - your latest dev build works pretty fine - my players are happy! Thank a lot!

@ScuroK

This comment has been minimized.

Copy link

ScuroK commented Feb 2, 2017

but im not 100% sure. now i just had some problems... but it works better than before.
i went to another world (seperate config but same settings) and there i had the old issues again.

after reloading NCP and relogging it worked fine again xD

overall it deffenitely works better than before.

but if i fly INTO something (for exaple a tree) i get stuck quite often.

@bigpresh

This comment has been minimized.

Copy link

bigpresh commented Feb 9, 2017

I have given this a good test on our test server, and all seemed well. I'm happy to say that I pushed it to our live server tonight, and players are happily boosting about :)

@asofold - thank you :)

@bigpresh

This comment has been minimized.

Copy link

bigpresh commented Feb 12, 2017

One issue I have had reports of is SurvivalFly triggering when using a boost when in / skimming water (e.g. coming too low and your feet touch the water) - and also trying to boost-fly through vines - but I haven't yet had a chance to reliably reproduce those myself.

@asofold

This comment has been minimized.

Copy link
Member

asofold commented Feb 17, 2017

Water - vines :) - most certainly issues.

I'm currently re--considering how to model all these things. Hopefully this can be done in a rather simple way (check + flying-model selection with respect to the abort conditions concerning gliding with elytra).

@asofold

This comment has been minimized.

Copy link
Member

asofold commented Feb 25, 2017

Concerning edge cases such as shortly touching water/vines: #346

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.