![]() |
|
RPGMVXAce - RGSS is fucking me - Printable Version +- Sinisterly (https://sinister.ly) +-- Forum: Coding (https://sinister.ly/Forum-Coding) +--- Forum: Coding (https://sinister.ly/Forum-Coding--71) +--- Thread: RPGMVXAce - RGSS is fucking me (/Thread-RPGMVXAce-RGSS-is-fucking-me) |
RPGMVXAce - RGSS is fucking me - ProfessorChill - 06-06-2016 Right up the anus. Not really code, just scripting Can someone who knows RGSS help me with this crap, the game freezes when I run this code. By freeze I mean this: http://i.imgur.com/Lej8s5o.gif ![]() Code: class Scene_DataHolder < Scene_Base
def prepare(x, y, path, loop, frames)
@window_x = x
@window_y = y
@path = path
@loop = loop
@frames = frames
@newframes = 1
@image = Sprite.new
create_window
end
def update
Graphics.wait(10)
@newframes += 1
if @newframes != @frames
@image.bitmap.dispose
create_window
end
else if @newframes == @frames
if @loop == 1
resetframes
end
else if @loop == 0
SceneManager.return if $frames == 0
end
end
end
def resetframes
@newframes = 1
update
end
def create_window
@image = Sprite.new
@image.bitmap = Bitmap.new("Graphics/Pictures/" + @path + "/" + @newframes.to_s + ".png")
end
end
class Game_Interpreter
def animatedimages(x, y, path, loop, frames)
SceneManager.call(Scene_DataHolder)
SceneManager.scene.prepare(x, y, path, loop, frames)
end
end |