ID:163891
 
I'm sorry sorry soryy soryy sorry x1,000,000 that I have to ask you guys this question but I'm at a loss.

I really can't go on reading right now in the guide to figure this out so please just roll with me.

How can I make an inventory slot? I have a command slot which houses my verbs but I want an Inventory slot or maybe even other slots for other random things. Also, how do I costomize the slot to have say

Inventory
---------

Clothes-

Weapons-

etc-

Thanks and sorry for being a newb


(Apologies unnecessary. We're here to help.)

A tab? That's simple.
Add a tab to hold the inventory using:
mob/Stat() // altering the predefined Stat proc
statpanel("Inventory") // create new panel

We could just add a stat(contents) (display the contents list (inventory) in the panel, but it looks like you want to sort it.

To sort the display, you'll want to use for() loops, like so:
    stat("------Clothes------") // create a text line in the panel
for(var/obj/items/Clothes/K in contents)
stat(K) // display all objects fitting definition

(I assume your clothes items are children of the same parent object. If they aren't, this task is made easier if you make them so)

Do one of those for each category, and as long as there are no non-categorized items, you're good.


--Vito
In response to Vito Stolidus
Thanks man. The reason I apologized so much is because SOME PEOPLE! like to yell at newbs to coding because they won't figure EVERYTHING for themselves. They don't realize that maybe we have an excuse......
In response to Moocow696
I have one more question though.
How can I organize my clothes to all match that catagory
What I have now is
Yellow_Shirt
icon='clothes.dmi'
icon_state="shirt1"


And I continue this with the others
also when I compile it all together, it does not reconize "K" that you put in there
In response to Moocow696
Moocow696 wrote:
I have one more question though.
How can I organize my clothes to all match that catagory
What I have now is
> Yellow_Shirt
> icon='clothes.dmi'
> icon_state="shirt1"
>

And I continue this with the others
also when I compile it all together, it does not reconize "K" that you put in there

One thing is to read over the code. The "K" is the variable assigned to the /obj/items/clothing/. What you need to do is;

obj/item/clothing
Yellow_Shirt
icon='clothes.dmi'
icon_state="shirt1"


and then define each clothing out.
In response to LucifersHellion
Ok thanks thats just what I needed