Add optional support for cliloc item names, a better idea.

Bug reports and feature requests. New features can only be added to the current development version. Bug-fixes may be back-ported.

Current release: 099 / Current development: 100
Post Reply
Yukiko
Distro Developer
Posts: 2391
Joined: Thu Feb 02, 2006 1:41 pm
Location: San Antonio, Texas
Contact:

Add optional support for cliloc item names, a better idea.

Post by Yukiko » Tue May 01, 2018 7:52 pm

This post replaces my previous feature request, the optional DescCL member in itemdesc files.

This feature request still involves sending cliloc numbers for item names rather than alpha character strings.

This method is much easier on shard developers than my previous idea because with this method there is no need on the part of the developer to find the cliloc number for an item.

Item names are currently displayed, depending on the player's options setting, when sigle-clicked or hovered over by the mouse. Currently if there is a Desc member defined in an item's definition in the itemdesc.cfg file POL will send that as a string to the client. If there is no Desc member then POL sends the string for the item's name that is in tiledata.mul. If this feature request is implemented rather than sending a string POL would send the cliloc number for that item's name. The cliloc number is an index into the cliloc file.

Fortunately, the UO developers made it extremely easy to find the proper cliloc number that will index into the cliloc file where the item's name can be found. Simply add 1020000 to the art tile ID number for an item to derive the proper cliloc number for an item's name. For example to find the name of the South facing cauldron simply take the decimal value for the cauldron's art tile ID, 2420, and add it to 1020000 and you get 1022420. If you look that up in the cliloc file using UO Fiddler you will see "cauldron" displayed in the text field.

I propose adding a new setting in servspecopt.cfg. For the purposes of this post we will call it UseClilocsForArtTiles. The value for the setting is either 0 or 1. If set to 0 POL will behave as it does now. If set to 1 POL will send a cliloc number, using whatever packet that is needed, instead of an alpha string for an item. POL would have to assure that cliloc numbers are only sent for items that have ID numbers from 0 to MaxTileID from pol.cfg. If the item number is above MaxTileID there will be no cliloc entry for the item. So POL would behave as it does currently by sending either the Name member or, if present, the Desc member.

This feature will aid those scripting for a more international audience by allowing their players to see item names in their own language, provided UO has a cliloc for their language. It may also reduce the packet size required for sending item names to the client. Reduced packet size means potentially reduced lag and bandwidth.

There is one caveat if this feature is implemented and a shard developer wishes to use it:
Any custom items MUST have ObjType numbers greater than the maximum art tile ID for the client version you are using.

Shard developers should already be doing this anyway. So this should not be an issue.
Sincerely,
Yukiko

I would tell you a UDP joke but you might not get it.

Titus 2:13

Yukiko
Distro Developer
Posts: 2391
Joined: Thu Feb 02, 2006 1:41 pm
Location: San Antonio, Texas
Contact:

Re: Add optional support for cliloc item names, a better idea.

Post by Yukiko » Mon May 21, 2018 11:41 am

As no one posted an objection to this, in fact no one even commented at all, I took the liberty of asking Turley what his thoughts were and he said that adding more cliloc messaging to POL is being looked at. So this might actually be implemented.

If so I think it should be an option that is enabled via a setting as I suggested.
Sincerely,
Yukiko

I would tell you a UDP joke but you might not get it.

Titus 2:13

Post Reply