27 Oct, 2012, triskaledia wrote in the 1st comment:
Votes: 0
if (!IS_NPC (ch) && ch->level < LEVEL_IMMORTAL)
OBJ_DATA *obj;

if ((obj = get_eq_char (ch, WEAR_LIGHT)) != NULL
&& obj->item_type == ITEM_LIGHT && obj->value[2] > 0)
if (–obj->value[2] == 0 && ch->in_room != NULL)
act ("$p goes out.", ch, obj, NULL, TO_ROOM);
act ("$p flickers and goes out.", ch, obj, NULL, TO_CHAR);
extract_obj (obj);
else if (obj->value[2] <= 7 && ch->in_room != NULL)
act ("$p flickers.", ch, obj, NULL, TO_CHAR);

So, this is the update for ITEM_LIGHT. To me it all seems in order. I've found a few other references for it in handler.c .
The issue: I've recently found that my lights set as -1 or 999 (infinite according to olc_act.c) doesn't actually make the light
last forever; it flickers and burns out. So the question: Is there any already known errors with the light item type within ROM that can be easily fixed, or am I perhaps over looking something?
As always, any help is appreciated.
27 Oct, 2012, Rarva.Riendf wrote in the 2nd comment:
Votes: 0
I do not think the problem lies in stock ROM but it is very easy to break thing with lights.
At 999 obviously the light is not infinite, at -1 though it should be (–obj->value[2] == 0 can never be true then) .
(and btw I find those tests annoying to read , better write a 'if (x -1) == 0' x–; I bet the compiler does exactly the same and it is a lot more easy on the brain. thus less bug.)

So I would check at boot if you read the value correctly, and not setting them at 0 by default.
Or oset one to -1 and force some tick to see if it flickers right away.
27 Oct, 2012, triskaledia wrote in the 3rd comment:
Votes: 0
if (obj->value[2] == -1 || obj->value[2] == 999) /* ROM OLC */
sprintf (buf, "[v2] Light: Infinite[-1]\n\r");
sprintf (buf, "[v2] Light: [%d]\n\r", obj->value[2]);
send_to_char (buf, ch);

This code bit is just so you know what the code says for defining the light as Infinite.

I'll keep scrolling around to see if I can find the problem…
I created a test character the other day to see check the validity of the players bug, and I found the quest like to flicker and disappear. Ran a couple copyovers and checked the code, and the today it appears it doesn't want to bug any more. It's frustrating.