script fly hclip help

Avatar

By LaVacheMilka 24 March 2019 00:33

Member · 65 comments

I would like my fly Hclip all 1 sec of 5 block someone could help me

this.onUpdate = function() {
        mc.thePlayer.motionY *= 0.2;
        mc.thePlayer.onGround = true;
        mc.timer.timerSpeed = 0.3;
    }
    this.onDisable = function() {
        mc.timer.timerSpeed = 1;
    }
}

Last edited by LaVacheMilka (24 March 2019 00:34)

Avatar

By Sms_Gamer 24 March 2019 05:27

Member · 160 comments

k,
1: 5 blocks is really way too much.
2: For what server?
3: If it's for cubecraft, every 1/2 seconds hClip 2.2 blocks, but k whatever.
4: Here's the cc glide code

var scriptName = "FlyCube";
var scriptAuthor = "By Survi_G";
var scriptVersion = 1.0;

 // Converts from degrees to radians.
 Math.radians = function(degrees) {
    return degrees * Math.PI / 180;
  };
   
  // Converts from radians to degrees.
  Math.degrees = function(radians) {
    return radians * 180 / Math.PI;
  };

function vClip(offset) {
    mc.thePlayer.setPosition(mc.thePlayer.posX, mc.thePlayer.posY + offset, mc.thePlayer.posZ);
}

function hClip(offset) {
    var playerYaw = Math.radians(mc.thePlayer.rotationYaw);
    mc.thePlayer.setPosition(mc.thePlayer.posX - (Math.sin(playerYaw) * offset), mc.thePlayer.posY, mc.thePlayer.posZ + (Math.cos(playerYaw) * offset));
}

var client;

function FlyModule() {

    this.getName = function() {
        return "CubeFly";
    }

    this.getDescription = function() {
        return "Fly Cubecraft Insurance"
    }

    this.getCategory = function() {
        return "Movement";
    }

    this.onEnable = function() {
        if(mc.thePlayer.onGround) {
            mc.thePlayer.setPosition(mc.thePlayer.posX, mc.thePlayer.posY + 0.8, mc.thePlayer.posZ) 
        }
    }

    this.onUpdate = function() {
        mc.timer.timerSpeed = 0.40; //Here you can edit it to your liking.
        if(mc.thePlayer.ticksExisted % 2 == 0) {
            hClip(2.2) //Maximum 2.2!
        }
    }

    this.onMotion = function() {
    }

    this.onDisable = function() {
        mc.timer.timerSpeed = 1.0;
    }
}

var flyModule = new FlyModule();
var flyModuleClient;

function onEnable() {
    flyModuleClient = moduleManager.registerModule(flyModule);
}

function onDisable() {
    moduleManager.unregisterModule(flyModuleClient);
}

人間の事私は知らない