بسم الله الرحمن الرحيم
موضوعنا النهارده ازاى نخلى الوحوش توقع ايتميات معينه
يلا ندخل في الموضوع علي طول
في كلاس
- MonsterTable
اتنزل لحد ماتلقي
- #region
اتحط دول تحيهم بعد ما تقفل من السالب
#region DB CPS uint ran13 = (uint)Kernel.Random.Next(1, 50); if (ran13 > 15) { if (this.Name == "Pheasant") { if (killer.Name.Contains("Guard")) return; uint Uid = 0; Random R = new Random(); //int Nr = R.Next(1, 1); switch (((byte)Kernel.Random.Next(1, 50))) { case 1: Uid = 720996;//SmallCPBox break; case 2: Uid = 1088000; break; case 3: Uid = 720998;//LargCPBox break; case 4: Uid = 1088000; break; case 5: Uid = 720996;//SmallCPBox break; case 6: Uid = 1088001; break; } if (Uid != 0) { ushort X = Owner.X, Y = Owner.Y; Game.Map Map = Kernel.Maps[Owner.MapID]; if (Map.SelectCoordonates(ref X, ref Y)) { Network.GamePackets.FloorItem floorItem = new Network.GamePackets.FloorItem(true); floorItem.Item = new Network.GamePackets.ConquerItem(true); floorItem.Item.Color = (DeadPool.Game.Enums.Color)Kernel.Random.Next(4, 8); floorItem.Item.ID = Uid; floorItem.Item.MaximDurability = floorItem.Item.Durability = 65535; floorItem.Item.UID = Program.NextItemID; ; floorItem.ValueType = Network.GamePackets.FloorItem.FloorValueType.Item; floorItem.ItemID = Uid; floorItem.MapID = Owner.MapID; floorItem.MapObjType = Game.MapObjectType.Item; floorItem.X = X; floorItem.Y = Y; floorItem.Type = Network.GamePackets.FloorItem.Drop; floorItem.OnFloor = Time32.Now; floorItem.ItemColor = floorItem.Item.Color; floorItem.UID = Network.GamePackets.FloorItem.FloorUID.Next; while (Map.Npcs.ContainsKey(floorItem.UID)) floorItem.UID = Network.GamePackets.FloorItem.FloorUID.Next; Map.AddFloorItem(floorItem); SendScreenSpawn(floorItem); } } } } #endregion
تعال نفهم شويه حجات
if (this.Name == "Pheasant")
- Pheasant
- ده اسم الوحش الي في التون وممكن تغير لي وحش حسب مانت عايز الوحوش
Uid = 720996;//SmallCPBox
- 720996
- ده ايتيم الي الوحش المفترض يوقعه بعد ما يموت
وكده انا خلصت شرح بالتوفيق