Elves

Forum where anything UOX3-related goes - including, but not limited to: newbie-support, ideas, general questions, comments, etc and-so-forth.
Post Reply
stranf
UOX3 Guru
Posts: 939
Joined: Wed Jan 04, 2006 3:59 pm
Has thanked: 0
Been thanked: 0

Elves

Post by stranf »

I searched the forum, but couldn't find anything. Is there currently a way to enable the elf race on UOx3?

I try to create one, and it just says it's not supported.
User avatar
Xuri
Site Admin
Posts: 3704
Joined: Mon Jun 02, 2003 9:11 am
Location: Norway
Has thanked: 48 times
Been thanked: 8 times
Contact:

Post by Xuri »

Alas, elves aren't supported yet. :/ Someone needs to add code for allowing the selection during character creation, as well as make the necessary changes throughout the source to make everything that depends on the human body ids also work for the elven body ids.
-= Ho Eyo He Hum =-
stranf
UOX3 Guru
Posts: 939
Joined: Wed Jan 04, 2006 3:59 pm
Has thanked: 0
Been thanked: 0

Post by stranf »

sounds like a lot of work. :)

I'd personally rather have magic and boats first. heheh.
Maarc
Developer
Posts: 576
Joined: Sat Mar 27, 2004 6:22 am
Location: Fleet, UK
Has thanked: 0
Been thanked: 0
Contact:

Post by Maarc »

Hmmm, Xu, is it just an updated packet thingy, and adding closer comparisons to the real body types?

I might be able to take a crack at that. I've recently installed a client and patched up to 5.0.1h, with the intent to try and take a look at code more often, once I finish a few things here.

Mind you, if you're really keen, you can send me a list of things todo, and I can try and work my way through them (admittedly, very slow)
giwo
Developer
Posts: 1780
Joined: Fri Jun 18, 2004 4:17 pm
Location: California
Has thanked: 0
Been thanked: 0

Post by giwo »

Heya Maarc... long time no see!

Any contributions would be more than welcome... as you may have noticed I've been inactive for almost a month now, we are moving to Los Angeles, and thus I have no time to contribute to UOX3 currently.

Regarding the to-do list, Xuri would be the best person for you as you mentioned, but I thought I might bring up something I may have mentioned before. We have an issue with the JS engine where Get/Set props on classes are allocating and not freeing memory.

For instance, say you did var myContainer = item.Container; it would allocate the memory for the new object (the container) but there is nowhere we can check and clean up that allocated memory later. I've yet to come up with a solution to this problem (which becomes quite a large problem when taken in context of an itemcount loop such as wipe).

Anyhow, hope all is going there downunder, and my apologies to the UOX3 community for the lack of updates on the project. :P
Scott
Maarc
Developer
Posts: 576
Joined: Sat Mar 27, 2004 6:22 am
Location: Fleet, UK
Has thanked: 0
Been thanked: 0
Contact:

Post by Maarc »

I can certainly think of one way of doing it, and that's by adding an explicit Dispose or Release method to the classes. The problem with that is, of course, is we don't know specifically *when* an object is being created/deleted, so it's not always easy to determine, of course, when it should be disposed of.

For things like itemcount loops and what not, they'd probably be reasonably trivial. But it's, as you say, the implicit construction of these objects, not the explicit, that bites you in the rear. One possibility (20 seconds thought) is we attach a needsDisposing boolean to each object, and set it to false for the things we know they DON'T want to dispose of, and have the dispose function do that. Sure, that means you make some extra calls to potentially dispose things you don't want, but it's better too many than too little (and this way, we track it a touch better). But again, only 20 seconds thought (came to me as I was writing).

Things are good here, been busy picking up more work, and trying to build a social life, but I still do daily CVS grabs.

I'll try and come up with some pointed questions to ask Xuri to get the ball rolling (for example, what is missing to get spells entirely out to JS).
giwo
Developer
Posts: 1780
Joined: Fri Jun 18, 2004 4:17 pm
Location: California
Has thanked: 0
Been thanked: 0

