Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:
- # Terrain Tag Changer
- # Version: 1.00
- # Author : LiTTleDRAgo
- #:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:=:
- #
- # How to Use :
- #
- # Use Script Call :
- # change_terrain( A , B )
- # A = terrain tag you want to change
- # B = result terrain tag
- #
- #==============================================================================
- # ** Interpreter
- #------------------------------------------------------------------------------
- # This interpreter runs event commands. This class is used within the
- # Game_System class and the Game_Event class.
- #==============================================================================
- class Interpreter
- def change_terrain(first=0,target=0)
- @parameter = []
- (0...$game_map.width).each {|x|
- (0...$game_map.height).each {|y|
- [2, 1, 0].each {|i|
- id = $game_map.data[x, y, i]
- @parameter << id if $game_map.terrain_tags[id] == first
- }}}
- @parameter.each {|i| $game_map.terrain_tags[i] = target }
- end
- end
- eval ("class Game_Map; attr_accessor :terrain_tags end")
- $drg_change_terrain = true
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement