Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public void createBeamEffect4(Player p) {
- Location eyeLocation = p.getLocation();
- double eyeX = eyeLocation.getX();
- double eyeY = eyeLocation.getY();
- double eyeZ = eyeLocation.getZ();
- double eyePitch = Math.toRadians(eyeLocation.getPitch());
- double eyeYaw = Math.toRadians(eyeLocation.getPitch() + 90.0F);
- double x = Math.cos(eyeYaw) * Math.sin(eyePitch);
- double y = Math.sin(eyeYaw) * Math.sin(eyePitch);
- double z = Math.sin(eyePitch);
- for(int i = 0; i <= 50; i++) {
- Location location = new Location(p.getWorld(), eyeX + i * x, eyeY + i * z, eyeZ + i * y);
- p.getWorld().playEffect(location, Effect.WATERDRIP, 1);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement