Versione: N/D
Autore/i: Crazyninjaguy
Informazioni:
Questo semplice script funziona un pò come l'uso delle picture, a differenza che può inserire anche più di 20 immagini.
Chi mappa in parallax infatti, potrebbe averne bisogno ^^
Screenshot:
Spoiler
Istruzioni:
Inserite lo script sotto Material.
Istruzioni all'interno dello script.
Script:
#===============================================================================
# * AEE - Second Parallax Layer
# * By Crazyninjaguy
# * http://www.planetdev.co.uk
# * Part of Cng's Ace Engine Evolution
# ---------------------------------------------------------------------------
# * Follow the script instructions to setup correctly.
#===============================================================================
$imported = {} if $imported == nil
$imported["AEE-ParallaxingLayers"] = true
module AEE
module Parallax
# Leave this line alone
MAPS = []
# Set this to true if you want MAP[Map ID] to have two parallax layers.
MAPS[1] = true
# To add a new map to the script, simply add MAPS[Map ID] = true
# on a new line. For example.
# MAPS[12] = true
# Without the '#' at the start of the line.
end # Parallax
end # AEE
class Spriteset_Map
include AEE::Parallax
#=============================================================================
# * Create_parallax - ALIASED
#=============================================================================
alias aee_spritesetmap_parallaxing_createparallax create_parallax
def create_parallax
aee_spritesetmap_parallaxing_createparallax
@parallax2 = Plane.new(@viewport1)
@parallax2.z = 201 # Above Character
end # create_parallax
#=============================================================================
# * Dispose_parallax - ALIASED
#=============================================================================
alias aee_spritesetmap_parallaxing_disposeparallax dispose_parallax
def dispose_parallax
@parallax2.bitmap.dispose if @parallax2.bitmap
@parallax2.dispose
end # dispose_parallax
#=============================================================================
# * Update_parallax - OVERWRITTEN
#=============================================================================
def update_parallax
if @parallax_name != $game_map.parallax_name
@parallax_name = $game_map.parallax_name
@parallax.bitmap.dispose if @parallax.bitmap
@parallax.bitmap = Cache.parallax(@parallax_name)
@parallax2.bitmap.dispose if @parallax2.bitmap
if MAPS[$game_map.map_id] == true
@parallax2.bitmap = Cache.parallax("#{@parallax_name}_layer2")
end
Graphics.frame_reset
end
if MAPS[$game_map.map_id] == true
@parallax.ox = $game_map.display_x * 32
@parallax.oy = $game_map.display_y * 32
@parallax2.ox = $game_map.display_x * 32
@parallax2.oy = $game_map.display_y * 32
elsif
@parallax.ox = $game_map.parallax_ox(@parallax.bitmap)
@parallax.oy = $game_map.parallax_oy(@parallax.bitmap)
end
end # update_parallax
end # Spriteset_Map
Note dell'Autore:
Per l'uso dello script in giochi commerciali, contattare l'autore.














