Submit Your Article


 
RPG Maker

Welcome Guest ( Log In | Register )


  Games Resources RPG Maker VX RPG Maker XP Scripts Tutorials Downloads

 
Reply to this topicStart new topic
> Working with text and text boxes
Draze
post Feb 26 2013, 07:30 PM
Post #1



Group Icon

Group: Member
Posts: 2
Type: None
RM Skill: Undisclosed




Hey guys, just discovered this forum and think its really cool. Then I started working again and found a problem and decided to ask it here tongue.gif Just some background on where I'm coming from: I am a college student currently learning C++ and I would love to continue on to create games at a more serious level. However I don't have much coding experience so I am pretty new at this.

Ok here's the problem. I've been messing around with the text box and the coordinates of where it goes but I can't seem to find where to make the text inside the text box match the coordinates I set for the text box. Is there any way to do this?

EDIT: Since I'm asking... is there any way to make the text only show... say two lines at a time? instead of all four? I'd like a thinner text box but it was cutting off the text. (This may even work with the fix that i need in the first place tongue.gif)



Thanks!

(Also, I don't know if I am allowed to ask this here but I thought I may as well instead of taking up more space on the forums tongue.gif I see cool stuff in the gallery, can we use that in games we plan on marketing? Or can they just be used for fun?)

This post has been edited by Draze: Feb 26 2013, 07:54 PM
Go to the top of the page
 
+Quote Post
   
Jens of Zanicuud
post Feb 27 2013, 01:33 AM
Post #2


Dark Jentleman
Group Icon

Group: Local Mod
Posts: 904
Type: Scripter
RM Skill: Skilled
Rev Points: 120




First of all, welcome RRR wink.gif
I'll try asking your questions properly.

1. Window_Message y is decided here: class Window_Message, line 170 on:
CODE
def reset_window
    if $game_temp.in_battle
      self.y = 16
    else
      case $game_system.message_position
      when 0
        self.y = 16
      when 1
        self.y = 160
      when 2
        self.y = 304
      end
    end
    if $game_system.message_frame == 0
      self.opacity = 255
    else
      self.opacity = 0
    end
    self.back_opacity = 160
  end


0 is referred to the top window position,
1 is referred to the middle window position,
2 is referred to the bottom window position.

Modify the y values here to move your window where you wish to;

2. Sure, you can resize the message window here: Window_Message, line 12:
CODE
super(80, 304, 480, 160)

Just modify that 160 with the number you like wink.gif
Remember that 32 pixels are always lost because of padding.
Anyway, remember that this solution will crop away the exceeding lines of text.
To use all the lines and then subdivide the text into two windows, you'd need a more refined script.

3. Gallery items belong to the user who opened it. To use them in commercial games, you have to ask the submitter via PM. Different people could have different reactions about it.

I hope this could help,

Jens


__________________________
"Thorns are the rose's sweetest essence..."
-Jens of Zanicuud


Games I'm working on:
>

official website: TryAdIne eFfeCt

>

Games I worked on (mainly as a scripter):
>
(Warning: it's a 3rr3's project and it's in Italian!)


Awards

Go to the top of the page
 
+Quote Post
   
Draze
post Feb 27 2013, 09:43 AM
Post #3



Group Icon

Group: Member
Posts: 2
Type: None
RM Skill: Undisclosed




Thanks so much smile.gif I really appreciate it!

EDIT: Hey is there anyway to Center the text? For example, my text box is very long and I don't want it to be all on one side like it is now. Thanks biggrin.gif

EDIT2: Man I'm going to have so much trouble being good XD. Ok, is it possible that a picture can show up on top of the textbox?

This post has been edited by Draze: Feb 28 2013, 05:59 PM
Go to the top of the page
 
+Quote Post
   
Jens of Zanicuud
post Mar 3 2013, 04:39 AM
Post #4


Dark Jentleman
Group Icon

Group: Local Mod
Posts: 904
Type: Scripter
RM Skill: Skilled
Rev Points: 120




QUOTE (Draze @ Feb 27 2013, 06:43 PM) *
Thanks so much smile.gif I really appreciate it!

EDIT: Hey is there anyway to Center the text? For example, my text box is very long and I don't want it to be all on one side like it is now. Thanks biggrin.gif

EDIT2: Man I'm going to have so much trouble being good XD. Ok, is it possible that a picture can show up on top of the textbox?


You should modify the Window_Message script, this way it would be actually possible to made both of these things wink.gif
This isn't too much difficult, but it could require some try.

I'll think about it and then post an answer in the next days...

Jens


__________________________
"Thorns are the rose's sweetest essence..."
-Jens of Zanicuud


Games I'm working on:
>

official website: TryAdIne eFfeCt

>

Games I worked on (mainly as a scripter):
>
(Warning: it's a 3rr3's project and it's in Italian!)


Awards

Go to the top of the page
 
+Quote Post
   

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 

Lo-Fi Version Time is now: 26th May 2013 - 01:35 AM
RPG RPG Revolution is an Privacy Policy and Legal
eXTReMe Tracker