1. Please be advised of a few specific rules and guidelines for this section.

RELEASED Four techs at once! - Ultratech

Discussion in 'Mechanics' started by SuperMandrew, Dec 9, 2013.

  1. SuperMandrew

    SuperMandrew Cosmic Narwhal

    I'm assuming the folder is unzipped, and you put the "tech" folder in there? Not sure why it would freeze on the loading screen, I've never tried stuff via the mods folder yet. You configured bootstrap.config correctly?
     
  2. ToaRex

    ToaRex Void-Bound Voyager

    yes yes and yes
     
    Last edited: Dec 14, 2013
  3. ToaRex

    ToaRex Void-Bound Voyager

    sorry for the double post but here's my new problem
    i got the game to load and everything made a new character and no tech to be found or crafted......
     
  4. SuperMandrew

    SuperMandrew Cosmic Narwhal

    Have you changed player.config to have a recipe added? You should be able to craft ultraTech with one torch after modifying player.config
     
  5. WatcherCCG

    WatcherCCG Giant Laser Beams

    This mod is one of the few I plan to use. It is awesome and how the game should work in the first place. Could you make a version that replaces Blink with Rocket Jump? Blink isn't nearly as useful as it sounds and Rocket Jump can be useful in places where a double jump doesn't reach and Bubble Boost would be overkill.
     
  6. SuperMandrew

    SuperMandrew Cosmic Narwhal

    What if I left Blink in and added Rocket Jump?
     
  7. Rukrio

    Rukrio Pangalactic Porcupine

    i, too seem to be having issues akin to Toa here. i've updated the player file to have the recipe for ultratech in, though i get the feeling i have it wrong seeing as it never pops up in my crafting menu.

    a few questions to perhaps help you help me:

    do i use the ultratech -> tech -> ultratech or tech -> ultratech?

    what would be the proper way to add it as a recipe, name wise? for reference, i have it in as
    Code:
    { "item" : "ultratech" },
    , after tier 1.
     
  8. SuperMandrew

    SuperMandrew Cosmic Narwhal


    Mine looks like this: inside the tech folder is a folder called ultratech, inside that folder are the files. (So it goes tech->ultratech)

    As for the player.config line, mine looks like this:
    Code:
    { "item" : "ultraTech" },
    I'm not sure if it's case sensitive, although it's probably better safe than sorry.
     
    Rukrio likes this.
  9. Rukrio

    Rukrio Pangalactic Porcupine

    going to try that now. thanks ahead of time, and will edit this post once i try that.

    EDIT:
    turns out that's the problem. case sensitivity is quite a thing it seems. otherwise, i've fallen in love with your mod now that i have it working. move aside gravity bubble, i got a new best mobility te- wait. it can be better. have gravity bubble be triggered on up and jump while in the air and after a pulse jump. (basically booster 2.0 from cave story.) but for now, i can settle for this tech with grav bubble and switch back and forth as needed.
     
    Last edited: Dec 15, 2013
    SuperMandrew likes this.
  10. WatcherCCG

    WatcherCCG Giant Laser Beams

    That would work. Blink is the only push-button tech in that list, so it could work perfectly. You'd basically have all of the best mobility techs together.

    I love it. Please make this happen.

    The only thing technically missing would be the two gravity techs, but Bubble Boost and Energy Dash move you MUCH faster than them, so they would be more for precision. Ultratech is about maximum mobility.
     
    Last edited: Dec 15, 2013
    SuperMandrew likes this.
  11. Ryuuichi

    Ryuuichi Big Damn Hero

    I would rather have the alternative one having the Energy Dash, Rocket Jump, Hover and Blink.
     
  12. WatcherCCG

    WatcherCCG Giant Laser Beams

    I'm sure he can make both if we just give him time.
     
  13. ToaRex

    ToaRex Void-Bound Voyager

    this wouldn't be updated to V. Offended koala would it...?
     
  14. SuperMandrew

    SuperMandrew Cosmic Narwhal

    It shouldn't require an update, it should still work properly. Remember that the line added to player.config should be:
    Code:
    { "item" : "ultraTech" },
     
  15. SuperMandrew

    SuperMandrew Cosmic Narwhal

    It shouldn't require an update, it should still work properly. Remember that the line added to player.config should be:
    Code:
    { "item" : "ultraTech" },
     
  16. ToaRex

    ToaRex Void-Bound Voyager

    lemme test and see

    EDIT: Confirmed and working on V. Offended Koala
     
    Last edited: Dec 15, 2013
    SuperMandrew likes this.
  17. SuperMandrew

    SuperMandrew Cosmic Narwhal

    Looks like this mod will be useless somewhat soon!

    which is from: http://www.reddit.com/r/starbound/comments/1t0nis/the_future_of_starbound_a_peek_at_whats_coming/

    which is from:
    Code:
    http://www.twitch.tv/tehmorag/c/3383633
     
    Rukrio likes this.
  18. ToaRex

    ToaRex Void-Bound Voyager

    SuperMandrew likes this.
  19. Ryuuichi

    Ryuuichi Big Damn Hero

    even though the hockey feature will be added for the tech system. you still can only equip 4 tech and you have keep on pressing hotkeys for smooth maneuvers. this mod is still useful... but it will be even better if you can make it in such way that it will like a 4 tech slot cartridge where you can change the techs in it and equip it as a tech. and not fixed 4 tech and right at the start of the game...
     
  20. LimiterDrive

    LimiterDrive Space Spelunker

    Arrg, I'm having trouble with this. I tried to remove the bubble boost so it's just pulse jump+dash+blink, but I think I must have done something horribly wrong, because once I equipped the tech it crashed the game, and now I can't even get back in to unequip it! If anyone could help me out, I'd be much obliged.
    Code:
    function checkCollision(position)
      local collisionBounds = tech.collisionBounds()
      collisionBounds[1] = collisionBounds[1] - tech.position()[1] + position[1]
      collisionBounds[2] = collisionBounds[2] - tech.position()[2] + position[2]
      collisionBounds[3] = collisionBounds[3] - tech.position()[1] + position[1]
      collisionBounds[4] = collisionBounds[4] - tech.position()[2] + position[2]
    
      return not world.rectCollision(collisionBounds)
    end
    
    function blinkAdjust(position, doPathCheck, doCollisionCheck, doLiquidCheck, doStandCheck)
      local blinkCollisionCheckDiameter = tech.parameter("blinkCollisionCheckDiameter")
      local blinkVerticalGroundCheck = tech.parameter("blinkVerticalGroundCheck")
      local blinkFootOffset = tech.parameter("blinkFootOffset")
    
      if doPathCheck then
        local collisionBlocks = world.collisionBlocksAlongLine(tech.position(), position, true, 1)
        if #collisionBlocks ~= 0 then
          local diff = world.distance(position, tech.position())
          diff[1] = diff[1] / math.abs(diff[1])
          diff[2] = diff[2] / math.abs(diff[2])
    
          position = {collisionBlocks[1][1] - diff[1], collisionBlocks[1][2] - diff[2]}
        end
      end
    
      if doCollisionCheck and not checkCollision(position) then
        local spaceFound = false
        for i = 1, blinkCollisionCheckDiameter * 2 do
          if checkCollision({position[1] + i / 2, position[2] + i / 2}) then
            position = {position[1] + i / 2, position[2] + i / 2}
            spaceFound = true
            break
          end
    
          if checkCollision({position[1] - i / 2, position[2] + i / 2}) then
            position = {position[1] - i / 2, position[2] + i / 2}
            spaceFound = true
            break
          end
    
          if checkCollision({position[1] + i / 2, position[2] - i / 2}) then
            position = {position[1] + i / 2, position[2] - i / 2}
            spaceFound = true
            break
          end
    
          if checkCollision({position[1] - i / 2, position[2] - i / 2}) then
            position = {position[1] - i / 2, position[2] - i / 2}
            spaceFound = true
            break
          end
        end
    
        if not spaceFound then
          return nil
        end
      end
    
      if doStandCheck then
        local groundFound = false
        for i = 1, blinkVerticalGroundCheck * 2 do
          local checkPosition = {position[1], position[2] - i / 2}
    
          if world.pointCollision(checkPosition, false) then
            groundFound = true
            position = {checkPosition[1], checkPosition[2] + 0.5 - blinkFootOffset}
            break
          end
        end
    
        if not groundFound then
          return nil
        end
      end
    
      if doLiquidCheck and (world.liquidAt(position) or world.liquidAt({position[1], position[2] + blinkFootOffset})) then
        return nil
      end
    
      if doCollisionCheck and not checkCollision(position) then
        return nil
      end
    
      return position
    end
    
    function findRandomBlinkLocation(doCollisionCheck, doLiquidCheck, doStandCheck)
      local randomBlinkTries = tech.parameter("randomBlinkTries")
      local randomBlinkDiameter = tech.parameter("randomBlinkDiameter")
    
      for i=1,randomBlinkTries do
        local position = tech.position()
        position[1] = position[1] + (math.random() * 2 - 1) * randomBlinkDiameter
        position[2] = position[2] + (math.random() * 2 - 1) * randomBlinkDiameter
    
        local position = blinkAdjust(position, false, doCollisionCheck, doLiquidCheck, doStandCheck)
        if position then
          return position
        end
      end
    
      return nil
    end
    
    function uninit()
      tech.setParentAppearance("normal")
    end
    
    function init()
      data.multiJumps = 0
      data.lastJump = false
      data.mode = "none"
      data.timer = 0
      data.targetPosition = nil
      data.airDashing = false
      data.dashTimer = 0
      data.dashDirection = 0
      data.dashLastInput = 0
      data.dashTapLast = 0
      data.dashTapTimer = 0
      data.ranOut = false
    end
    
    function input(args)
      local currentJump = args.moves["jump"]
    
      if args.moves["jump"] and not tech.jumping() and not tech.canJump() and not data.lastJump and data.multiJumps < tech.parameter("multiJumpCount") then
        data.lastJump = true
        return "multiJump"
      elseif args.moves["special"] == 1 then
        return "blink"
      elseif args.moves["jump"] and not tech.onGround() then
        --world.logInfo("here1")
          end
        end
        data.lastJump = currentJump
      else
        --data.lastJump = args.moves["jump"]
        data.lastJump = currentJump
        if data.dashTimer > 0 then
          return nil
        end
    
        local maximumDoubleTapTime = tech.parameter("maximumDoubleTapTime")
    
        if data.dashTapTimer > 0 then
          data.dashTapTimer = data.dashTapTimer - args.dt
        end
    
        if args.moves["right"] then
          if data.dashLastInput ~= 1 then
            if data.dashTapLast == 1 and data.dashTapTimer > 0 then
              data.dashTapLast = 0
              data.dashTapTimer = 0
              return "dashRight"
            else
              data.dashTapLast = 1
              data.dashTapTimer = maximumDoubleTapTime
            end
          end
          data.dashLastInput = 1
        elseif args.moves["left"] then
          if data.dashLastInput ~= -1 then
            if data.dashTapLast == -1 and data.dashTapTimer > 0 then
              data.dashTapLast = 0
              data.dashTapTimer = 0
              return "dashLeft"
            else
              data.dashTapLast = -1
              data.dashTapTimer = maximumDoubleTapTime
            end
          end
          data.dashLastInput = -1
        else
          data.dashLastInput = 0
        end
          return nil
      end
    end
    
    function update(args)
      local multiJumpCount = tech.parameter("multiJumpCount")
      local energyUsage = tech.parameter("energyUsage")
      local blinkMode = tech.parameter("blinkMode")
      local blinkOutTime = tech.parameter("blinkOutTime")
      local blinkInTime = tech.parameter("blinkInTime")
     
      local dashControlForce = tech.parameter("dashControlForce")
      local dashSpeed = tech.parameter("dashSpeed")
      local dashDuration = tech.parameter("dashDuration")
      --local energyUsage = tech.parameter("energyUsage")
     
      local usedEnergy = 0
     
     
     
      if args.actions["blink"] and data.mode == "none" and args.availableEnergy > energyUsage then
        local blinkPosition = nil
        if blinkMode == "random" then
          local randomBlinkAvoidCollision = tech.parameter("randomBlinkAvoidCollision")
          local randomBlinkAvoidMidair = tech.parameter("randomBlinkAvoidMidair")
          local randomBlinkAvoidLiquid = tech.parameter("randomBlinkAvoidLiquid")
    
          blinkPosition =
            findRandomBlinkLocation(randomBlinkAvoidCollision, randomBlinkAvoidMidair, randomBlinkAvoidLiquid) or
            findRandomBlinkLocation(randomBlinkAvoidCollision, randomBlinkAvoidMidair, false) or
            findRandomBlinkLocation(randomBlinkAvoidCollision, false, false)
        elseif blinkMode == "cursor" then
          blinkPosition = blinkAdjust(args.aimPosition, true, true, false, false)
        elseif blinkMode == "cursorPenetrate" then
          blinkPosition = blinkAdjust(args.aimPosition, false, true, false, false)
        end
    
        if blinkPosition then
          data.targetPosition = blinkPosition
          data.mode = "start"
        else
          -- Make some kind of error noise
        end
      end
     
       
      if data.mode == "start" then
        tech.setVelocity({0, 0})
        data.mode = "out"
        data.timer = 0
    
        return energyUsage
      elseif data.mode == "out" then
        tech.setParentAppearance("hidden")
        tech.setAnimationState("blinking", "out")
        tech.setVelocity({0, 0})
        data.timer = data.timer + args.dt
    
        if data.timer > blinkOutTime then
          tech.setPosition(data.targetPosition)
          data.mode = "in"
          data.timer = 0
        end
    
        return 0
      elseif data.mode == "in" then
        tech.setParentAppearance("normal")
        tech.setAnimationState("blinking", "in")
        tech.setVelocity({0, 0})
        data.timer = data.timer + args.dt
    
        if data.timer > blinkInTime then
          data.mode = "none"
        end
    
        return 0
      end
     
      if args.actions["multiJump"] and data.multiJumps < multiJumpCount and args.availableEnergy > energyUsage then
        tech.jump(true)
        data.multiJumps = data.multiJumps + 1
        tech.burstParticleEmitter("multiJumpParticles")
        tech.playImmediateSound(tech.parameter("jumpsound"))
        return energyUsage
      else
        if tech.onGround() or tech.inLiquid() then
          data.multiJumps = 0
        end
        --return 0.0
      end
     
     
      local dashed = 0 --need a flag to tell if we've dashed
      if args.actions["dashRight"] and data.dashTimer <= 0 and args.availableEnergy > energyUsage then
        data.dashTimer = dashDuration
        data.dashDirection = 1
        dashed = 1
        usedEnergy = energyUsage
        data.airDashing = not tech.onGround()
      elseif args.actions["dashLeft"] and data.dashTimer <= 0 and args.availableEnergy > energyUsage then
        data.dashTimer = dashDuration
        data.dashDirection = -1
        dashed = 1
        usedEnergy = energyUsage
        data.airDashing = not tech.onGround()
      end
    
      if data.dashTimer > 0 then
        tech.xControl(dashSpeed * data.dashDirection, dashControlForce, true)
    
        if data.airDashing then
          tech.applyMovementParameters({gravityEnabled = false})
          tech.yControl(0, dashControlForce, true)
        end
    
        if data.dashDirection == -1 then
          tech.moveLeft()
          tech.setFlipped(true)
        else
          tech.moveRight()
          tech.setFlipped(false)
        end
        tech.setAnimationState("dashing", "on")
        tech.setParticleEmitterActive("dashParticles", true)
        data.dashTimer = data.dashTimer - args.dt
      else
        tech.setAnimationState("dashing", "off")
        tech.setParticleEmitterActive("dashParticles", false)
      end
     
      if dashed == 1 then
        return usedEnergy
      else
        return 0.0
      end
     
      --elseif args.actions["blink"] and data.mode == "none" and args.availableEnergy > energyUsage then
    end
    
     

Share This Page