1. Welcome to the Starbound support forums. Please check the support FAQs before posting: http://playstarbound.com/support

Closed Flying to Volcanic, Magma and Ocean planets gets the player stuck in FTL flight, working fix inside

Discussion in 'Starbound Support' started by Raindrac, Jan 28, 2014.

Thread Status:
Not open for further replies.
  1. Raindrac

    Raindrac Existential Complex

    This will be fixed next patch. Keeping this here for legacy.

    Issue: Flying to a Magma/Volcanic/Ocean biome gets you permanently stuck in FTL until you reset the game.
    With the error: "caused by: VariantException: Improper conversion to bool from int"

    Fixes:
    To fix volcanic biomes...
    In volcanic.parallax, change all appearances of
    Code:
          "nohueshift" : 1,
    to
    Code:
          "nohueshift" : true,
    To fix magma biomes...
    In magma.parallax and magma.undergroundparallax, change all appearances of
    Code:
          "nohueshift" : 1,
    to
    Code:
          "nohueshift" : true,
    To fix ocean biomes...
    In ocean.undergroundparallax, change
    Code:
          "nohueshift" : 1,
    to
    Code:
          "nohueshift" : true,
     
    Last edited: Feb 10, 2014
  2. Aurorialis

    Aurorialis Pangalactic Porcupine

    As someone who is terrible at modding, I am awed that you saw your mod was unstable, tried to fix it, found errors in the VANILLA game, and patched around them. Bravo and currently downloading your mod!
     
  3. RvLesh

    RvLesh Parsec Taste Tester

    The OP *DID* get help from the ##starbound-modding channel ( eventually :p ), but yes. Persistence is a virtue.
     
    Raindrac likes this.
  4. Raindrac

    Raindrac Existential Complex

    Yep, AgentSnazz was the one who helped me, so I don't deserve all of the credit. I was in a -bit- of a freakout since I had no clue what was causing the error with my mod.
    Turns out that is was Chucklefish's fault all along.:p
     
  5. RvLesh

    RvLesh Parsec Taste Tester

    Oh, typo in your OP: should be "magma.undergroundparallax" ?
     
  6. Raindrac

    Raindrac Existential Complex

    Yep, it's actually broke in both the .parallax and the .undergroundparallax files. Fixed.
     
  7. To note magma biomes already patched in Furious #636 ;) (but not underground)

    Btw thank you for sharing, made the patch I know uniffied diff so you can reappli patches quickly with patch --no-backup-if-mismatch -g0 -F1 -p1 -f -i <patch file>

    (includes a workaround for a nil error in vec2.lua) Pastbin syntax highlight: http://pastebin.com/AcFqL6gW

    Code:
    diff -durN starbound.assets.636.orig/biomes/surface/magma/magma.undergroundparallax starbound.assets.636/biomes/surface/magma/magma.undergroundparallax
    --- starbound.assets.636.orig/biomes/surface/magma/magma.undergroundparallax    2014-01-29 03:58:27.126650300 +0100
    +++ starbound.assets.636/biomes/surface/magma/magma.undergroundparallax    2014-01-29 14:38:40.781788400 +0100
    @@ -1,7 +1,7 @@
    {
       "image" : "magmaunderground.png?brightness=-65",
       "dividerimage" : "rockdivider.png?brightness=-65",
    -  "nohueshift" : 1,
    +  "nohueshift" : true,
       "parallax" : 1.1,
       "origin" : [0, 395]
    }
    diff -durN starbound.assets.636.orig/biomes/surface/ocean/ocean.undergroundparallax starbound.assets.636/biomes/surface/ocean/ocean.undergroundparallax
    --- starbound.assets.636.orig/biomes/surface/ocean/ocean.undergroundparallax    2014-01-29 03:58:27.235677600 +0100
    +++ starbound.assets.636/biomes/surface/ocean/ocean.undergroundparallax    2014-01-29 04:07:04.853321800 +0100
    @@ -1,7 +1,7 @@
    {
       "image" : "oceanunderground.png",
       "dividerimage" : "rockdivider.png",
    -  "nohueshift" : 1,
    +  "nohueshift" : true,
       "parallax" : 1,
       "origin" : [0, 180]
    }
    diff -durN starbound.assets.636.orig/biomes/surface/volcanic/volcanic.parallax starbound.assets.636/biomes/surface/volcanic/volcanic.parallax
    --- starbound.assets.636.orig/biomes/surface/volcanic/volcanic.parallax    2014-01-29 03:58:27.424726500 +0100
    +++ starbound.assets.636/biomes/surface/volcanic/volcanic.parallax    2014-01-29 04:05:56.593001300 +0100
    @@ -72,7 +72,7 @@
           "nightCorrelation" : 0,
           "minSpeed" : 0,
           "maxSpeed" : 0,
    -      "nohueshift" : 1,
    +      "nohueshift" : true,
           "modifiers" : "",
           "fadePercent" : 0.04
         },
    @@ -83,7 +83,7 @@
           "nightCorrelation" : 0,
           "minSpeed" : 0,
           "maxSpeed" : 0,
    -      "nohueshift" : 1,
    +      "nohueshift" : true,
           "modifiers" : "",
           "fadePercent" : 0.03
         },
    @@ -94,7 +94,7 @@
           "nightCorrelation" : 0,
           "minSpeed" : 0,
           "maxSpeed" : 0,
    -      "nohueshift" : 1,
    +      "nohueshift" : true,
           "modifiers" : "",
           "fadePercent" : 0.015
         },
    diff -durN starbound.assets.636.orig/scripts/vec2.lua starbound.assets.636/scripts/vec2.lua
    --- starbound.assets.636.orig/scripts/vec2.lua    2014-01-29 03:59:07.696995800 +0100
    +++ starbound.assets.636/scripts/vec2.lua    2014-01-29 04:02:38.537703400 +0100
    @@ -3,31 +3,38 @@
    vec2 = {}
    
    function vec2.eq(vector1, vector2)
    +  if vector1 == nil then return vector1 end
    +  if vector2 == nil then return vector2 end
       return vector1[1] == vector2[1] and vector1[2] == vector2[2]
    end
    
    function vec2.dup(vector)
    +  if vector == nil then return vector end
       return { vector[1], vector[2] }
    end
    
    function vec2.norm(vector)
    +  if vector == nil then return vector end
       local magnitude = world.magnitude(vector)
       return vec2.div(vector, magnitude)
    end
    
    function vec2.mul(vector, scalar)
    +  if vector == nil then return vector end
       vector[1] = vector[1] * scalar
       vector[2] = vector[2] * scalar
       return vector
    end
    
    function vec2.div(vector, scalar)
    +  if vector == nil then return vector end
       vector[1] = vector[1] / scalar
       vector[2] = vector[2] / scalar
       return vector
    end
    
    function vec2.add(vector, scalar_or_vector)
    +  if vector == nil then return vector end
       if type(scalar_or_vector) == "table" then
         vector[1] = vector[1] + scalar_or_vector[1]
         vector[2] = vector[2] + scalar_or_vector[2]
    @@ -40,6 +47,7 @@
    end
    
    function vec2.sub(vector, scalar_or_vector)
    +  if vector == nil then return vector end
       if type(scalar_or_vector) == "table" then
         vector[1] = vector[1] - scalar_or_vector[1]
         vector[2] = vector[2] - scalar_or_vector[2]
    @@ -52,6 +60,7 @@
    end
    
    function vec2.angle(vector)
    +  if vector == nil then return vector end
       local angle = math.atan2(vector[2], vector[1])
       if angle < 0 then angle = angle + 2 * math.pi end
       if vector[1] < 0 then angle = math.pi - angle end
    @@ -59,6 +68,7 @@
    end
    
    function vec2.rotate(vector, angle)
    +  if vector == nil then return vector end
       local sinAngle = math.sin(angle)
       local cosAngle = math.cos(angle)
    
     
    Last edited: Jan 29, 2014
  8. Your Buddy Bill

    Your Buddy Bill Existential Complex

    Holy d
    Holy doritoes this is like a foreign language to me
    What can you do with this?
     
  9. it is a .patch or .diff file and with a cygwin or mingw/msys environment you get the package called patch and then in the cygwin you change to the assets directory and you patch --no-backup-if-mismatch -g0 -F1 -p1 -f -i <patch file>

    Better getting a tiny linux env for windows I like a lot msys2 get here

    http://sourceforge.net/projects/msys2/files/Base/x86_64/msys2-base-x86_64-20131208.tar.xz/download

    then read the first steps to update the system here

    https://sourceforge.net/p/msys2/wiki/MSYS2 installation/

    and finally you should be able to get patch and diff with

    pacman -Su patch diffutils
     
  10. Regal Kain

    Regal Kain Space Kumquat

    Good to know it's not only me. I wonder if they'll hotfix this soonish? :)
     
  11. Inkwell

    Inkwell Hey, You!

    So I am having this problem in 1 player mode. how do I fix it? where do I change these things or whatever?
     
  12. RvLesh

    RvLesh Parsec Taste Tester

    You will need to unpack the packed.pak, then edit the assets manually.

    Or wait for a mod to fix it, or an update.

    @Dracyoshi Is this fixed in your biome mod?
     
    Inkwell likes this.
  13. Inkwell

    Inkwell Hey, You!

    thank you! :rainbow:
     
  14. FormalRiceFarmr

    FormalRiceFarmr Big Damn Hero

    I made a mod to replace these files with the changes you suggested, yet the issue persists for me. Any suggestions?
     
  15. Cyberra

    Cyberra Aquatic Astronaut

    Do i need to pack them again?
     
  16. RvLesh

    RvLesh Parsec Taste Tester

    You can either use Dracyoshi's mod, re-pack the fixed files, or wait for the next patch (in which the issue should be fixed).
     
  17. if you want to get ride of the bug in sleepState.lua, again nil error

    Code:
    diff -durN starbound.assets.636.orig/npcs/sleepstate.lua starbound.assets.636/npcs/sleepstate.lua
    --- starbound.assets.636.orig/npcs/sleepstate.lua    2014-01-29 03:58:48.405752200 +0100
    +++ starbound.assets.636/npcs/sleepstate.lua    2014-01-31 13:54:42.610682300 +0100
    @@ -29,7 +29,10 @@
        end
        local bedPosition = vec2.add(world.entityPosition(stateData.bedId), { 0, 1 })
    -    local toTarget = world.distance(bedPosition, entity.position())
    +    if bedPosition == nil then return true end
    +    local po = entity.position()
    +    if po == nil then return true end
    +    local toTarget = world.distance(bedPosition, po)
        if world.magnitude(toTarget) < entity.configParameter("sleep.lieDownRadius") then
          entity.setLounging(stateData.bedId)
        else
    
    better read on pastebin with diff syntax highlight starbound.636.patch
     
  18. Torren

    Torren Ketchup Robot

    Ocean... Biomes?! Where are they, do you have a coordinate? I've been looking since the patch and I've had no luck. (I usually look around 0,0, but I've been getting as far out as ~500, ~500.)
     
  19. SweFox

    SweFox Guest

    They are not completed yet.
     
  20. Cetek14

    Cetek14 Void-Bound Voyager

    I can't open packed.pak file. I try winrar and 7 zip - still nothing.
     
Thread Status:
Not open for further replies.

Share This Page