Clothing Slots
-
- Posts: 4
- Joined: Tue Jul 01, 2014 5:15 am
Clothing Slots
Hi everyone!
This is my first post on here but I've enjoyed IF since the days of Zork and Adventureland (on the Commodore Vic-20, no less!!!).
I just spent a fair bit of time working on Adrift to incorporate the infamous clothing layers I've read about a little bit on this site.
Right now, I have managed to build a working model that:
- uses 10 different slots (Head, Neck, Torso, Waist, Pelvis, Arms, Hands, Thighs, Calves, Feet)
- allows objects to be worn on multiple slots at the same time (ex. a hoodie can cover Head, Neck,Torso, and Arms; trousers can cover Waist, Pelvis, Thighs, and Calves)
- allows use of any number of clothing layers (
- restricts players from removing objects that are covered (ex. you cannot remove your shirt without removing your jacket first)
- restricts players from wearing objects when a higher-layer object in the same slot is already worn (ex. you cannot put on underwear if you are wearing pants)
I'm working on concealing clothing that is not the highest layer in a slot (ex. if you are wearing a jacket, the "inventory" command will not show your shirt which is hidden by the jacket.)
Does anyone want something like this?
What's the next step?
Thanks
This is my first post on here but I've enjoyed IF since the days of Zork and Adventureland (on the Commodore Vic-20, no less!!!).
I just spent a fair bit of time working on Adrift to incorporate the infamous clothing layers I've read about a little bit on this site.
Right now, I have managed to build a working model that:
- uses 10 different slots (Head, Neck, Torso, Waist, Pelvis, Arms, Hands, Thighs, Calves, Feet)
- allows objects to be worn on multiple slots at the same time (ex. a hoodie can cover Head, Neck,Torso, and Arms; trousers can cover Waist, Pelvis, Thighs, and Calves)
- allows use of any number of clothing layers (
- restricts players from removing objects that are covered (ex. you cannot remove your shirt without removing your jacket first)
- restricts players from wearing objects when a higher-layer object in the same slot is already worn (ex. you cannot put on underwear if you are wearing pants)
I'm working on concealing clothing that is not the highest layer in a slot (ex. if you are wearing a jacket, the "inventory" command will not show your shirt which is hidden by the jacket.)
Does anyone want something like this?
What's the next step?
Thanks
-
- Posts: 4
- Joined: Tue Jul 01, 2014 5:15 am
Re: Clothing Slots
Here's a link to the TAF file. http://www.4shared.com/file/d2juEksEce/ ... yers.html?
Please let me know what you think.
Thanks
Please let me know what you think.
Thanks
-
- Posts: 4
- Joined: Tue Jul 01, 2014 5:15 am
Re: Clothing Slots
Here's the actual taf file.
- Attachments
-
- clothing layers.taf
- (16.64 KiB) Downloaded 222 times
-
- Posts: 98
- Joined: Thu Aug 22, 2013 2:12 am
- Points: 10
Re: Clothing Slots
Nicely done so far. I could use this if you get the visibility. Adding commands to pull up or unzip clothing items (while affecting visibility) would be the following step I would like to see.
Re: Clothing Slots
Malenfant, thanks for this, it's probably much more efficient than the mess I kludged together for my own game. I'd suggest uploading it to the demos section of the main site, I'm sure other people could make use of it too, and not everyone visits the forums.
(Actually lately it seems like no one visits the forums, but ah well, I guess we've gone through these phases before...)
(Actually lately it seems like no one visits the forums, but ah well, I guess we've gone through these phases before...)
- Lazzah
- Moderator
- Posts: 2454
- Joined: Thu Mar 31, 2011 5:54 am
- Points: 90
- Location: Clacton-on-Sea, Essex
Re: Clothing Slots
Well I'm still visiting at least once a day and I know PO Prune is as well. Campbell doesn't seem to be around very much these days, because of the new baby no doubt, but I noticed he has added a few more fixed bugs to the list on the bugs and enhancements page (24 to date). Who knows, we may even get a new version of ADRIFT sometime this year!Lumin wrote:Malenfant, thanks for this, it's probably much more efficient than the mess I kludged together for my own game. I'd suggest uploading it to the demos section of the main site, I'm sure other people could make use of it too, and not everyone visits the forums.
(Actually lately it seems like no one visits the forums, but ah well, I guess we've gone through these phases before...)

The Axe of Kolt, The Spectre of Castle Coris, The Fortress of Fear, Die Feuerfaust, The Lost Children, Run, Bronwynn, Run, The Call of the Shaman, The Lost Labyrinth of Lazaitch, Magnetic Moon, Starship Quest, Revenge of the Space Pirates
-
- Posts: 4
- Joined: Tue Jul 01, 2014 5:15 am
Re: Clothing Slots
Well, visibility is done. I used a trick where I move all clothes to a NPC (the mannequin) and then move ONLY the top-most layer to the player every time the player wears or removes something.ice_wanted wrote:Nicely done so far. I could use this if you get the visibility. Adding commands to pull up or unzip clothing items (while affecting visibility) would be the following step I would like to see.
As for pulling-up or un-zipping... do you mean like unzipping a jacket to reveal the shirt beneath and the jacket?
Sounds like it would involve adding a property for clothing (can be unzipped) and then... I'm not sure

Re: Clothing Slots
I'm sure the AIF crowd will put zippers to good use. 

Re: Clothing Slots
I installed the library to a game I am working on and the following happens after hitting return:
First error

Then, after clicking 'ok' on that, this comes up:
second error

Any ideas? Suggestions?
Even after the item is worn, the game still says the PC is naked
i.e.

I hope someone can help me understand what is going on here.
Thanks
First error

Then, after clicking 'ok' on that, this comes up:
second error

Any ideas? Suggestions?
Even after the item is worn, the game still says the PC is naked
i.e.

I hope someone can help me understand what is going on here.

Thanks
-
- Posts: 294
- Joined: Sun Mar 30, 2014 9:20 pm
- Points: 150
Re: Clothing Slots
This thread is a little old, but in the interest of giving credit where credit is due, I "stole" this method for use in Lost Coastlines. It's an elegant solution to a rather complex problem.