Page 1 of 1

Strange things with desc and changing desc.

Posted: Wed Sep 12, 2007 1:31 pm
by phao
when pressed ctrl+alt, UO show a lot of name (i think suposed to be the item desc or player names) and i've made a custom item (0x5806) that has this desc "Trap Making Recipe Book", and when i press ctrl-alt, i got the 'original' name, which is Book of Truth?

see:
http://i4.photobucket.com/albums/y111/A ... tranho.jpg

is there any way to fix that?


Also..

is there any way to change the desc of a item?
like this recipe book stores scrolls refering to recipes, so i want to make the script of adding recipes, increase a 'recipe-count' so when the player clicks in the book, appear:

'Crafting Recipe Book (#)' where # is the number of recipes in the book, to do that i need to change the desc, and the .desc is r/o so, how can i change the desc?

Posted: Wed Sep 12, 2007 3:40 pm
by CWO
There is no way to fix Ctrl+Alt. When you press the key combo, the client asks POL for the name of all mobiles in the area which POL returns. The client never asks nor listens to anything about the items in the area, it automatically just lists the default name of the item.

Posted: Wed Sep 12, 2007 6:30 pm
by OldnGrey
To set the single click name a player will see:
item.name := "xxxxx";

To read that name in a script use:
item.desc


Of course, you can always use tooltips to display item properties: eg
Recipe Count: 10

Posted: Wed Sep 12, 2007 11:35 pm
by Xadhoom
OldnGrey wrote:item.name := "xxxxx";
Use the function SetName to change the name/desc

Posted: Wed Sep 12, 2007 11:55 pm
by OldnGrey
You can do it as you like. I was merely making a point about desc.