The PokéCommunity Forums  

Go Back   The PokéCommunity Forums > Creative Discussions > Game Development > Pokémon Essentials
Sign Up Rules/FAQ Live Battle Blogs Mark Forums Read

Notices

Pokémon Essentials All questions and discussion about Pokémon Essentials, the Pokémon game kit for RPG Maker XP, go in here. Also contains links to the latest downloads and the Essentials Wiki.

Reply
Click here to go to the first staff post in this thread.  
Thread Tools
  #1    
Old August 5th, 2013 (01:05 AM).
Kaito123
 
Join Date: Jul 2012
Gender: Male
Hello, I want to modifed the Pokemon Bag, an I have some questions:

How I can put in the two red circles in my picture the Item Name and the quantity?
Attached Thumbnails
Bildschirmfoto 2013-08-05 um 10.25.04.png‎  
Reply With Quote
  #2    
Old August 5th, 2013 (11:41 PM). Edited August 5th, 2013 by dexter1o6.
dexter1o6
 
Join Date: Jul 2013
Age: 26
Gender: Male
To place square like that, I would suggest looking at how other squares are placed. For example, in the folder 'graphics' under 'pictures' you find 'bagSel.png'. This is the kind of square you're looking for, right? See how it is used, and try to copy that.

Ps. I have no experience with this thing at all (so I'm like a Ralts without Confusion, just growling about...)

EDIT: Oh wait, I think I misunderstood your question. You want information in those circle-thingies. Uhm. I can see that there is information displayed. Maybe try to find out how that is displayed, then copy the code for that, and display the name and quantity instead. The name is (I think) already a string (text-variable), so you can just display it. As for the quantity, that will probably be an integer (number-variable). You may have to cast it (but I don't know how that works in Ruby).
Reply With Quote
  #3    
Old August 6th, 2013 (02:42 AM).
Maruno's Avatar
Maruno
Lead Dev of Pokémon Essentials
 
Join Date: Jan 2008
Location: England
dexter's advice is basically correct. You want to add some text to your screen. Is there an existing example of text being on the screen? The item description, you say? How does that work? Can you copy it?
__________________
Reply With Quote
  #4    
Old August 6th, 2013 (03:23 AM).
Kaito123
 
Join Date: Jul 2012
Gender: Male
it must be that:

Code:
@sprites["itemtextwindow"].text=(itemwindow.item==0) ? _INTL("Close bag.") : 
       pbGetMessage(MessageTypes::ItemDescriptions,itemwindow.item)

or is that not the right?
Reply With Quote
  #5    
Old August 6th, 2013 (04:58 AM).
Maruno's Avatar
Maruno
Lead Dev of Pokémon Essentials
 
Join Date: Jan 2008
Location: England
That's the part that updates the description text when you change which item you're looking at. However, that's just half of it. The other half is creating the window to put the text in (the window is called @sprites["itemtextwindow"]). You'll need to create two more windows, one for the item's name and one for the quantity.

Here's how the item description's window is created:

Code:
    @sprites["itemtextwindow"]=Window_UnformattedTextPokemon.new("")
    @sprites["itemtextwindow"].x=72
    @sprites["itemtextwindow"].y=270
    @sprites["itemtextwindow"].width=Graphics.width-72
    @sprites["itemtextwindow"].height=128
    @sprites["itemtextwindow"].baseColor=ITEMTEXTBASECOLOR
    @sprites["itemtextwindow"].shadowColor=ITEMTEXTSHADOWCOLOR
    @sprites["itemtextwindow"].visible=true
    @sprites["itemtextwindow"].viewport=@viewport
    @sprites["itemtextwindow"].windowskin=nil
Just copy-paste, really (both the code above and the update part).
__________________
Reply With Quote
  #6    
Old August 6th, 2013 (05:15 AM).
Kaito123
 
Join Date: Jul 2012
Gender: Male
thanks :D
but how I call the quantity and the name with the script ?
Reply With Quote
  #7    
Old August 6th, 2013 (05:17 AM).
Maruno's Avatar
Maruno
Lead Dev of Pokémon Essentials
 
Join Date: Jan 2008
Location: England
The name and the quantity both (used to) appear in the list of items. Both these properties are also used in many other scripts. Is it so difficult for you to do some research of your own?
__________________
Reply With Quote
  #8    
Old August 12th, 2013 (12:41 AM).
Kaito123
 
Join Date: Jul 2012
Gender: Male
sry, but I don't know how I to do this

i have try this:

Code:
@sprites["itemnamewindow"].text=(itemwindow.item==0) ? _INTL("Close bag.") : 
              pbGetMessage(MessageTypes::Itemname,itemwindow.item)

and how I do this with the quantity?


Edit: I really don't know, how I can do it at this Way...... Because what i should write instead of "ItemDescriptions".......
Reply With Quote
Reply
Quick Reply

Sponsored Links
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Minimum Characters Per Post: 25



All times are UTC -8. The time now is 08:01 PM.


Style by Nymphadora, artwork by Sa-Dui.
Like our Facebook Page Follow us on Twitter © 2002 - 2014 The PokéCommunity™, pokecommunity.com.
Pokémon characters and images belong to The Pokémon Company International and Nintendo. This website is in no way affiliated with or endorsed by Nintendo, Creatures, GAMEFREAK, The Pokémon Company or The Pokémon Company International. We just love Pokémon.
All forum styles, their images (unless noted otherwise) and site designs are © 2002 - 2014 The PokéCommunity / PokéCommunity.com.
PokéCommunity™ is a trademark of The PokéCommunity. All rights reserved. Sponsor advertisements do not imply our endorsement of that product or service. User generated content remains the property of its creator.