View Single Post
Old 14.07.2007, 14:16   #1
HF
Архивный участник
 
Join Date: Aug 2005
Posts: 1,531
Default ...after decompilation. Stranges in npc

agent_of_slaughter

Code:
If ( 1 != 0 && 1 == 1 )
{
	myself->GiveItem1(target, 7543, 1);
	myself->SoundEffect(target, "ItemSound.quest_itemget");
}
If ( 0 != 0 && 0 == 1 )
{
	myself->GiveItem1(target, 0, 0);
	myself->SoundEffect(target, "ItemSound.quest_itemget");
}
This npc spawn in world, have quest.
But... this code confused me.

- two identical conditions
If ( 0 != 0 && 0 == 1 )
- two strange conditions
If ( 0 != 0 && 0 == 1 ) 0 != 0 and 0 == 1??? Madness...
- GiveItem, id=0, amount 0
what is it? debug code? Horror.

Is very interesting to examine the code in nps. Much interesting it is possible there to find.
HF is offline