我可能发晚了,希望对你有帮助:
# 一个普通的固定远景图脚本 by 取个名要上天
$SWI_PAR = true #当为false时,恢复默认远景更新,true时固定远景
class Spriteset_Map
alias new_update_parallax update_parallax
def update_parallax
new_update_parallax
return unless $SWI_PAR
@parallax.ox = @tilemap.ox
@parallax.oy = @tilemap.oy
end
end
# 一个普通的固定远景图脚本 by 取个名要上天
$SWI_PAR = true #当为false时,恢复默认远景更新,true时固定远景
class Spriteset_Map
alias new_update_parallax update_parallax
def update_parallax
new_update_parallax
return unless $SWI_PAR
@parallax.ox = @tilemap.ox
@parallax.oy = @tilemap.oy
end
end










