• 0
Sign in to follow this  
LinkinParK

[Request] L2Item slot values

Question

Where were the slot values found?

 

Example:

 

public static final int SLOT_LR_HAND = 0x4000;
public static final int SLOT_FULL_ARMOR = 0x8000;
public static final int SLOT_FACE = 0x010000;
public static final int SLOT_ALLDRESS = 0x020000;
public static final int SLOT_HAIR = 0x040000;
public static final int SLOT_HAIRALL = 0x080000;

Share this post


Link to post
Share on other sites

Recommended Posts

  • 0

No, no maybe I wasn't clear enough. I mean where were the original values found? Are the in client files or sniffed by phx?

Are those fixed values or I can change them at will?

Share this post


Link to post
Share on other sites
  • 0

Those are fixed values from client, using others will lead to a terrible mess (critical errors, visual bugs and such). For exemple, you can see RequestUnEquipItem uses a _slot variable which is sent by client, and then controlled by server (for CW case).

 

About how they have been found, probably using L2PHX.

 

Finally, those values depends of chronicle you're using.

Share this post


Link to post
Share on other sites
  • 0

A bit silly question now... Can I sniff packets from a l2j server since the values are stored in client or do I have to find a L2OFF server to do the job?

 

@EDIT: Q2 -> Why are the values stored in hex and not dec form? Is there some restriction or gain or is it just developer's taste?

Share this post


Link to post
Share on other sites
  • 0

Clientpackets and Serverpackets, l2j and l2off use different coded Serverpackets so you will get different server packets from off, I never tested btw. About Clientpackets l2off reads them differently than l2j.

 

Dec? No we are not in 1950 to work and code in dec/bin, a hex F has a size of 16 bits, a FF hex 255, now what u would choose ? 255 characters of 0 1 or 2 characters of Hex?

 

Correct me if I'm wrong this is just personal experience.

Share this post


Link to post
Share on other sites
  • 0

Retail uses ONE system (per chronicle, as it often changes between packet organization or simply opcode), then L2J tries to use/emulate those at best as it can. Obviously differences came from L2J not being able to guess all values. The point is to reach L2OFF no matter the packet you ask, the problem is there are 3xx packets so it's very long.

 

If you got a different packet scheme on L2J compared to L2OFF, that means packet is incomplete on L2J.

 

About LinkinParK question, just be more accurate. What do you want to do at first glance ?

 

And you can sniff L2J or L2OFF. If L2J is wrong, that's another story. But you would have indirect visual bugs, speaking of inventory. On aCis for instance there was a bug I introduced a long time ago about masks/hats. It was using another value rather than the one it should use.

 

Values are static to a client, until you modify client.

Share this post


Link to post
Share on other sites
  • 0

Nevermind I figured it out. Another question now: DOM or SAX parsing?

Lol :). You want to recode entirely document parsing ?

 

SAX is better on any level (faster + RAM consumption), the problem is you can't write with it, and the use is totally different (work by events). You have to entirely recode stuff.

 

But if you manage to do it for IL, I'm interested by result and parser.

 

:troll:

Share this post


Link to post
Share on other sites
  • 0

Im interested to see what he wants to do.

Except performance, there is no reason to recode all.

Share this post


Link to post
Share on other sites
  • 0

Slots was entirely another matter. I wanted to confirm the values the l2j C4 sources have.

 

About the parsing. I saw that all the current projects move from SQL to XML, so I did a little research and read about SAX and DOM. I asked here to give me your opinion on those two methods.

 

I already did it for character templates and armorsets, which have very little data and it's easier to do, and the results are ok. Everything loads and seems to be just fine. Perfomance-wise I can't tell any difference yet.

Share this post


Link to post
Share on other sites
  • 0

Perfomance? :dat: whole L2 Client lacks perfomance, why sm1 would want to rework slots

No facepalm emote yet on MxC.

 

I will take a  :LOL:

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this