[Help] Dropping Quest Item

01/22/2011 14:49 Zkiller110#1
i added that code for a quest and i get the following error can someone tell me how to get rid of the error?

Code:
                    if (MobID == 1 && Char.DefenderofTwinCity == 1 != Char.InventoryContains(1075000, 1))
                    {
                        if (MyMath.ChanceSuccess(5))
                        {
                            DI2.Info.ID = 1075000;
                            DI2.Info.MaxDur = DI2.Info.DBInfo.Durability;
                            DI2.Info.CurDur = DI2.Info.MaxDur;
                        }
                    }
System.NullReferenceException: Object reference not set to an instance of an obj
ect.
at NewestCOServer.Game.Mob.DropAnItem(UInt32 Owner, Byte OwnerLevel) in C:\51
65\5165 Source\Game\Mob.cs:line 542
01/22/2011 18:56 Arcо#2
if (Mob != null)
01/22/2011 20:17 _tao4229_#3
'Char' is null probably.