RunUO Community

This is a sample guest message. Register a free account today to become a member! Once signed in, you'll be able to participate on this site by adding your own topics and posts, as well as connect with other members through your own private inbox!

Paperdoll Generator using PHP (MyRunUO)

punt59

Wanderer
Kinetix said:
In the tiledata, how do I get the item's gumpid for when it is equipped?

What is commonly referred to as the animid in many documents for tiledata.mul is the index number. Add 50,000 to that number, to get the gumpid for the male paperdoll, and add 60,000 to it to get the female paperdoll (if not present, it defaults to the male paperdoll version).

And hues, I don't understand them at all. How are they applied to the gumps? I'd appreciate any help, thanks.
(Keep in mind I don't know C#)

In the hues, you see a table of 32 colors. Those represent the subsitute color to use based on the orginal colors red value (which will be a number between 0-31). So you take the gump color for a pixel, get the red value, index into that hue table for the particular hue, and get a new color to use.
 

Kinetix

Wanderer
Great! I got it working! Using a C program to do the reading of the files (which is WAY faster than having PHP do it) and let PHP create the picture, I have successfully hued gumps!

But I have a problem, how do you go about reading the strange hues? The ones from 1152 to 1170 or so. Ingame they display fine, but in my program it reads it with the black colors, displaying a weird gump. Any ideas on this?

PS. Once I finish this, I plan on releasing it so all those people who wanted to use Zulu's MyUO on a PHP platform will be able to.

EDIT: AHHHHHHH!!!!!!
I fixed it!!!! And it's working! Thanks for the help. :D
 

Iridath

Wanderer
could you give me a clue to your solution ? *G*

i'm generating the pictures using c# and my drow (with a skin color of 0x800ish) are displayed with a normal skin hue :(
 

Kinetix

Wanderer
Iridath said:
could you give me a clue to your solution ? *G*

i'm generating the pictures using c# and my drow (with a skin color of 0x800ish) are displayed with a normal skin hue :(
I'll be releasing the programs as soon as I fix this one last problem.

The hues above 3000 and from 1152 to 1176 are irregular hues. For some reason I can read 1152, 1153, 1154 fine, even they look weird like the other hues in that range when I open it in the hue editor. However, hues ABOVE 3000 (such as skin hues: 33770, etc) will not display at ALL, because those hues don't exist. The ones from 1155 to 1176 display correctly ingame, but seem to be distorted when I use them in my program.

How it is possible to read these hues, any ideas?
 

Bradley

Sorceror
Kinetix said:
I'll be releasing the programs as soon as I fix this one last problem.

The hues above 3000 and from 1152 to 1176 are irregular hues. For some reason I can read 1152, 1153, 1154 fine, even they look weird like the other hues in that range when I open it in the hue editor. However, hues ABOVE 3000 (such as skin hues: 33770, etc) will not display at ALL, because those hues don't exist. The ones from 1155 to 1176 display correctly ingame, but seem to be distorted when I use them in my program.

How it is possible to read these hues, any ideas?

Krrios' SDK can read them, the source for that is available. You should be able to look at the source code for that section to see if there is anything special being done to read those hues.
 

Atomic

Wanderer
skin hues are just normal hues with
0x8000 added to them :p
but they have the difference that only the grey parts of the gump/item is rehued
 

Kinetix

Wanderer
Ahhh! That makes sense, I'm going to give it a try now. Thanks :)
Edit: It worked. :D

But I'm still stuck with the 1155-1176 hue range...
 

Zippy

Razor Creator
There are lots of little problems like this due to the way AOS handles .def files. The one I wrote for myuogamers ( www.uogamers.com/myuog ) encountered similar problems, mostly with art not showing up because it is actually displayed with a different hue and art # from the .def files.

It's really annoying, I just said screw it and left it out. This applies to stuff like arcane clothing.

Otherwise, skin hues and stuff can be a bit trickey. But I wouldn't want to spoil your fun :-P
 

Zippy

Razor Creator
Also btw the myuogamers one is all done natively in PHP (no dlls, or external programs). Though most of the code was borrowed from Ultima.dll
 

Kinetix

Wanderer
I just ported mine to PHP. You can find it in the script support forum.

EDIT: Hmm... Seems like the verdata has an effect on hues. Possibly the scanlines code? Dunno... I'll have to dig deeper for this.
 
Top