Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- module SES module Map
- # This is the number of the terrain tag that signifies that the new passage
- # setting should be used for the tile. Make sure to set the normal passage
- # to ☆ or it won't work.
- XPPass = 1
- end end
- class Game_CharacterBase
- attr_accessor :z
- alias en_xpp_gcb_sz screen_z
- def screen_z
- @z || en_xpp_gcb_sz
- end
- end
- class Game_Map
- def tile_above_char(c)
- x, y = c.x, c.y - 1
- all_tiles(x, y).each do |tile_id|
- flag = tileset.flags[tile_id]
- return true if (flag & 0x10 != 0) && (terrain_tag(x, y) == SES::Map::XPPass)
- end
- return false
- end
- end
- class Spriteset_Map
- alias en_xpp_sm_ut update_tilemap
- def update_tilemap
- @character_sprites.each do |c|
- if $game_map.tile_above_char(c.character) && c.character.priority_type == 1
- c.character.z = 205
- else c.character.z = nil if !c.character.z.nil? && !c.character.moving? end
- end
- en_xpp_sm_ut
- end
- end
RAW Paste Data