بسم الله الرحمان الرحيم هتخش علي GameState.cs وي دور علي كود PHP: public bool Reborn(byte toClass) وي بدلو بي ده كود PHP: public bool Reborn(byte toClass) { #region Items if (Inventory.Count > 37) return false; switch (toClass) { case 11: case 21: case 51: case 61: case 71: { Inventory.Add(410077, Game.Enums.ItemEffect.Poison); break; } case 41: { Inventory.Add(500057, Game.Enums.ItemEffect.Shield); break; } case 132: case 142: { if (toClass == 132) Inventory.Add(421077, Game.Enums.ItemEffect.MP); else Inventory.Add(421077, Game.Enums.ItemEffect.HP); break; } } #region Low level items for (byte i = 1; i < 9; i++) { if (i != 7) { ConquerItem item = Equipment.TryGetItem(i); if (item != null && item.ID != 0) { try { //UnloadItemStats(item, false); Data.....ConquerItemInformation cii = new Conquer_Online_Server.Data.....ConquerItemInformation(item.ID, item.Plus); item.ID = cii.LowestID(Network.PacketHandler.ItemMinLevel(Network.PacketHandler.ItemPosition(item.ID))); item.Mode = Conquer_Online_Server.Game.Enums.ItemMode.Update; item.Send(this); LoadItemStats(); Data.....ConquerItemTable.UpdateItemID(item, this); } catch { Console.......Line("Reborn item problem: " + item.ID); } } } } ConquerItem hand = Equipment.TryGetItem(5); if (hand != null) { Equipment.Remove(5); CalculateStatBonus(); CalculateHPBonus(); } hand = Equipment.TryGetItem(25); if (hand != null) { Equipment.Remove(25); CalculateStatBonus(); CalculateHPBonus(); } LoadItemStats(); SendScreen(Entity.SpawnPacket, false); #endregion #endregion if (Entity.Reborn == 0) { Entity.FirstRebornClass = Entity.Class; Entity.FirstRebornLevel = Entity.Level; Entity.Atributes = (ushort)(ExtraAtributePoints(Entity.FirstRebornClass, Entity.FirstRebornLevel) + 52); } else { Entity.SecondRebornClass = Entity.Class; Entity.SecondRebornLevel = Entity.Level; Entity.Atributes = (ushort)(ExtraAtributePoints(Entity.FirstRebornClass, Entity.FirstRebornLevel) + ExtraAtributePoints(Entity.SecondRebornClass, Entity.SecondRebornLevel) + 62); } byte PreviousClass = Entity.Class; Entity.Reborn++; Entity.Class = toClass; Entity.Level = 15; Entity.Experience = 0; #region Spells Interfaces.ISkill[] spells = Spells.Values.ToArray(); foreach (Interfaces.ISkill spell in spells) { spell.PreviousLevel = spell.Level; spell.Level = 0; spell.Experience = 0; #region KungFuKing if (PreviousClass == 85) { if (Entity.Class != 81) { switch (spell.ID) { case 12120: case 12130: case 12140: case 12160: case 12170: case 12200: case 12240: case 12350: case 12270: case 12280: case 12290: case 12300: case 12320: case 12330: case 12340: RemoveSpell(spell); break; } } } #endregion #region Pirate if (PreviousClass == 75) { if (Entity.Class != 71) { switch (spell.ID) { case 11110: case 11040: case 11050: case 11060: case 11100: case 11120: case 11130: case 11030: RemoveSpell(spell); break; } } } #endregion #region Monk if (PreviousClass == 65) { if (Entity.Class != 61) { switch (spell.ID) { case 10490: case 10415: case 10381: RemoveSpell(spell); break; } } } #endregion #region Warrior if (PreviousClass == 25) { if (Entity.Class != 21) { switch (spell.ID) { case 1025: if (Entity.Class != 21 && Entity.Class != 132) RemoveSpell(spell); break; } } } #endregion #region Ninja if (toClass != 51) { switch (spell.ID) { case 6010: case 6000: case 6011: RemoveSpell(spell); break; } } #endregion #region Trojan if (toClass != 11) { switch (spell.ID) { case 1115: RemoveSpell(spell); break; } } #endregion #region Archer if (toClass != 41) { switch (spell.ID) { case 8001: case 8000: case 8003: case 9000: case 8002: case 8030: RemoveSpell(spell); break; } } #endregion #region WaterTaoist if (PreviousClass == 135) { if (toClass != 132) { switch (spell.ID) { case 1000: case 1001: case 1010: case 1125: case 1100: case 8030: RemoveSpell(spell); break; case 1050: case 1175: case 1170: if (toClass != 142) RemoveSpell(spell); break; } } } #endregion #region FireTaoist if (PreviousClass == 145) { if (toClass != 142) { switch (spell.ID) { case 1000: case 1001: case 1150: case 1180: case 1120: case 1002: case 1160: case 1165: RemoveSpell(spell); break; } } } #endregion if (Spells.ContainsKey(spell.ID)) if (spell.ID != (ushort)Game.Enums.SkillIDs.Reflect) spell.Send(this); } #endregion #region Proficiencies foreach (Interfaces.IProf proficiency in Proficiencies.Values) { proficiency.PreviousLevel = proficiency.Level; proficiency.Level = 0; proficiency.Experience = 0; proficiency.Send(this); } #endregion #region Adding earned skills if (Entity.Reborn == 2) AddSpell(new Spell(true) { ID = 9876 }); if (toClass == 51 && PreviousClass == 55 && Entity.Reborn == 1) AddSpell(new Spell(true) { ID = 6002 }); if (toClass == 81 && PreviousClass == 85 && Entity.Reborn == 1) AddSpell(new Spell(true) { ID = 12280 }); if (Entity.FirstRebornClass == 85 && Entity.SecondRebornClass == 85 && Entity.Class == 81 && Entity.Reborn == 2) AddSpell(new Spell(true) { ID = 12300 }); if (Entity.FirstRebornClass == 15 && Entity.SecondRebornClass == 15 && Entity.Class == 11 && Entity.Reborn == 2) AddSpell(new Spell(true) { ID = 10315 }); if (Entity.FirstRebornClass == 25 && Entity.SecondRebornClass == 25 && Entity.Class == 21 && Entity.Reborn == 2) AddSpell(new Spell(true) { ID = 10311 }); if (Entity.FirstRebornClass == 45 && Entity.SecondRebornClass == 45 && Entity.Class == 41 && Entity.Reborn == 2) AddSpell(new Spell(true) { ID = 10313 }); if (Entity.FirstRebornClass == 55 && Entity.SecondRebornClass == 55 && Entity.Class == 51 && Entity.Reborn == 2) AddSpell(new Spell(true) { ID = 6003 }); if (Entity.FirstRebornClass == 65 && Entity.SecondRebornClass == 65 && Entity.Class == 61 && Entity.Reborn == 2) AddSpell(new Spell(true) { ID = 10405 }); if (Entity.FirstRebornClass == 135 && Entity.SecondRebornClass == 135 && Entity.Class == 132 && Entity.Reborn == 2) AddSpell(new Spell(true) { ID = 30000 }); if (Entity.FirstRebornClass == 145 && Entity.SecondRebornClass == 145 && Entity.Class == 142 && Entity.Reborn == 2) AddSpell(new Spell(true) { ID = 10310 }); if (Entity.Reborn == 1) { if (Entity.FirstRebornClass == 75 && Entity.Class == 71) { AddSpell(new Spell(true) { ID = 3050 }); } if (Entity.FirstRebornClass == 15 && Entity.Class == 11) { AddSpell(new Spell(true) { ID = 3050 }); } else if (Entity.FirstRebornClass == 25 && Entity.Class == 21) { AddSpell(new Spell(true) { ID = 3060 }); } else if (Entity.FirstRebornClass == 145 && Entity.Class == 142) { AddSpell(new Spell(true) { ID = 3080 }); } else if (Entity.FirstRebornClass == 135 && Entity.Class == 132) { AddSpell(new Spell(true) { ID = 3090 }); } } if (Entity.Reborn == 2) { if (Entity.SecondRebornClass == 75 && Entity.Class == 71) { AddSpell(new Spell(true) { ID = 3050 }); } if (Entity.SecondRebornClass == 15 && Entity.Class == 11) { AddSpell(new Spell(true) { ID = 3050 }); } else if (Entity.SecondRebornClass == 25) { AddSpell(new Spell(true) { ID = 3060 }); } else if (Entity.SecondRebornClass == 145 && Entity.Class == 142) { AddSpell(new Spell(true) { ID = 3080 }); } else if (Entity.SecondRebornClass == 135 && Entity.Class == 132) { AddSpell(new Spell(true) { ID = 3090 }); } } #endregion Data.....DataHolder.GetStats(Entity.Class, Entity.Level, this); CalculateStatBonus(); CalculateHPBonus(); GemAlgorithm(); using (var conn = Data.....DataHolder.MySqlConnection) { conn.Open(); Data.....EntityTable.SaveEntity(this, conn); Data.....SkillTable.SaveSpells(this, conn); Data.....SkillTable.SaveProficiencies(this, conn); Data.....SkillTable.SaveSpells(this); Data.....SkillTable.SaveProficiencies(this); } Kernel.SendWorldMessage(new Message("" + Entity.Name + " has got " + Entity.Reborn + " reborns. Congratulations!", System.Drawing.Color.White, Message.Center), Program.Values); return true;//edit By MrHamo } بعد كدا خش علي PacketHandler.cs وي دور علي كود PHP: public static byte ItemMinLevel(ushort postion) وي بدلو بي ده كود PHP: public static byte ItemMinLevel(ushort postion) { switch (postion) { case 0: return 0; case ConquerItem.Head: return 15; case ConquerItem.Necklace: return 7; case ConquerItem.Armor: return 15; case ConquerItem.LeftWeapon: return 40; case ConquerItem.RightWeapon: return 5; case ConquerItem.Boots: return 10; case ConquerItem.Ring: return 10; case ConquerItem.Tower: return 0; case ConquerItem.Fan: return 0; case ConquerItem.Wing: return 0; case ConquerItem.Steed: return 0; case ConquerItem.SteedCrop: return 0; } return 0; } بعد كدا تخش علي كود PHP: class ConquerItemInformation تحط ده او تبدلو مكان الي عاندك كود PHP: public uint LowestID(byte Level) { if (....Information.ID / 1000 == 616)// Epic Ninja { return (uint)(616010 + ....Information.ID % 10); } if (....Information.ID / 1000 == 620)//Divin Backsword { return (uint)(620003 + ....Information.ID % 10); } if (....Information.ID / 1000 == 619)//Hossu { return (uint)(619000 + ....Information.ID % 10); } var grades = GradeInformations[this.....Information.Description]; if (grades == null) return ....Information.ID; for (byte gr = 0; gr < grades.Count; gr++) if (grades[gr].Level == Level) return (uint)((grades[gr + 1].ID / 10) * 10 + ....Information.ID % 10); return (uint)((grades[0].ID / 10) * 10 + ....Information.ID % 10); } public uint CalculateDownlevel() { if (....Information.ID / 1000 == 616) { return (uint)(616010 + ....Information.ID % 10); } if (....Information.ID / 1000 == 620) { return (uint)(620003 + ....Information.ID % 10); } if (....Information.ID / 1000 == 619)//Hossu { return (uint)(619000 + ....Information.ID % 10); } var grades = GradeInformations[this.....Information.Description]; if (grades == null) return ....Information.ID; if (grades[....Information.GradeKey - 1] == null) return ....Information.ID; else return (uint)((grades[....Information.GradeKey - 1].ID / 10) * 10 + ....Information.ID % 10); } #الاسطورة #HamoCoOL