哦,这个意思啊。
替换:精灵处理
#-------------------------------------------------------------------------- # ● 精灵处理 #-------------------------------------------------------------------------- def sprite_p # 刷新puyo if @map.can_down?(@now_b) @now_b.move_down if @now_b.can_down? else if @now_b.can_down? and @now_b.can_turn? and @now_b.can_move? @map.register(@now_b) chain = 0;num=0 loop do until @map.update Graphics.update update_eyes end @map.update # 再运行一次以检 Graphics.update break if @map.can_next? # 无4组时 # 执行清空 chain += 1 # 连击 @map.sb! # 显示SB了 60.times{|i|Graphics.update;update_eyes break if @map.sb_update Audio.se_play("Audio/SE/chain#{[chain,7].min}") if i == 10 show_chain chain if i == 32# 显示连击 } Graphics.update num = @map.remove # 消除 @score += num * 10 * (2 ** chain) # 加分 check_score # 更新分数 20.times{Graphics.update;update_eyes} end show_chain 0 # 消除显示连击 @amina[-1].animation($data_animations[Clear[2][chain]], true) show_next return lose if @map.game_over? return allclear if @map.all_clear? crisis! end end @now_b.move(@move) if @move != 0 and @now_b.can_move? and @map.can_move?(@now_b,@move) @now_b.turn(@turn) if @turn != 0 and @now_b.can_turn? and @map.can_turn?(@now_b,@turn) @level.times{@now_b.update(@speed)} end
#--------------------------------------------------------------------------
# ● 精灵处理
#--------------------------------------------------------------------------
def sprite_p
# 刷新puyo
if @map.can_down?(@now_b)
@now_b.move_down if @now_b.can_down?
else
if @now_b.can_down? and @now_b.can_turn? and @now_b.can_move?
@map.register(@now_b)
chain = 0;num=0
loop do
until @map.update
Graphics.update
update_eyes
end
@map.update # 再运行一次以检
Graphics.update
break if @map.can_next? # 无4组时
# 执行清空
chain += 1 # 连击
@map.sb! # 显示SB了
60.times{|i|Graphics.update;update_eyes
break if @map.sb_update
Audio.se_play("Audio/SE/chain#{[chain,7].min}") if i == 10
show_chain chain if i == 32# 显示连击
}
Graphics.update
num = @map.remove # 消除
@score += num * 10 * (2 ** chain) # 加分
check_score # 更新分数
20.times{Graphics.update;update_eyes}
end
show_chain 0 # 消除显示连击
@amina[-1].animation($data_animations[Clear[2][chain]], true)
show_next
return lose if @map.game_over?
return allclear if @map.all_clear?
crisis!
end
end
@now_b.move(@move) if @move != 0 and @now_b.can_move? and @map.can_move?(@now_b,@move)
@now_b.turn(@turn) if @turn != 0 and @now_b.can_turn? and @map.can_turn?(@now_b,@turn)
@level.times{@now_b.update(@speed)}
end
|