Project1
标题:
图片固定
[打印本页]
作者:
子弹君
时间:
2015-3-7 00:38
标题:
图片固定
#==============================================================================
# 图片固定 by 子弹君
#==============================================================================
# 说明:
# 在要固定住的图片名字前加一个[固定]
#==============================================================================
$BombScript ||= {};$BombScript["图片固定"] = "图片固定20150305"
#==============================================================================
# ■ Sprite_Picture
#------------------------------------------------------------------------------
# 显示图片用的精灵。根据 Game_Picture 类的实例的状态自动变化。
#==============================================================================
class Sprite_Picture < Sprite
#--------------------------------------------------------------------------
# ● 更新画面
#--------------------------------------------------------------------------
def update
super
update_bitmap
update_origin
if @picture.name.include?("[固定]")
self.x = 0 - $game_map.display_x * 32
self.y = 0 - $game_map.display_y * 32
else
update_position
end
update_zoom
update_other
end
end
复制代码
欢迎光临 Project1 (https://rpg.blue/)
Powered by Discuz! X3.1