File tree 1 file changed +8
-3
lines changed
src/main/java/de/zoeyvid/stacker/Listener
1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -13,10 +13,15 @@ public class PlayerMoveListener implements Listener {
13
13
14
14
@ EventHandler
15
15
public void onPlayerMove (PlayerMoveEvent event ) {
16
- if (!loadConfig .throwfalldamage ()) return ;
17
16
Player player = event .getPlayer ();
18
- if (main .getThrown ().contains (player ) && player .getLocation ().getBlock ().getRelative (BlockFace .DOWN ).getType () != Material .AIR && player .getFallDistance () == 0 ) {
19
- main .getThrown ().remove (player );
17
+ if (getVelocity .containsKey (player )) {
18
+ player .setVelocity (getVelocity .get (player ));
19
+ main .getThrown ().add (passenger );
20
+ }
21
+ if (loadConfig .throwfalldamage ()) {
22
+ if (main .getThrown ().contains (player ) && player .getLocation ().getBlock ().getRelative (BlockFace .DOWN ).getType () != Material .AIR && player .getFallDistance () == 0 ) {
23
+ main .getThrown ().remove (player );
24
+ }
20
25
}
21
26
}
22
27
}
You can’t perform that action at this time.
0 commit comments