Unremovable Object

For builders to discuss and ask building questions.
Post Reply
Amalia
Sword Grand Master
Sword Grand Master
Posts: 331
Joined: Wed Feb 01, 2006 6:51 pm
Location: Ardeep Forest
Contact:

Unremovable Object

Post by Amalia » Thu Mar 15, 2007 11:27 pm

Another query for the powers that be: how does one make an object unremovable? I would assume such code is used for the vampire bitemark a lot of folk seem to have been sporting at one time or another.

Also, should I seek any sort of special permission to make a certain object unremovable?

And, finally, can one make such an object "stackable" so things can be worn on top of it, or set it up so that something worn in a different slot would hide it? (Say, for example, a helm hiding something worn on the face/forehead)
Dear Enemy: May the Lord hate you and all your kind, may you be turned orange in hue, and may your head fall off at an awkward moment.
User avatar
Japcil
Sword Grand Master
Sword Grand Master
Posts: 1143
Joined: Fri Jun 17, 2005 5:32 pm
Location: Golden Oaks
Contact:

Post by Japcil » Fri Mar 16, 2007 7:04 am

You make an item not removable by not placing a take flag on it.

As far as wear items over, that is default by code and you are limited to certain layers that can be chosen by item's wear location.
Image
Dalvyn
Sword Grand Master
Sword Grand Master
Posts: 4708
Joined: Tue Jul 15, 2003 9:26 pm
Location: House of Wonder, Waterdeep

Post by Dalvyn » Fri Mar 16, 2007 4:46 pm

Actually, that's not entirely exact.

The CAN_WEAR_TAKE flag indicates whether you can pick something from the ground or not. To make an object non-removeable, you would use the flag FLAG_NOREMOVE.

You do not need any kind of special permission... you can put it in the file, and whether or not it is fine will be decided when the area is up for review. :)

Items can only be hidden by other items on the same wear locations, but on "higher" layers, and then only if those items are not flagged FLAG_TRANSPARENT. That means that you cannot hide a CAN_WEAR_FACE items with a WEAR_HEAD item (because they are not set on the same wear locations).

To make it possible to wear something "above" an item, you would set this item to LAYER_UNDER or LAYER_ARMOR layer. There are 3 layers for most locations: LAYER_UNDER, LAYER_ARMOR, and LAYER_OVER. For the CAN_WEAR_BODY wear location, they would respectively correspond to a silk shirt, a leather jerkin, and a wool cape. The cape would be flagged FLAG_TRANSPARENT because, even when it is worn, the other items worn "under" the cape would still be visible. The jerkin would most likely not have this flag, since it would hide the silk shirt.
Post Reply