expecting Keyword_end

● ARCHIVED · READ-ONLY
Started by Sausage_Boi 4 posts View original ↗
  1. Error.png

    When I try and run a game with Velvet Isis' script, I get this error. Line 87, specifically is: (@map_terrain_camos ||= {}) ||= VIS::TERRAIN_CAMOS

    In context, the whole block is:

    def terrain_camos(ter)
    (@map_terrain_camos ||= {}) ||= VIS::TERRAIN_CAMOS
    @map_terrain_camos
    end
    end

    There are options to define terrain camo in lines 51-66, but I can't make heads or tails of it:

    TERRAIN_CAMOS = { 1 => 60}
    #These are how much Camo a Terrain Tag gives when standing on it.
    #These go across all maps. Use the format: terrain_id => camo
    #So right now terrain tag 1 has a Camo value of 60.

    TERRAIN_CAMOS.default = 0
    #This is the default camo of any undefined terrain above.
    end

    link to the whole script can be found here
  2. Looking at the original script, that line is:

    (@map_terrain_camos ||= {})[@map_id] ||= VIS::TERRAIN_CAMOS

    Which is different from you posted, so it looks like you just messed up the script. I'd try re-copy/pasting the script into your project.
  3. hey thanks for the reply. I may have messed up that line, not sure. But i had copied it multiple times and always the same thing. I contacted the author and he said he forgot code tags and the start and end so it wasn't registering the brackets, or something like that. It works now, though.
  4. This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.

    at OP's request