obj
Items
Armor/Head
Cyborg_Helm
icon='Armor.dmi'
icon_state="Cyborg1"
desc="A helmet from the future made of unknown metal stronger than!"
def=100
iconadd = 1//has no use yet
obj
Items
Armor/Head
verb
wear()
set src in usr.contents//in inventory
if(usr.hequipped==1)//if head slot is filled
usr<<"You already have a helmet equipped!"
else
usr.overlays += src.icon//yes i know i don't need to add src i just do it out of old habit
usr.overlays += src.icon_state
usr.def+=src.def
usr.hequipped=1//fill head slot
//please understand this is just a rough mix of what i'm trying to do
//not ment to be good and usable for a game just getting used to overlays
Problem description:
Alright i'm coding for the first time in about 2 years so i'm really rusty, but i just read the DM guide trying to re-learn. To me this makes no sense, problem is that this used to work till i changed the icon state in the .dmi file, but even after updating it in the .dm file it wont add the overlay when i try to wear it but the object has the correct icon, but if i switch the icon state back to the old one in the .dm file and not in the .dmi file the obj has no icon but it adds the correct overlay.
Presumably, you want to be adding src to overlays instead.