Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse

LiquidBounce Forum

  1. Home
  2. ScriptAPI
  3. Hello. Script not work

Hello. Script not work

Scheduled Pinned Locked Moved Unsolved ScriptAPI
5 Posts 3 Posters 312 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • Its DommeI Offline
    Its DommeI Offline
    Its Domme
    wrote on last edited by
    #1

    Hello. Who is not hard to help fix the script, it does not work.

    function getBaseMoveSpeed() {
        var BaseSpeed = 0.2873;
          baseSpeed *= 1.0 + 0.2 * (0.20000000298023224 + 1);
        return baseSpeed;
      }
    var stage;
    var moveSpeed;
    var lastDist;
    var name1 = "KirkaLongJump"
    var category1 = "Movement" // Movement, Misc, Combat, Fun, Player, Exploit, World, Render
    var author1 = "ItsDoome1"
    var script = registerScript({
        name: name1,
        version: "1.0.0",
        authors: [author1]
    });
    script.registerModule({
        name: name1,
        category: category1,
        description: author1
        settings: {
            Boost: Setting.integer({
                name: "Boost",
                default: 24,
                min: 4,
                max: 25
            })
        }
    }, function (module) {
    module.on("enable", function() {
    stage = 0;
    });
    module.on("move", function() {
    if (mc.thePlayer.moveForward != 0 || mc.thePlayer.moveStrafing != 0) {
    	if (stage == 0) {
    		moveSpeed = 1 + getBaseMoveSpeed() - 0.05;
    			} else {
    				mc.thePlayer.motionY = 0.42;
    				moveSpeed *= 2.13;
    				if (stage == 2) {
    				var d = 0.66 * (lastDist - getBaseMoveSpeed());
    				moveSpeed = lastDist - d;
    				} else {
    					moveSpeed = lastDist - lastDist / 159;
    				}
    			}
    			moveSpeed = Math.max(getBaseMoveSpeed(), moveSpeed)
    			mc.setMoveSpeed = moveSpeed
    			if (!mc.thePlayer.isCollidedVertically) {
    				mc.thePlayer.setY(mc.thePlayer.motionY = -1.0-4)
    				stage++;
    			} else if (stage > 0) {
    				moduleManager.getModule('KirkaLongJump').setState(false);
    			}
    		}
    	});
    module.on("update", function() {
    if (mc.thePlayer.moveForward != 0.0 || mc.thePlayer.moveStrafing != 0.0) {
    var d1 = mc.thePlayer.x - mc.thePlayer.prevPosX;
    var d2 = mc.thePlayer.z - mc.thePlayer.prevPosZ;
    lastDist = Math.sqrt(d1 * d1 + d2 * d2);
    } else {
    	moduleManager.getModule('KirkaLongJump').setState(false);
    }
    });
    });
    
    Y 1 Reply Last reply
    0
    • Y Offline
      Y Offline
      Yeahuhhuh
      replied to Its Domme on last edited by Yeahuhhuh
      #2

      @its-domme fix your fucking formatting. What IDE are you using? Notepad? get VS code it does the formatting for you

      function getBaseMoveSpeed() {
          var BaseSpeed = 0.2873;
            baseSpeed *= 1.0 + 0.2 * (0.20000000298023224 + 1);
          return baseSpeed;
        }
      var stage;
      var moveSpeed;
      var lastDist;
      var name1 = "KirkaLongJump"
      var category1 = "Movement" // Movement, Misc, Combat, Fun, Player, Exploit, World, Render
      var author1 = "ItsDoome1"
      var script = registerScript({
          name: name1,
          version: "1.0.0",
          authors: [author1]
      });
      script.registerModule({
          name: name1,
          category: category1,
          description: author1
          settings: {
              Boost: Setting.integer({
                  name: "Boost",
                  default: 24,
                  min: 4,
                  max: 25
              })
          }
      }, function (module) {
      module.on("enable", function() {
      stage = 0;
      });
      module.on("move", function() {
      if (mc.thePlayer.moveForward != 0 || mc.thePlayer.moveStrafing != 0) {
      	if (stage == 0) {
      		moveSpeed = 1 + getBaseMoveSpeed() - 0.05;
      			} else {
      				mc.thePlayer.motionY = 0.42;
      				moveSpeed *= 2.13;
      				if (stage == 2) {
      				var d = 0.66 * (lastDist - getBaseMoveSpeed());
      				moveSpeed = lastDist - d;
      				} else {
      					moveSpeed = lastDist - lastDist / 159;
      				}
      			}
      			moveSpeed = Math.max(getBaseMoveSpeed(), moveSpeed)
      			mc.setMoveSpeed = moveSpeed
      			if (!mc.thePlayer.isCollidedVertically) {
      				mc.thePlayer.setY(mc.thePlayer.motionY = -1.0-4)
      				stage++;
      			} else if (stage > 0) {
      				moduleManager.getModule('KirkaLongJump').setState(false);
      			}
      		}
      	});
      module.on("update", function() {
          if (mc.thePlayer.moveForward != 0.0 || mc.thePlayer.moveStrafing != 0.0) {
          var d1 = mc.thePlayer.x - mc.thePlayer.prevPosX;
          var d2 = mc.thePlayer.z - mc.thePlayer.prevPosZ;
          lastDist = Math.sqrt(d1 * d1 + d2 * d2);
          } else {
            	moduleManager.getModule('KirkaLongJump').setState(false);
         }
         });
      });
      

      there, fixed it for you, if it doesnt work anyway, i dont care
      the last few things are probably formatted wrong by me

      Ali00035A 1 Reply Last reply
      1
      • Ali00035A Offline
        Ali00035A Offline
        Ali00035
        replied to Yeahuhhuh on last edited by
        #3

        @yeahuhhuh 10 months later...

        Y 1 Reply Last reply
        0
        • Y Offline
          Y Offline
          Yeahuhhuh
          replied to Ali00035 on last edited by
          #4

          @ali00035 yeah, i was bored

          Ali00035A 1 Reply Last reply
          0
          • Ali00035A Offline
            Ali00035A Offline
            Ali00035
            replied to Yeahuhhuh on last edited by
            #5

            @yeahuhhuh I see now, anyways good job on fixing.

            1 Reply Last reply
            0

            About
            • Terms of Service
            • Privacy Policy
            • Status
            • Contact Us
            Downloads
            • Releases
            • Source code
            • License
            Docs
            • Tutorials
            • CustomHUD
            • AutoSettings
            • ScriptAPI
            Community
            • Forum
            • Guilded
            • YouTube
            • Twitter
            • D.Tube
            • Login

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • Users
            • Groups