Jump to content


Photo

[Ace] Modifying Window_NumberInput


  • Please log in to reply
No replies to this topic

#1 Elements

Elements

    Oh you~

  • Members
  • 340 posts
  • Primarily UsesRMVX Ace
  • First LanguageEnglish

User's Awards

     

Posted 01 June 2012 - 10:48 PM

Hello! I was wondering how to modify the Window_NumberInput class, I'm trying to create a slightly altered version of it, and i've ran into a few issues.
First of all, and utilizing the original script which comes with VXAce, I'm not sure why this part of the code doesn't work when I create a Window_NumberInput object, yet it works perfectly fine when I create a number input window through the command events:

def initialize(message_window)
	@message_window = message_window
	super(0, 0, 0, 0)
	@number = 0
	@digits_max = 1
	@index = 0
  # self.openness = 0
   deactivate
  end
The commented one is the problematic method, self.openness, causing the system to freeze.

Second of all, and now with my own altered version of Window_InputNumber, I'm not sure why this is happening:
Posted Image
Basically in my modified Window_NumberInput script, the 2 numbers don't actually show up until I move the cursors up or down. I tried messing around with the refresh and update methods, but those don't seem to be the cause of it. anyone has any theory on how to make it display both numbers by default? this is my altered script:
Spoiler

It's actually mostly the same, except for a few changes in the initializations to make it work as I intend it to.



Edit: Duhhhhh nvm lol it was something really silly, I've fixed it now, this thread can get locked.

Edited by Elements, 02 June 2012 - 01:38 AM.

elebanner.png

G9cCg.png





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users