I'm wanting to change Glasses to use the Earring slot. I had hoped it would be as simple as changing a line or two, but it seems no matter what I try, I have poor results. I tried changing ElvenGlasses.cs "BaseArmor" to "BaseEarrings", that threw a ton of errors dealing with glasses having resists, so when I cleared those lines, it threw a bunch more errors regarding all the specific glasses having resists. Then I tried adding "Layer = Layer.Neck;" below "Weight = 2;" and changing ": base(0x2FB8)" to ": base(0x1087)", this stopped throwing errors but didn't change how it was equipped at all. Then I just tried changing the Properties of a pair of glasses to Layer -> Earrings, but for some reason that set the BodySlot to Gorget. My limited knowledge has run out, and I'm sure most of what I tried seems stupid to those of you who know better, but I'm hoping those of you who do can help me set this up!

EDIT: So, apparently that last attempt did work, but I'm equally confused by that (since it says "Gorget") and also that it wouldn't let me equip them until I took off my helmet, but then let me put my helmet back on. Either way, this is only a temporary fix, as I'd rather not have to edit every player's pair of glasses individually so they could wear them as earrings, so still looking for some help!
 
So what you are trying to do is change which layer the glasses take up. That is actually the client that determines that. You would need to edit the glasses within Uofiddler. Also would need to distribute the patch that would fix that.
 
Boo, that's what I was afraid of. Thanks for explaining.

Would it be possible, without the use of UOFiddler, to make Glasses alterable to Gargish Earrings?
 
so there is another way but its more of a step 1 step 2 type deal, so in order for someone to wear glasses on the earrings spot, you would do
C#:
Layer = Layer.Earrings;
not neck, and step 2 of that is you would have to take off a helmet first and then put the glasses on first then the helmet/hat like you mentioned before.
 
Erads way is the way I was going to recommend as well. Only problem with it is, you have ot go into each Glasses file and change the layer by hand. Same thing would have to be done for Gargish Version / Alterable.

Alterable Script looks like this:


using Server.Engines.Craft;

namespace Server.Items
{
[Alterable(typeof(DefTailoring), typeof(GargishBeltofVirtue))]
public class BeltofVirtue : HalfApron
{
public override bool IsArtifact => true;
[Constructable]
public BeltofVirtue()

and the Layer would look like this:


public class NewVirtueCloak : BaseClothing
{
public override bool IsArtifact => true;

[Constructable]
public NewVirtueCloak()
: base(0x2B04, Layer.Cloak)
{
 
Correct me if I am wrong @DragnMaw , but I think in order for it to alter you need it to be under the same base and I believe glasses are under a hats category as for the earrings are under their own base which leads back to BaseJewel, as Hats are under base clothing/ hats
 
I honestly do not know if they are only alterable one way or not... This is the table I use for altering of custom equipment added to my server (Gargoyles only have 13 equipment slots while Humans/Elves have 14)

Helmet - N/A
Gorget - Gargish Necklace
Chest - Gargish Tunic
Shorts - Gargish Leggings
Gloves - Kilt
Arms - Gargoyle Sleeve
Robe - AS IS
Cloak - WingArmor
Ring - AS IS
Bracelet - AS IS
Earring - Gargish Earring
Belt - GargoyleHalfApron
Sash - GargishSash
Shoes - GargishTalons
 
Back