Advertisement
TheoAllen

window contents

Jul 11th, 2015
321
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Ruby 0.44 KB | None | 0 0
  1. DataManager.init
  2.  
  3. class Window_Test < Window_Base
  4.  
  5.   def initialize
  6.     super(0,0,300,48)
  7.     self.contents = Bitmap.new(600, 24)
  8.     draw_text(0,0,600,24,"THIS IS A LOOOOOONG TEXT SUPPOSED TO BE VERY LONG")
  9.   end
  10.  
  11.   def update
  12.     super
  13.     self.ox += 4 if Input.press?(:LEFT)
  14.     self.ox -= 4 if Input.press?(:RIGHT)
  15.   end
  16.  
  17. end
  18.  
  19. @window = Window_Test.new
  20.  
  21. loop do
  22.   Graphics.update
  23.   Input.update
  24.   @window.update
  25. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement