Page 1 of 1

Question about IdFactory

Posted: Mon May 05, 2014 1:50 pm
by yksdtc
Why objectId dont start from 1?

Re: Question about IdFactory

Posted: Mon May 05, 2014 1:58 pm
by UnAfraid
That's hell of a good question.
I've ask myself a couple of times when i saw this but still didn't found answer.

Re: Question about IdFactory

Posted: Mon May 05, 2014 3:45 pm
by jurchiks
Maybe to not conflict with NPC/item IDs and such?

Re: Question about IdFactory

Posted: Mon May 05, 2014 5:12 pm
by UnAfraid
jurchiks wrote:Maybe to not conflict with NPC/item IDs and such?
It cannot conflict them since its a separate id in retail it starts from 1 and it resets everytime u restart L2Server

Re: Question about IdFactory

Posted: Mon May 05, 2014 5:47 pm
by jurchiks
Ok, let's assume you have an NPC with some ID that matches an existing object ID. There is an error/warning logged somewhere with the object ID, but the log message does not say if it's the object or the NPC ID. You look at the ID and it clearly looks like an NPC ID, so you start looking into it, but can't find anything. Searching for the log message in the code reveals it was actually the object ID, not the NPC ID.

I believe it's just a simple case of avoiding mixups. But in any case, it is not a problem in any way.

Re: Question about IdFactory

Posted: Mon May 05, 2014 6:11 pm
by UnAfraid
Then those kinds of logs are wrong .. :)

Re: Question about IdFactory

Posted: Mon May 05, 2014 6:25 pm
by jurchiks
Meh, it's a non-issue in any case.