قديم 2020-03-25, 02:18 PM
المشاركة 2
MRonlineGvrix
.:: عضو مميز ::.
  • غير متواجد
افتراضي رد: مشكلة فى البيرفكشن
عدل برحتك


كود:
        public void Handle(Client.GameState clientbyte[] myPacket)
        {
            try
            {
                switch (
Info.ActionId)
                {
                    case 
0://Temper
                        
{
                            
#region Minors
                            
var packet2 = new byte[myPacket.Length 4];
                            Array.
Copy(myPacket4packet20packet2.Length);
                            var 
variable Kernel.Read7BitEncodedInt(packet2).SelectMany(System.BitConverter.GetBytes).ToArray();
                            var 
variable2 = new byte[variable.Length 8];
                            Array.
Copy(variable8variable20variable.Length 8);
                            var 
MinorsCount = (variable2.Length 4);
                            
uint[] Minors = new uint[MinorsCount];
                            
byte x 0;
                            for (
int i 0MinorsCounti++)
                            {
                                
Minors[i] = BitConverter.ToUInt32(variable2x);
                                
+= 4;
                            }
                            
#endregion
                            
if (Minors != null)
                            {
                                
ConquerItem Item;
                                if (
client.Equipment.TryGetItem(Info.ItemUIDout Item))
                                {
                                    foreach (var 
minor in Minors)
                                    {
                                        
ConquerItem ItemPlus;
                                        if (
client.Inventory.TryGetItem(minorout ItemPlus))
                                        {
                                            if (
ItemPlus.ID == 730001
                                           
|| ItemPlus.ID == 730002
                                           
|| ItemPlus.ID == 730003
                                           
|| ItemPlus.ID == 730004
                                           
|| ItemPlus.ID == 730005
                                           
|| ItemPlus.ID == 730006
                                           
|| ItemPlus.ID == 730007
                                           
|| ItemPlus.ID == 730008) { client.MessageBox("You can't temp the perfection with a stone "); return; }
                                            if (
ItemPlus.ID == 300000) { client.MessageBox("You can't temp the perfection with a steed "); return; }
                                            
Item.PerfectionProgress += GetPlusStonePoints(ItemPlus.ID == 300000 ItemPlus.Plus ItemPlus.ID)/*Database.PerfectionTable.CostList[ItemPlus.ID].Progress*/;
                                            
client.Inventory.Remove(minorGame.Enums.ItemUse.Removetrue);
                                        }
                                    }
                                    while (
Item.PerfectionProgress >= GetPerfectionProgress(Item)/*Database.PerfectionTable.UpgradeList.Where(i => i.Stars == (Item.Stars + 1)).FirstOrDefault().Progress*/)
                                    {
                                        
Item.PerfectionProgress -= GetPerfectionProgress(Item)/*Database.PerfectionTable.UpgradeList.Where(i => i.Stars == (Item.Stars + 1)).FirstOrDefault().Progress*/;
                                        
Item.Stars++;
                                    }
                                    while (
Item.Stars >= 54 && Item.PerfectionProgress 0)
                                    {
                                        
Item.Stars 54;
                                        
Item.PerfectionProgress 0;
                                    }
                                    
Item.Owner client.Entity.Name;
                                    
Item.OwnerUID client.Entity.UID;
                                    
Item.Mode Game.Enums.ItemMode.Update;
                                    
Item.Send(client);
                                    var 
proto Kernel.FinalizeProtoBuf((new MsgItemRefineOptProto2()
                                    {
                                        
ItemUID Item.UID,
                                        
EntityUID client.Entity.UID,
                                        
OwnerUID Item.OwnerUID,
                                        
OwnerName Item.Owner,
                                        
Progress Item.PerfectionProgress,
                                        
Stars Item.Stars
                                    
}), 3250);
                                    
client.LoadItemStats();
                                    
client.Send(proto);
                                    
Database.ConquerItemTable.UpdatePerfection(Item);
                                    new 
MsgUserTotalRefineLev().Send(client);

                                }
                            }

                            break;
                        } 



العلامات المرجعية



الذين يشاهدون محتوى الموضوع الآن : 1 ( الأعضاء 0 والزوار 1)
 

الانتقال السريع

المواضيع المتشابهه للموضوع: مشكلة فى البيرفكشن
الموضوع كاتب الموضوع المنتدى مشاركات آخر مشاركة
مشكلة فى ان بي سي البيرفكشن MRonlineGvrix مشكلات السيرفيرات كونكر الشخصيه 11 2020-01-25 07:15 AM
مشكلة في رانك البيرفكشن Avengers-Co مشكلات السيرفيرات كونكر الشخصيه 4 2019-09-02 12:54 AM


الساعة الآن 10:20 PM

Powered by vBulletin® Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.