09-30-2011, 08:37 PM
xerojester > could you post a screenshot of your problem with characters sprites? And a link to the caterpillar script ?
NekoMage > Use this script instead of the one above :
And use in your maps names : [NSX/Y], where X and Y are the coordinates of the focused tile.
example : [NS10/8] will center the camera on the tile at coordinates (10, 8).
NekoMage > Use this script instead of the one above :
Content Hidden
Code:
#============================================================================
# ** Game_System
#============================================================================
class Game_System
#--------------------------------------------------------------------------
# * Aliased methods (F12 compatibility)
#--------------------------------------------------------------------------
unless @already_aliased_neoM7_center
alias neoM7_reset_neoM7_center_game_system neoM7_reset
@already_aliased_neoM7_center = true
end
#--------------------------------------------------------------------------
# * Attributes
#--------------------------------------------------------------------------
attr_accessor :neoM7_limit_scroll
attr_accessor :neoM7_no_scroll
attr_accessor :neoM7_no_scroll_x
attr_accessor :neoM7_no_scroll_y
#--------------------------------------------------------------------------
# * Reset zoom and pivot
#--------------------------------------------------------------------------
def neoM7_reset
neoM7_reset_neoM7_center_game_system
self.neoM7_limit_scroll = false
self.neoM7_no_scroll = false
self.neoM7_no_scroll_x = 0
self.neoM7_no_scroll_y = 0
end
end
#============================================================================
# ** Game_Player
#============================================================================
class Game_Player < Game_Character
#--------------------------------------------------------------------------
# * Always center around the hero in mode 7
#--------------------------------------------------------------------------
def center(x, y)
if $game_system.neoM7_no_scroll
$game_map.display_x = $game_system.neoM7_no_scroll_x * 128 - CENTER_X
$game_map.display_y = $game_system.neoM7_no_scroll_y * 128 - $game_system.neoM7_center_y
return
end
unless $game_system.neoM7 && !$game_system.neoM7_limit_scroll
center_neoM7_game_player(x, y)
return
end
$game_map.display_x = x * 128 - CENTER_X
$game_map.display_y = y * 128 - $game_system.neoM7_center_y
end
end
#============================================================================
# ** Game_Map
#============================================================================
class Game_Map
#--------------------------------------------------------------------------
# * Scroll Down
# distance : scroll distance
#--------------------------------------------------------------------------
def scroll_down(distance)
if $game_system.neoM7_no_scroll
return
end
unless $game_system.neoM7 && !$game_system.neoM7_limit_scroll
scroll_down_neoM7_game_map(distance)
return
end
@display_y = @display_y + distance.to_i
end
#--------------------------------------------------------------------------
# * Scroll Left
# distance : scroll distance
#--------------------------------------------------------------------------
def scroll_left(distance)
if $game_system.neoM7_no_scroll
return
end
unless $game_system.neoM7 && !$game_system.neoM7_limit_scroll
scroll_left_neoM7_game_map(distance)
return
end
@display_x = @display_x - distance.to_i
end
#--------------------------------------------------------------------------
# * Scroll Right
# distance : scroll distance
#--------------------------------------------------------------------------
def scroll_right(distance)
if $game_system.neoM7_no_scroll
return
end
unless $game_system.neoM7 && !$game_system.neoM7_limit_scroll
scroll_right_neoM7_game_map(distance)
return
end
@display_x = @display_x + distance.to_i
end
#--------------------------------------------------------------------------
# * Scroll Up
# distance : scroll distance
#--------------------------------------------------------------------------
def scroll_up(distance)
if $game_system.neoM7_no_scroll
return
end
unless $game_system.neoM7 && !$game_system.neoM7_limit_scroll
scroll_up_neoM7_game_map(distance)
return
end
@display_y = @display_y - distance.to_i
end
#--------------------------------------------------------------------------
# * Setup
# map_id : map ID
#--------------------------------------------------------------------------
def setup(map_id)
old_setup_neoM7(map_id)
if !$game_switches[$enable_neoM7_number]
$game_system.neoM7 = false
$game_system.neoM7_loop = false
$game_system.neoM7_animated = false
$game_system.neoM7_white_horizon = false
$game_system.neoM7_alpha = 0
$game_system.neoM7_theta = 0
$game_system.neoM7_horizon = 960
$game_system.neoM7_resolution = 1
$game_system.neoM7_filter = false
$game_system.neoM7_limit_scroll = false
$game_system.neoM7_no_scroll = false
return
end
map_data = $data_maps[$game_map.map_id]
for keyword in $neoM7_maps_settings.keys
if map_data.name2.include?(keyword)
command_list = $neoM7_maps_settings[keyword]
$game_system.neoM7 = command_list.include?("NM7")
$game_system.neoM7_loop = command_list.include?("L")
$game_system.neoM7_animated = command_list.include?("A")
$game_system.neoM7_white_horizon = command_list.include?("H")
$game_system.neoM7_filter = command_list.include?("F")
$game_system.neoM7_limit_scroll = command_list.include?("LS")
$game_system.neoM7_limit_scroll = command_list.include?("NS")
for command in command_list
if command.include?("R")
$game_system.neoM7_resolution = (command.slice(1, 1)).to_i
$game_system.neoM7_resolution = [[$game_system.neoM7_resolution, 1].max, 3].min
end
if command.include?("#")
$game_system.neoM7_alpha = (command.slice(1, 2)).to_i
$game_system.neoM7_alpha = [[$game_system.neoM7_alpha, 0].max, 89].min
end
if command.include?("%")
$game_system.neoM7_theta = (command.slice(1, 3)).to_i
$game_system.neoM7_theta = [[$game_system.neoM7_theta, 0].max, 359].min
end
if command.include?("NS")
command =~ /NS[ ]*([000-999]+)\/([000-999]+)/i
$game_system.neoM7_no_scroll_x = $1.to_i
$game_system.neoM7_no_scroll_y = $2.to_i
end
end
return
end
end
$game_system.neoM7 = map_data.name2.include?("[NM7]")
$game_system.neoM7_loop = map_data.name2.include?("[L]")
$game_system.neoM7_animated = map_data.name2.include?("[A]")
$game_system.neoM7_white_horizon = map_data.name2.include?("[H]")
$game_system.neoM7_filter = map_data.name2.include?("[F]")
$game_system.neoM7_limit_scroll = map_data.name2.include?("[LS]")
$game_system.neoM7_no_scroll = map_data.name2.include?("[NS")
if $game_system.neoM7
map_data.name2 =~ /\[R[ ]*([1-3]+)\]/i
$game_system.neoM7_resolution = $1.to_i
$game_system.neoM7_resolution = [[$game_system.neoM7_resolution, 1].max, 3].min
map_data.name2 =~ /\[#[ ]*([00-99]+)\]/i
$game_system.neoM7_alpha = $1.to_i
$game_system.neoM7_alpha = [[$game_system.neoM7_alpha, 0].max, 89].min
map_data.name2 =~ /\[%[ ]*([000-999]+)\]/i
$game_system.neoM7_theta = $1.to_i
$game_system.neoM7_theta = [[$game_system.neoM7_theta, 0].max, 359].min
map_data.name2 =~ /\[NS[ ]*([000-999]+)\/([000-999]+)\]/i
$game_system.neoM7_no_scroll_x = $1.to_i
$game_system.neoM7_no_scroll_y = $2.to_i
end
end
end
And use in your maps names : [NSX/Y], where X and Y are the coordinates of the focused tile.
example : [NS10/8] will center the camera on the tile at coordinates (10, 8).
Some scripts :
[XP] H-Mode7
[XP] ASBC for ATCBS
[XP] Neo Mode 7 / Neo Mode 7 + / [VX] Import NeoM7 maps
[XP] FPLE / [VX] Import FPLE maps
[Old][XP] Moving Platforms
[Old][XP] New Mode 7
[Old][XP] 2D ISO
[XP] ASBC for ATCBS
[XP] Neo Mode 7 / Neo Mode 7 + / [VX] Import NeoM7 maps
[XP] FPLE / [VX] Import FPLE maps
[Old][XP] Moving Platforms
[Old][XP] New Mode 7
[Old][XP] 2D ISO
Working on :
- H-Mode7 Engine v.1.4
- FPLE 2
- MGC_ISO Engine
- VP Engine
- MKBS
- FPLE 2
- MGC_ISO Engine
- VP Engine
- MKBS