Post by giwo »

The JS Spells question I can answer for you, as I wrote the clumsy js script. (The only spell that currently is run from the JS).

There are two major things we are missing, and feel free to open up clumsy.js to see just what implementation of these things we require for magic.

1) LoS checking

2) Combat functions (Mostly routines to initiate combat).

Once those are exposed, JS magic should be fully functional (as soon as the actual scripts are written).
Scott
User avatar
Xuri
Site Admin
Posts: 3704
Joined: Mon Jun 02, 2003 9:11 am
Location: Norway
Has thanked: 48 times
Been thanked: 8 times
Contact:

Post by Xuri »

I dug up some stuff concerning elves and whatnot from RunUO:

Code: Select all

public SupportedFeatures( IAccount acct ) : base( 0xB9, 3 )
{
int flags = 0x3 | m_AdditionalFlags;

if ( Core.SE )
flags |= 0x0040;

if ( Core.AOS )
flags |= 0x801C;

if ( acct != null && acct.Limit >= 6 )
{
flags |= 0x8020;
flags &= ~0x004;
}

[color=yellow]flags |= 0x0080;[/color]

m_Stream.Write( (ushort) flags );
//m_Stream.Write( (ushort) m_Value ); // 0x01 = T2A, 0x02 = LBR
}

Code: Select all

//CharacterList packet
if ( Core.SE )
flags |= 0xA0; //SE & AOS
else if ( Core.AOS )
flags |= 0x20; //AOS

[color=yellow]flags |= 0x100;[/color]

Elven skin / hair-hues:

Code: Select all

static int[] ElvenHairs  = new int[] { 52, 53, 54, 55, 56, 57, 88, 142, 143, 144, 145, 146, 257, 296, 303, 345, 346, 347, 348, 349, 350, 445, 484, 499, 519, 529, 569, 593, 620, 707, 713, 797, 798, 799, 800, 801, 802, 803, 804, 805, 806, 873, 902, 903, 904, 905, 906, 1437, 1720, 1829, 2131 };
        static int[] ElvenBodies = new int[] { 191, 589, 590, 591, 851, 865, 871, 884, 885, 886, 897, 898, 899, 900, 901, 905, 990, 997, 998, 1000, 1001, 1072, 1191, 1246, 1309, 1343, 1401, 1899, 1900, 1901, 2101, 2307 };

Additionally, we need to make the code see the body id's of the elven characters as "human", i.e. work exactly the same as the default human bodies (and ghosts)
Male Elf: 605
Male Elf Ghost: 607
Female Elf: 606
Male Female Ghost: 608
There are also some Javascripts that need to be updated (healing, for instance), but I can handle that =)
-= Ho Eyo He Hum =-
giwo
Developer
Posts: 1780
Joined: Fri Jun 18, 2004 4:17 pm
Location: California
Has thanked: 0
Been thanked: 0

Post by giwo »

Most sections of UOX3 will use CChar::IsHuman() which currently supports Male, Female, and GM bodies. So that change shouldn't be very difficult.
Scott
Grimson
Developer
Posts: 802
Joined: Sat Jun 04, 2005 1:52 am
Location: Germany
Has thanked: 0
Been thanked: 0

Post by Grimson »

While your at it, you could also add support for the SE races like ninjas ;) :P.
stranf
UOX3 Guru
Posts: 939
Joined: Wed Jan 04, 2006 3:59 pm
Has thanked: 0
Been thanked: 0

Post by stranf »

wow this topic got detailed! On the SE note....my Yumi bow won't accept arrows. :(

Oh well, the elven composites work fine.:).

Like I said, if elves are too much trouble currently, it's not important. Magic and boats are personally what I'd like tackled first. (which magic is in the beta, still looking forward to the new CVS build this next weekend)
User avatar
Xuri
Site Admin
Posts: 3704
Joined: Mon Jun 02, 2003 9:11 am
Location: Norway
Has thanked: 48 times
Been thanked: 8 times
Contact:

