how to implant a database(item & item box) in renpy?

Discuss how to use the Ren'Py engine to create visual novels and story-based games. New releases are announced in this section.
Forum rules
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
Post Reply
Message
Author
Muchi
Newbie
Posts: 7
Joined: Wed Jan 04, 2012 11:13 pm
Contact:

how to implant a database(item & item box) in renpy?

#1 Post by Muchi » Sat Jan 07, 2012 11:31 pm

hello i'm a newbie can someone tell me a code to implant a database like(we can have item like ring,flower,etc) an a menu to see the item i have,and the items had a picture.. thx before

User avatar
leon
Miko-Class Veteran
Posts: 554
Joined: Sun Oct 09, 2011 11:15 pm
Completed: Visual Novel Tycoon, Night at the Hospital, Time Labyrinth, The Buried Moon, Left of Center, Super Otome Quest
Projects: Lemon Project, Porcelain Heart, Dream's Dénouement
Organization: Team ANARKY
Contact:

Re: how to implant a database(item & item box) in renpy?

#2 Post by leon » Mon Jan 09, 2012 6:19 pm

Have you checked http://www.renpy.org/wiki/renpy/doc/cookbook/Cookbook already? I found a few useful examples there.

User avatar
MoPark
Regular
Posts: 98
Joined: Sat Dec 31, 2011 7:05 pm
Projects: Kangaroo, Terminal Love
Location: DC
Contact:

Re: how to implant a database(item & item box) in renpy?

#3 Post by MoPark » Mon Jan 09, 2012 8:39 pm

Do you simply want to know how to make the visuals for such a thing, or how to build the actual database in Python? Those two seem like very different concepts to me.

User avatar
DragoonHP
Miko-Class Veteran
Posts: 758
Joined: Tue Jun 22, 2010 12:54 am
Completed: Christmas
IRC Nick: DragoonHP
Location: Zion Island, Solario
Contact:

Re: how to implant a database(item & item box) in renpy?

#4 Post by DragoonHP » Mon Jan 09, 2012 10:49 pm

I think OP wants a inventory system in his game...
http://www.renpy.org/wiki/renpy/doc/coo ... ney_System

Not exactly what you are looking for, but it should get you started...

Muchi
Newbie
Posts: 7
Joined: Wed Jan 04, 2012 11:13 pm
Contact:

Re: how to implant a database(item & item box) in renpy?

#5 Post by Muchi » Tue Jan 10, 2012 5:06 am

@DragoonHP thx i've already seen that,what i want to make it's like i had an iventory in a rpg game,something like that.how can i make an inventory menu,so i can see what item that i had in my bag..

User avatar
DragoonHP
Miko-Class Veteran
Posts: 758
Joined: Tue Jun 22, 2010 12:54 am
Completed: Christmas
IRC Nick: DragoonHP
Location: Zion Island, Solario
Contact:

Re: how to implant a database(item & item box) in renpy?

#6 Post by DragoonHP » Tue Jan 10, 2012 5:32 am

It is rather complex as you will need to learn more about Python and ui elements in the very least...

If you want it for your game, I suggest that you recruit a programmer, or if you want to learn how to code it, you should learn it... Ren'Py Documentation and the link I gave you will be good starting place...

User avatar
leon
Miko-Class Veteran
Posts: 554
Joined: Sun Oct 09, 2011 11:15 pm
Completed: Visual Novel Tycoon, Night at the Hospital, Time Labyrinth, The Buried Moon, Left of Center, Super Otome Quest
Projects: Lemon Project, Porcelain Heart, Dream's Dénouement
Organization: Team ANARKY
Contact:

Re: how to implant a database(item & item box) in renpy?

#7 Post by leon » Tue Jan 10, 2012 9:17 am

This is a simpler version - http://www.renpy.org/wiki/renpy/doc/coo ... _Inventory

Information screen - http://www.renpy.org/wiki/renpy/doc/coo ... ion_Screen

Displaying items only (without selecting items) should be fairly easy to implement, and you can probably avoid learning ui elements (but you probably shouldn't) by using 'show' command and displaying items as sprites.

I suggest you start with a mock-up inventory in your favourite photo editor and then describe your inventory system in detail, down to coordinates where you want items to be displayed.

Muchi
Newbie
Posts: 7
Joined: Wed Jan 04, 2012 11:13 pm
Contact:

Re: how to implant a database(item & item box) in renpy?

#8 Post by Muchi » Thu Jan 12, 2012 1:35 am

hmm i'm trying to use code from http://www.renpy.org/wiki/renpy/doc/coo ... _Inventory
but i got an error..
Image

Uploaded with ImageShack.us

i've already put $ items =[]

but it traceback..

User avatar
DragoonHP
Miko-Class Veteran
Posts: 758
Joined: Tue Jun 22, 2010 12:54 am
Completed: Christmas
IRC Nick: DragoonHP
Location: Zion Island, Solario
Contact:

Re: how to implant a database(item & item box) in renpy?

#9 Post by DragoonHP » Thu Jan 12, 2012 1:53 am

It works for me... where are you putting $ items = []

Muchi
Newbie
Posts: 7
Joined: Wed Jan 04, 2012 11:13 pm
Contact:

Re: how to implant a database(item & item box) in renpy?

#10 Post by Muchi » Thu Jan 12, 2012 9:22 am

My bad @dragoonHp i missplace it.I had already solved it.thx for ur help..

Post Reply

Who is online

Users browsing this forum: No registered users