• Just a reminder that providing specifics on, sharing links to, or naming websites where ROMs can be accessed is against the rules. If your post has any of this information it will be removed.
  • Our friends from the Johto Times are hosting a favorite Pokémon poll - and we'd love for you to participate! Click here for information on how to vote for your favorites!
  • Serena, Kris, Dawn, Red - which Pokémon protagonist is your favorite? Let us know by voting in our grand final favorite protagonist poll!
  • Welcome to PokéCommunity! Register now and join one of the best fan communities on the 'net to talk Pokémon and more! We are not affiliated with The Pokémon Company or Nintendo.

Help with making a surfable lake

  • 13
    Posts
    9
    Years
    • Seen Dec 23, 2015
    Hi guys, first of all I'd like to thanks in advance for solving my dumb question, yes, I know it will sound noobish but I haven't used RPG maker since 2005 and I'm a little rusty. I'll explain my problem with a little example:

    I'd like to do a surfable lake. So I take a titleset with only 3 materials: Empty, Sand and Water. I set the sand as walkable, the Water as not walkable and "Terrain flag" 7, I set my "empty" material as walkable and "terrain flag" 7 too. Now my problem is...

    1.) If I put, SAND, in layer 1, and WATER, in the layer 2, nothing happens. I can just walk through it.
    2.) If I put SAND, in layer 1, WATER, in layer 2, and use layer 3 to put and fill it with "empty squares" I can surf it, but just the first square, since I got stuck as soon as I start surf in the same spot.

    Now my question is, how do I make a lake surfable? I know it sounds stupid but I really need help. I don't know if I messed with the SCRIPTS or something but I just cannot make water surfable, just walkable or like an invisible walk.

    thanks in advance, really, I'm bloody stupid lol.

    EDIT:

    I'll edit my answer to clarify what happens.

    I'm using this current titleset, with this preferences:

    https://imageshack.com/i/p5QoyOLjj

    If I use them to make a map that's what happens:

    https://imageshack.com/i/p81uIQfWj

    If I put everything on layer 2, and leaves layer 1 empty, The grey borders are visible, so I have to put grass under the water (using layer 1)

    So it fits this way:

    https://imageshack.com/i/p5uJusFXj

    The problem is, now the water is walkable. And if I use layer 3 (using and empty square) to make it surfable, it just won't

    That's the issue. I'm bloody lost and I dont know what to do
     
    Last edited:
    I believe that the surfable lake is done through terrain tags. Set the lake as walkable, then set its terrain tag to a certain value and the scripts that Essentials uses will do the rest.

    Not working but thanks man
     
    "Blank" Tiles are generally set to Terrain Tag "0". It may not solve your problem, but it's just good practice, since the blank tiles are what you're going to use to delete other tiles in the three layers. Otherwise you're going to have a blank tile that is basically acting like invisible water.


    Also make sure the sand and blank tiles are set to "passable" and the water tile is set to "unpassable". Set the sand terrain tag to either 0 or 3 (3 is specifically for sand but either one works).


    What I usually do for maps with water is paint the entire map with sand as the first layer, then use water tiles on the second layer. I use the third layer for rocks on the water or whatever you're using to border off the map. Since sand is on the first layer, you can still use the other two layers to tile additional details on land, as long as they don't overlap with the water.
     
    Last edited:
    "Blank" Tiles are generally set to Terrain Tag "0". It may not solve your problem, but it's just good practice, since the blank tiles are what you're going to use to delete other tiles in the three layers. Otherwise you're going to have a blank tile that is basically acting like invisible water.


    Also make sure the sand and blank tiles are set to "passable" and the water tile is set to "unpassable". Set the sand terrain tag to either 0 or 3 (3 is specifically for sand but either one works).


    What I usually do for maps with water is paint the entire map with sand as the first layer, then use water tiles on the second layer. I use the third layer for rocks on the water or whatever you're using to border off the map. Since sand is on the first layer, you can still use the other two layers to tile additional details on land, as long as they don't overlap with the water.

    I set:
    The Sand as passable, terrain tag:0. I placed it in layer 3.
    The water as unwalkable, terrain tag: 5. I placed it in layer 2.
    (The third layer is reserved to rocks and stuff)


    It just don't let me surf, when I aproach water it says: "seems the water is surfable, want to surf?" I say "yes" and it just don't go through, just mount into the pokemon and get blocked by an invisible wall. Even if I put it inside the water using the control key (debug mode) I just keep stuck there into invisible walls. And I don't know why. Any idea?

    Maybe I messed something with the scripts. Do you have any idea where in the scripts is the tiles properties localed :S?
     
    I set:
    The Sand as passable, terrain tag:0. I placed it in layer 3.
    The water as unwalkable, terrain tag: 5. I placed it in layer 2.
    (The third layer is reserved to rocks and stuff)


    It just don't let me surf, when I aproach water it says: "seems the water is surfable, want to surf?" I say "yes" and it just don't go through, just mount into the pokemon and get blocked by an invisible wall. Even if I put it inside the water using the control key (debug mode) I just keep stuck there into invisible walls. And I don't know why. Any idea?

    Maybe I messed something with the scripts. Do you have any idea where in the scripts is the tiles properties localed :S?

    It looks like PField_Field and PBTerrain is where you'll find scripts related to terrain tags, but I'm wondering if it has anything to do with your blank tile. I know I've had issues in the past where I accidentally used the wrong blank tile to erase parts of my map. If you don't use the very first blank tile in the top left corner of your tileset when erasing tiles on your map, it could cause passability issues that you can't see. If you can't find anything wrong with your scripts, the only other suggestion I have is to make sure you're using the right blank tile when erasing parts of your maps.
     
    It looks like PField_Field and PBTerrain is where you'll find scripts related to terrain tags, but I'm wondering if it has anything to do with your blank tile. I know I've had issues in the past where I accidentally used the wrong blank tile to erase parts of my map. If you don't use the very first blank tile in the top left corner of your tileset when erasing tiles on your map, it could cause passability issues that you can't see. If you can't find anything wrong with your scripts, the only other suggestion I have is to make sure you're using the right blank tile when erasing parts of your maps.

    I've found where the error was, it was caused for this script:

    #==============================================================================
    # ** Big Events System v1.0
    #------------------------------------------------------------------------------
    # Autor: Wecoc
    # No se requieren créditos
    #==============================================================================

    #==============================================================================
    # ** Game_Character
    #==============================================================================

    class Game_Character
    attr_accessor :ch_width
    attr_accessor :ch_height
    alias big_chars_ini initialize unless $@
    def initialize(*args)
    big_chars_ini(*args)
    @ch_width = 1
    @ch_height = 1
    end

    def ch_area
    area_array = []
    for ix in 0...@ch_width
    for iy in 0...@ch_height
    dx = (@ch_width - 1) / 2
    dy = (@ch_height - 1)
    area_array.push([@x - dx + ix, @y - dy + iy])
    end
    end
    return area_array
    end

    alias big_chars_screen_x screen_x unless $@
    def screen_x
    sx = big_chars_screen_x
    if @ch_width % 2 == 0
    sx += 16
    end
    return sx
    end

    def passable?(x, y, d)
    new_x = x + (d == 6 ? 1 : d == 4 ? -1 : 0)
    new_y = y + (d == 2 ? 1 : d == 8 ? -1 : 0)
    unless $game_map.valid?(new_x, new_y)
    return false
    end
    if @through
    return true
    end
    unless $game_map.passable?(x, y, d, self)
    return false
    end
    unless $game_map.passable?(new_x, new_y, 10 - d)
    return false
    end
    for event in $game_map.events.values
    for coord in event.ch_area
    if coord == [new_x, new_y]
    unless event.through
    if self != $game_player
    return false
    end
    if event.character_name != ""
    return false
    end
    end
    end
    end
    end
    if $game_player.x == new_x and $game_player.y == new_y
    unless $game_player.through
    if @character_name != ""
    return false
    end
    end
    end
    return true
    end
    end

    #==============================================================================
    # ** Game_Event
    #==============================================================================

    class Game_Event < Game_Character
    def over_trigger?
    if @character_name != "" and not @through
    return false
    end
    for coord in self.ch_area
    unless $game_map.passable?(coord[0], coord[1], 0)
    return false
    end
    end
    return true
    end

    def check_event_trigger_auto
    if @trigger == 2
    for coord in self.ch_area
    if coord == [$game_player.x, $game_player.y]
    if not jumping? and over_trigger?
    start
    end
    end
    end
    end
    if @trigger == 3
    start
    end
    end

    def refresh
    new_page = nil
    unless @erased
    for page in @event.pages.reverse
    c = page.condition
    if c.switch1_valid
    if $game_switches[c.switch1_id] == false
    next
    end
    end
    if c.switch2_valid
    if $game_switches[c.switch2_id] == false
    next
    end
    end
    if c.variable_valid
    if $game_variables[c.variable_id] < c.variable_value
    next
    end
    end
    if c.self_switch_valid
    key = [@map_id, @event.id, c.self_switch_ch]
    if $game_self_switches[key] != true
    next
    end
    end
    new_page = page
    break
    end
    end
    if new_page == @page
    return
    end
    setup_page(new_page)
    end

    def setup_page(new_page)
    @page = new_page
    clear_starting
    if @page == nil
    @tile_id = 0
    @character_name = ""
    @character_hue = 0
    @move_type = 0
    @through = true
    @trigger = nil
    @list = nil
    @interpreter = nil
    return
    end
    @tile_id = @page.graphic.tile_id
    @character_name = @page.graphic.character_name
    @character_hue = @page.graphic.character_hue
    if @original_direction != @page.graphic.direction
    @direction = @page.graphic.direction
    @original_direction = @direction
    @prelock_direction = 0
    end
    if @original_pattern != @page.graphic.pattern
    @pattern = @page.graphic.pattern
    @original_pattern = @pattern
    end
    @opacity = @page.graphic.opacity
    @blend_type = @page.graphic.blend_type
    @move_type = @page.move_type
    @move_speed = @page.move_speed
    @move_frequency = @page.move_frequency
    @move_route = @page.move_route
    @move_route_index = 0
    @move_route_forcing = false
    @walk_anime = @page.walk_anime
    @step_anime = @page.step_anime
    @direction_fix = @page.direction_fix
    @through = @page.through
    @always_on_top = @page.always_on_top
    @trigger = @page.trigger
    @list = @page.list
    @interpreter = nil
    if @trigger == 4
    @interpreter = Interpreter.new
    end
    check_event_trigger_auto
    get_list_codes
    end

    def get_list_codes
    result = check_for_comment(/CH_WIDTH (.+)/i)
    if result != false
    @ch_width = result.to_i
    end
    result = check_for_comment(/CH_HEIGHT (.+)/i)
    if result != false
    @ch_height = result.to_i
    end
    end

    def check_for_comment(regexp)
    return false if @list.nil?
    for item in @list
    if item.code == 108 or item.code == 408
    if !item.parameters[0][regexp].nil?
    return $1.nil? ? true : $1
    end
    end
    end
    return false
    end
    end

    #==============================================================================
    # ** Game_Player
    #==============================================================================

    class Game_Player < Game_Character
    def check_event_trigger_here(triggers)
    result = false
    if $game_system.map_interpreter.running?
    return result
    end
    for event in $game_map.events.values
    if triggers.include?(event.trigger)
    if not event.jumping? and event.over_trigger?
    for coord in event.ch_area
    if coord == [@x, @y]
    event.start
    result = true
    end
    end
    end
    end
    end
    return result
    end

    def check_event_trigger_there(triggers)
    result = false
    if $game_system.map_interpreter.running?
    return result
    end
    new_x = @x + (@direction == 6 ? 1 : @direction == 4 ? -1 : 0)
    new_y = @y + (@direction == 2 ? 1 : @direction == 8 ? -1 : 0)
    for event in $game_map.events.values
    if triggers.include?(event.trigger)
    if not event.jumping? and not event.over_trigger?
    for coord in event.ch_area
    if coord == [new_x, new_y]
    event.start
    result = true
    end
    end
    end
    end
    end
    if result == false
    if $game_map.counter?(new_x, new_y)
    new_x += (@direction == 6 ? 1 : @direction == 4 ? -1 : 0)
    new_y += (@direction == 2 ? 1 : @direction == 8 ? -1 : 0)
    for event in $game_map.events.values
    if triggers.include?(event.trigger)
    if not event.jumping? and not event.over_trigger?
    for coord in event.ch_area
    if coord == [new_x, new_y]
    event.start
    result = true
    end
    end
    end
    end
    end
    end
    end
    return result
    end

    def check_event_trigger_touch(x, y)
    result = false
    triggers = [1, 2]
    if $game_system.map_interpreter.running?
    return result
    end
    for event in $game_map.events.values
    if triggers.include?(event.trigger)
    if not event.jumping? and not event.over_trigger?
    for coord in event.ch_area
    if coord == [x, y]
    event.start
    result = true
    end
    end
    end
    end
    end
    return result
    end
    end

    #==============================================================================
    # ** Game_Map
    #==============================================================================

    class Game_Map
    def passable?(x, y, d, self_event = nil)
    unless valid?(x, y)
    return false
    end
    bit = (1 << (d / 2 - 1)) & 0x0f
    for event in events.values
    if event.tile_id >= 0 and event != self_event and not event.through
    for coord in event.ch_area
    if coord == [x, y]
    if @passages[event.tile_id] & bit != 0
    return false
    elsif @passages[event.tile_id] & 0x0f == 0x0f
    return false
    elsif @priorities[event.tile_id] == 0
    return true
    end
    end
    end
    end
    end
    for i in [2, 1, 0]
    tile_id = data[x, y, i]
    if tile_id == nil
    return false
    elsif @passages[tile_id] & bit != 0
    return false
    elsif @passages[tile_id] & 0x0f == 0x0f
    return false
    elsif @priorities[tile_id] == 0
    return true
    end
    end
    return true
    end
    end

    I was using it to make some character biggers, like snorlax, caravans, bikes, etc.

    I deleted it and solved the error, now I have to find some big event script working with pokemon essentials, anyway, you helped me a lot man, really, thanks!
     
    Actually, in Essentials, the size of the event is the size of the image you used for the event. If, for example, you want a Giant Snorlax event to block the character's way, just take a Snorlax event sprite and use a photo editor to upscale that image.
     
    Actually, in Essentials, the size of the event is the size of the image you used for the event. If, for example, you want a Giant Snorlax event to block the character's way, just take a Snorlax event sprite and use a photo editor to upscale that image.

    are you sure about that? If I place a giant snorlax as an event, I can see it, but I can traspass it, it's pasable, (not in the center where the event is but the rest is walkable), how can I fix that :S?
     
    Make more, invisible events to fill in the spaces. Each event should have the same interactions (e.g. check for a Poké Flute and cause a wild battle). When you disable one (due to defeating/capturing the Snorlax), disable them all. Only one of the events needs a graphic.
     
    Oh, I see, thank you very much you all guys, seriously, you helped me a lot! thanks, thanks, and once more, thanks!
     
    Back
    Top