Post by Xuri »

Ninjitsu isn't a race, it's a class/skill =) Along with bushido, necromancy, chivalry and focus, it has been enabled in the current release of UOX3, but not yet "implemented". Which means, you can write your own JScripts for those skills if you want to (through the onSkill event), but there is currently no implemented functionality for them.

The reason your Yumi bow won't accept arrows, is that it's defined in the UOX3 source as a "crossbow" :) Which it obviously isn't hehe. Fix will be up on CVS for that... now. :) Short term fix for you if you don't mess with the source yourself - use crossbow bolts instead =)
-= Ho Eyo He Hum =-
Grimson
Developer
Posts: 802
Joined: Sat Jun 04, 2005 1:52 am
Location: Germany
Has thanked: 0
Been thanked: 0

Post by Grimson »

Xuri wrote:Ninjitsu isn't a race, it's a class/skill =) Along with bushido, necromancy, chivalry and focus, it has been enabled in the current release of UOX3, but not yet "implemented". Which means, you can write your own JScripts for those skills if you want to (through the onSkill event), but there is currently no implemented functionality for them.
Ah, I confused the race with the pre-defined profession templates. If you create a new char you can't use the "Samurai" and "Ninja" options, when you try UO tells you that you first have to upgrade your account to SE.
User avatar
Xuri
Site Admin
Posts: 3704
Joined: Mon Jun 02, 2003 9:11 am
Location: Norway
Has thanked: 48 times
Been thanked: 8 times
Contact:

Post by Xuri »

Ah yes, we need support for those too! :)
-= Ho Eyo He Hum =-
giwo
Developer
Posts: 1780
Joined: Fri Jun 18, 2004 4:17 pm
Location: California
Has thanked: 0
Been thanked: 0

Post by giwo »

Xuri: if there are no major bugs (since v3.1 release) we could just make the current CVS v3.2 to get it into peoples hands.
Scott
User avatar
Xuri
Site Admin
Posts: 3704
Joined: Mon Jun 02, 2003 9:11 am
Location: Norway
Has thanked: 48 times
Been thanked: 8 times
Contact:

Post by Xuri »

Sure, works for me. =)
-= Ho Eyo He Hum =-
stranf
UOX3 Guru
Posts: 939
Joined: Wed Jan 04, 2006 3:59 pm
Has thanked: 0
Been thanked: 0

Post by stranf »

giwo, I checked out the CVS that was zipped on the other post, and I did run into a stacking bug that was deleting objects. It started when I was cutting cloth that was woven from cotton in the field. There is more info on the "anyone have the CVS for download?" thread.

I can continue to play on the beta server and try to get you more information if your interested.

But I agree, if that bug was absent in my 2 hours of play, I'd say the current CVS is ready to replace the current build.
User avatar
Xuri
Site Admin
Posts: 3704
Joined: Mon Jun 02, 2003 9:11 am
Location: Norway
Has thanked: 48 times
Been thanked: 8 times
Contact:

Post by Xuri »

Forgot to provide the actual hair-ids! So here they are:

Code: Select all

Male Elf hairstyles:
	Mid Long: 0x2fbf
	Long Feather: 0x2fc0
	Short: 0x2fc1
	Mullet:	0x2fc2
	Long: 0x2fcd
	Topknot: 0x2fce
	Long Braid: 0x2fcf
	Spiked:	0x2fd1

Female Elf hairstyles:
	Long Feather: 0x2fc0
	Short: 0x2fc1
	Mullet:	0x2fc2
	Flower: 0x2fcc
	Topknot: 0x2fce
	Long Braid: 0x2fcf
	Buns: 0x2fd0
	Spiked:	0x2fd1
-= Ho Eyo He Hum =-
Post Reply