[Solved!]The frame will be low after playing my mini-game.Please help me to solve it.

Can someone tell me the reason why frame will be low and give me the way to solve it.
I think that I can understand the reason but I cannot write a solution by the reason.

The frame is 60fps before starting my game.
1.png

After you flipped a Voltorb or Press "Shift" to reset current game.(Press "Alt" to start flip and "Enter" to flip)
While cleaning some picture,hhe frame will get down like this
(Before show message "Play VOLTORB Flip Lv.\v[1234]?")
2.png

And then,I quit the game.The frame continue to be low.
3.png
I'm sorry of posting this post to a wrong place.
Can admin move to a correct place please.Thank you.

I find that the reasons should come from the below scripts

screen.pictures.each{|pic|pic.erase}

and

index = 0
screen.pictures.each do |pic|
index += 1
pic.erase unless index == 1
end
Solved!

This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.

Original thread: https://forums.rpgmakerweb.com/threads/solved-the-frame-will-be-low-after-playing-my-mini-game-please-help-me-to-solve-it.121106/