منتدي اكواد

منتدي اكواد (https://code.vpscairo.com/index.php)
-   مشكلات السيرفيرات كونكر الشخصيه (https://code.vpscairo.com/forumdisplay.php?f=12)
-   -   حل السالب في الفلوس (https://code.vpscairo.com/showthread.php?t=3704)

مجدى 2020-02-16 02:55 PM

حل السالب في الفلوس
 
لما اكون فى البوكر والاميل يهنج بيجيلو فلوس بالسالب عايز اخلي ميجيش سالب

محمد ياسر 2020-02-16 11:57 PM

رد: حل السالب في الفلوس
 
جرب ملف conquer.exe نضيف

Rider 2020-02-17 12:11 AM

رد: حل السالب في الفلوس
 
اقتباس:

المشاركة الأصلية كتبت بواسطة مجدى (المشاركة 28806)
لما اكون فى البوكر والاميل يهنج بيجيلو فلوس بالسالب عايز اخلي ميجيش سالب

يهنج اذايرجاء وصف شامل لكل شئ او فيديو يوضح المشكله

مجدى 2020-02-17 10:41 PM

رد: حل السالب في الفلوس
 
اقتباس:

المشاركة الأصلية كتبت بواسطة rider (المشاركة 29021)
يهنج اذايرجاء وصف شامل لكل شئ او فيديو يوضح المشكله

مثلا لو النت فصل والاميل قفل او اللعبة قفلت او اي طريقة الاميل يقفل بيها يفتح بعدها يلاقى معاه فلوس بالسالب

bosha1 2020-02-18 12:54 AM

رد: حل السالب في الفلوس
 
اقتباس:

المشاركة الأصلية كتبت بواسطة Rider (المشاركة 29021)
يهنج اذايرجاء وصف شامل لكل شئ او فيديو يوضح المشكله


حضرتك دا وصف المشكله بظبط

ان لما حد يقفل الايميل وهوا قاعد ع التربيزا

الاكونت بيفضل قاعد ع التربيزا والى قاعد بيلعب معاه بيكون بيلعب ويفضل الاكونت الى قفل ومهنج قاعد ويفلد يجى

يفتح بقا يلاقى الفلوس سالب وكمان الى قاعد بيلعب معاه بيجيلو هوا كمان الفلوس سالب وانا عامل موضوع بالصور لتوضيح اكتر




دا رابط الموضوع

https://code.vpscairo.com/showthread.php?t=3746

ياريت تشوفلنا حل ي رجوله

Rider 2020-02-18 07:25 PM

رد: حل السالب في الفلوس
 
سيرش علي shutdown
خش جواها و ضيف
كود PHP:

PokerHandler.ShutDown(this); 


bosha1 2020-02-18 09:31 PM

رد: حل السالب في الفلوس
 
اقتباس:

المشاركة الأصلية كتبت بواسطة rider (المشاركة 29512)
سيرش علي shutdown
خش جواها و ضيف
كود PHP:

pokerhandler.shutdown(this); 


ياريت ي باشا تقولى انهى كلاس فيهم عشان عملت سيرش طلع ليا كذا كود

وتقولى اضيفو فين بظبط

Rider 2020-02-18 10:12 PM

رد: حل السالب في الفلوس
 
اقتباس:

المشاركة الأصلية كتبت بواسطة bosha1 (المشاركة 29554)
ياريت ي باشا تقولى انهى كلاس فيهم عشان عملت سيرش طلع ليا كذا كود

وتقولى اضيفو فين بظبط

سيرش client.disconnect

و اقف علي disconnect
و دوس اف 12 هتلاقي shutdown تحتها او ضفها جوه disconnect عادي مفيش مشكله

bosha1 2020-02-18 11:06 PM

رد: حل السالب في الفلوس
 
بضيفو ي صحبى

بيجبلى ايرور

دا ي صحبى الكود معلش ضيفو انت وادهوالى

دا ي صحبى الكود


كود:

public void Disconnect(bool save = true)
        {
            if (Fake) return;
            if (Screen != null) Screen.DisposeTimers();
            PacketHandler.RemoveTPA(this);
            Program.World.Unregister(this);
            if (OnDisconnect != null) OnDisconnect(this);
            if (_socket.Connector != null)
            {
                _socket.Disconnect();
                //foreach (var c in LoaderClient.CLients)/////
                //{
                //    if (this.Account != null)
                //    {
                //        if (c.Username == this.Account.Username)
                //        {
                //            c.Disconnect();
                //            LoaderClient.CLients.Remove(c);
                //        }
                //    }
                //}
                ShutDown();
            }
            /*    if (_socket.Connector != null)
                {
                    if (Entity != null)
                    {
                        if (Entity.MyPokerTable != null)
                        {
                            if (Entity.MyPokerTable.Entitys.ContainsKey(Entity.UID) && Entity.MyPokerTable.Pot > 1)
                            {
                                byte[] P = new byte[10];
                                P[6] = 4; P[9] = 200;
                                Entity.MyPokerTable.NewEntityMove(P, Entity.UID);
                            }
                            else
                                Entity.MyPokerTable.RemoveEntity(Entity.UID);
                        }
                    }
                    _socket.Disconnect();
                    ShutDown();
                }*/
        }




ودا الكود التانى

كود:

private void ShutDown()
        {
            if (Socket.Connector == null) return;
            Socket.Connector = null;
            if (this.Entity != null)
            {
                try
                {
                    if (this.Entity.JustCreated) return;
                    Time32 now = Time32.Now;
                    Kernel.DisconnectPool.Add(this.Entity.UID, this);
                    RemoveScreenSpawn(this.Entity, false);

                    Database.EntityTable.UpdateOnlineStatus(this, false);
                    using (var conn = Database.DataHolder.MySqlConnection)
                    {
                        conn.Open();
                        NobilityOff.Save(this, conn);
                    }
                   
                    Database.EntityTable.SaveEntity(this);
                    if (!TransferedEntity)
                        Database.EntityVariableTable.Save(this);
                    Database.SkillTable.SaveProficiencies(this);
                    if (!TransferedEntity)
                    {
                        Database.ArenaTable.SaveArenaStatistics(this.ArenaStatistic);
                        Database.TeamArenaTable.SaveArenaStatistics(this.TeamArenaStatistic);
                    }
                    Kernel.GamePool.Remove(this.Entity.UID);

                    if (Booth != null)
                        Booth.Remove();

                    if (Quests != null)
                        Quests.Save();
                   
                    if (Pet != null)
                        Pet.ClearAll();
                    if (QualifierGroup != null)
                        QualifierGroup.End(this);
                    if (TeamQualifierGroup != null)
                        TeamQualifierGroup.CheckEnd(this, true);
                    if (Entity.CLanArenaBattleFight != null)
                        Entity.CLanArenaBattleFight.CheakToEnd(this, true);
                    if (Entity.GuildArenaBattleFight != null)
                        Entity.GuildArenaBattleFight.CheakToEnd(this, true);
                    if (Entity.MyClones.Count > 0)
                    {
                       
                        foreach (var item in Entity.MyClones.Values)
                        {
                            MsgActionProto Action = new MsgActionProto();
                            Action.UID = item.UID;
                            Action.TimeStamp = (uint)Time32.Now.GetHashCode();
                            Action.ID = MsgActionEmulator.RemoveEntity;
                            SendScreen(MsgActionEmulator.SendPacket(Action));
                        }
                        Entity.MyClones.Clear();
                    }
                    if (Challenge != null)
                        Challenge.End(this);
                    EndQualifier();

                    Database.SkillTable.SaveClientSpells(this);
                    Game.Arena.Clear(this);
                    Game.TeamArena.Clear(this);
                   
                    RemoveScreenSpawn(this.Entity, false);

                    #region Friend/TradePartner/Apprentice
                    Message msg = new Message("Your friend, " + Entity.Name + ", has logged off.", System.Drawing.Color.Red, Message.TopLeft);
                    if (Friends == null)
                        Friends = new SafeDictionary<uint, Game.ConquerStructures.Society.Friend>(100);
                    foreach (Game.ConquerStructures.Society.Friend friend in Friends.Values)
                    {
                        if (friend.IsOnline)
                        {
                            var packet = new Network.GamePackets.KnownPersons(true)
                            {
                                UID = Entity.UID,
                                Type = Network.GamePackets.KnownPersons.RemovePerson,
                                Name = Entity.Name,
                                Online = false
                            };
                            friend.Client.Send(packet);
                            packet.Type = Network.GamePackets.KnownPersons.AddFriend;
                            if (friend != null)
                            {
                                if (friend.Client != null)
                                {
                                    friend.Client.Send(packet);
                                    friend.Client.Send(msg);
                                }
                            }
                        }
                    }
                    Message msg2 = new Message("Your partner, " + Entity.Name + ", has logged off.", System.Drawing.Color.Red, Message.TopLeft);

                    if (Partners != null)
                    {
                        foreach (Game.ConquerStructures.Society.TradePartner partner in Partners.Values)
                        {
                            if (partner.IsOnline)
                            {
                                var packet = new TradePartner(true)
                                {
                                    UID = Entity.UID,
                                    Type = TradePartner.BreakPartnership,
                                    Name = Entity.Name,
                                    HoursLeft = (int)(new TimeSpan(partner.ProbationStartedOn.AddDays(3).Ticks).TotalHours - new TimeSpan(DateTime.Now.Ticks).TotalHours),
                                    Online = false
                                };
                                partner.Client.Send(packet);
                                packet.Type = TradePartner.AddPartner;
                                if (partner != null)
                                {
                                    if (partner.Client != null)
                                    {
                                        partner.Client.Send(packet);
                                        partner.Client.Send(msg2);
                                    }
                                }
                            }
                        }
                    }
                    MentorInformation Information = new MentorInformation(true);
                    Information.Mentor_Type = 1;
                    Information.Mentor_ID = Entity.UID;
                    Information.Mentor_Level = Entity.Level;
                    Information.Mentor_Class = Entity.Class;
                    Information.Mentor_PkPoints = Entity.PKPoints;
                    Information.Mentor_Mesh = Entity.Mesh;
                    Information.Mentor_Online = false;
                    Information.String_Count = 3;
                    Information.Mentor_Name = Entity.Name;
                    Information.Mentor_Spouse_Name = Entity.Spouse;
                    if (Apprentices == null) Apprentices = new SafeDictionary<uint, Game.ConquerStructures.Society.Apprentice>();
                    foreach (var appr in Apprentices.Values)
                    {
                        if (appr.IsOnline)
                        {
                            Information.Apprentice_ID = appr.ID;
                            Information.Enrole_Date = appr.EnroleDate;
                            Information.Apprentice_Name = appr.Name;
                            appr.Client.Send(Information);
                            appr.Client.ReviewMentor();
                        }
                    }
                    if (Mentor != null)
                    {
                        if (Mentor.IsOnline)
                        {
                            ApprenticeInformation AppInfo = new ApprenticeInformation();
                            AppInfo.Apprentice_ID = Entity.UID;
                            AppInfo.Apprentice_Level = Entity.Level;
                            AppInfo.Apprentice_Name = Entity.Name;
                            AppInfo.Apprentice_Online = false;
                            AppInfo.Apprentice_Spouse_Name = Entity.Spouse;
                            AppInfo.Enrole_date = Mentor.EnroleDate;
                            AppInfo.Mentor_ID = Mentor.Client.Entity.UID;
                            AppInfo.Mentor_Mesh = Mentor.Client.Entity.Mesh;
                            AppInfo.Mentor_Name = Mentor.Client.Entity.Name;
                            AppInfo.Type = 2;
                            Mentor.Client.Send(AppInfo);
                        }
                    }

                    #endregion
                    #region Team
                    /* if (Team != null)
                    {
                        if (Team.TeamLeader)
                        {
                            Network.GamePackets.Team team = new Network.GamePackets.Team();
                            team.UID = Account.EntityID;
                            team.Type = Network.GamePackets.Team.Dismiss;
                            foreach (Client.GameState Teammate in Team.Teammates)
                            {
                                if (Teammate != null)
                                {
                                    if (Teammate.Entity.UID != Account.EntityID)
                                    {
                                        Teammate.Send(team);
                                        Teammate.Team = null;
                                    }
                                }
                            }
                        }
                        else
                        {
                            Network.GamePackets.Team team = new Network.GamePackets.Team();
                            team.UID = Account.EntityID;
                            team.Type = Network.GamePackets.Team.ExitTeam;
                            foreach (Client.GameState Teammate in Team.Teammates)
                            {
                                if (Teammate != null)
                                {
                                    if (Teammate.Entity.UID != Account.EntityID)
                                    {
                                        Teammate.Send(team);
                                        Teammate.Team.Remove(this);
                                    }
                                }
                            }
                        }
                    }*/
                    #endregion
                    if (Team != null)
                    {
                        Team.Remove(this, true);
                    }
                }
                catch (Exception e)
                {
                    Program.SaveException(e);
                }
                finally
                {
                    Kernel.DisconnectPool.Remove(this.Entity.UID);
                    Console.WriteLine("Player " + this.Entity.Name + "*Has logged off*" + "[IP]" + this.Account.IP + "" , ConsoleColor.Red);
                }
            }
        }


ودا الايرور الى بيجيلى

معلش ي صحبى هتعبك معايا بس انا نفسى احل المشكله دى


https://www2.0zz0.com/2020/02/19/00/780827033.png

bosha1 2020-02-18 11:07 PM

رد: حل السالب في الفلوس
 
اقتباس:

المشاركة الأصلية كتبت بواسطة Rider (المشاركة 29556)
سيرش client.disconnect

و اقف علي disconnect
و دوس اف 12 هتلاقي shutdown تحتها او ضفها جوه disconnect عادي مفيش مشكله

بضيفو ي صحبى

بيجبلى ايرور

دا ي صحبى الكود معلش ضيفو انت وادهوالى

دا ي صحبى الكود


كود:

public void Disconnect(bool save = true)
        {
            if (Fake) return;
            if (Screen != null) Screen.DisposeTimers();
            PacketHandler.RemoveTPA(this);
            Program.World.Unregister(this);
            if (OnDisconnect != null) OnDisconnect(this);
            if (_socket.Connector != null)
            {
                _socket.Disconnect();
                //foreach (var c in LoaderClient.CLients)/////
                //{
                //    if (this.Account != null)
                //    {
                //        if (c.Username == this.Account.Username)
                //        {
                //            c.Disconnect();
                //            LoaderClient.CLients.Remove(c);
                //        }
                //    }
                //}
                ShutDown();
            }
            /*    if (_socket.Connector != null)
                {
                    if (Entity != null)
                    {
                        if (Entity.MyPokerTable != null)
                        {
                            if (Entity.MyPokerTable.Entitys.ContainsKey(Entity.UID) && Entity.MyPokerTable.Pot > 1)
                            {
                                byte[] P = new byte[10];
                                P[6] = 4; P[9] = 200;
                                Entity.MyPokerTable.NewEntityMove(P, Entity.UID);
                            }
                            else
                                Entity.MyPokerTable.RemoveEntity(Entity.UID);
                        }
                    }
                    _socket.Disconnect();
                    ShutDown();
                }*/
        }




ودا الكود التانى

كود:

private void ShutDown()
        {
            if (Socket.Connector == null) return;
            Socket.Connector = null;
            if (this.Entity != null)
            {
                try
                {
                    if (this.Entity.JustCreated) return;
                    Time32 now = Time32.Now;
                    Kernel.DisconnectPool.Add(this.Entity.UID, this);
                    RemoveScreenSpawn(this.Entity, false);

                    Database.EntityTable.UpdateOnlineStatus(this, false);
                    using (var conn = Database.DataHolder.MySqlConnection)
                    {
                        conn.Open();
                        NobilityOff.Save(this, conn);
                    }
                   
                    Database.EntityTable.SaveEntity(this);
                    if (!TransferedEntity)
                        Database.EntityVariableTable.Save(this);
                    Database.SkillTable.SaveProficiencies(this);
                    if (!TransferedEntity)
                    {
                        Database.ArenaTable.SaveArenaStatistics(this.ArenaStatistic);
                        Database.TeamArenaTable.SaveArenaStatistics(this.TeamArenaStatistic);
                    }
                    Kernel.GamePool.Remove(this.Entity.UID);

                    if (Booth != null)
                        Booth.Remove();

                    if (Quests != null)
                        Quests.Save();
                   
                    if (Pet != null)
                        Pet.ClearAll();
                    if (QualifierGroup != null)
                        QualifierGroup.End(this);
                    if (TeamQualifierGroup != null)
                        TeamQualifierGroup.CheckEnd(this, true);
                    if (Entity.CLanArenaBattleFight != null)
                        Entity.CLanArenaBattleFight.CheakToEnd(this, true);
                    if (Entity.GuildArenaBattleFight != null)
                        Entity.GuildArenaBattleFight.CheakToEnd(this, true);
                    if (Entity.MyClones.Count > 0)
                    {
                       
                        foreach (var item in Entity.MyClones.Values)
                        {
                            MsgActionProto Action = new MsgActionProto();
                            Action.UID = item.UID;
                            Action.TimeStamp = (uint)Time32.Now.GetHashCode();
                            Action.ID = MsgActionEmulator.RemoveEntity;
                            SendScreen(MsgActionEmulator.SendPacket(Action));
                        }
                        Entity.MyClones.Clear();
                    }
                    if (Challenge != null)
                        Challenge.End(this);
                    EndQualifier();

                    Database.SkillTable.SaveClientSpells(this);
                    Game.Arena.Clear(this);
                    Game.TeamArena.Clear(this);
                   
                    RemoveScreenSpawn(this.Entity, false);

                    #region Friend/TradePartner/Apprentice
                    Message msg = new Message("Your friend, " + Entity.Name + ", has logged off.", System.Drawing.Color.Red, Message.TopLeft);
                    if (Friends == null)
                        Friends = new SafeDictionary<uint, Game.ConquerStructures.Society.Friend>(100);
                    foreach (Game.ConquerStructures.Society.Friend friend in Friends.Values)
                    {
                        if (friend.IsOnline)
                        {
                            var packet = new Network.GamePackets.KnownPersons(true)
                            {
                                UID = Entity.UID,
                                Type = Network.GamePackets.KnownPersons.RemovePerson,
                                Name = Entity.Name,
                                Online = false
                            };
                            friend.Client.Send(packet);
                            packet.Type = Network.GamePackets.KnownPersons.AddFriend;
                            if (friend != null)
                            {
                                if (friend.Client != null)
                                {
                                    friend.Client.Send(packet);
                                    friend.Client.Send(msg);
                                }
                            }
                        }
                    }
                    Message msg2 = new Message("Your partner, " + Entity.Name + ", has logged off.", System.Drawing.Color.Red, Message.TopLeft);

                    if (Partners != null)
                    {
                        foreach (Game.ConquerStructures.Society.TradePartner partner in Partners.Values)
                        {
                            if (partner.IsOnline)
                            {
                                var packet = new TradePartner(true)
                                {
                                    UID = Entity.UID,
                                    Type = TradePartner.BreakPartnership,
                                    Name = Entity.Name,
                                    HoursLeft = (int)(new TimeSpan(partner.ProbationStartedOn.AddDays(3).Ticks).TotalHours - new TimeSpan(DateTime.Now.Ticks).TotalHours),
                                    Online = false
                                };
                                partner.Client.Send(packet);
                                packet.Type = TradePartner.AddPartner;
                                if (partner != null)
                                {
                                    if (partner.Client != null)
                                    {
                                        partner.Client.Send(packet);
                                        partner.Client.Send(msg2);
                                    }
                                }
                            }
                        }
                    }
                    MentorInformation Information = new MentorInformation(true);
                    Information.Mentor_Type = 1;
                    Information.Mentor_ID = Entity.UID;
                    Information.Mentor_Level = Entity.Level;
                    Information.Mentor_Class = Entity.Class;
                    Information.Mentor_PkPoints = Entity.PKPoints;
                    Information.Mentor_Mesh = Entity.Mesh;
                    Information.Mentor_Online = false;
                    Information.String_Count = 3;
                    Information.Mentor_Name = Entity.Name;
                    Information.Mentor_Spouse_Name = Entity.Spouse;
                    if (Apprentices == null) Apprentices = new SafeDictionary<uint, Game.ConquerStructures.Society.Apprentice>();
                    foreach (var appr in Apprentices.Values)
                    {
                        if (appr.IsOnline)
                        {
                            Information.Apprentice_ID = appr.ID;
                            Information.Enrole_Date = appr.EnroleDate;
                            Information.Apprentice_Name = appr.Name;
                            appr.Client.Send(Information);
                            appr.Client.ReviewMentor();
                        }
                    }
                    if (Mentor != null)
                    {
                        if (Mentor.IsOnline)
                        {
                            ApprenticeInformation AppInfo = new ApprenticeInformation();
                            AppInfo.Apprentice_ID = Entity.UID;
                            AppInfo.Apprentice_Level = Entity.Level;
                            AppInfo.Apprentice_Name = Entity.Name;
                            AppInfo.Apprentice_Online = false;
                            AppInfo.Apprentice_Spouse_Name = Entity.Spouse;
                            AppInfo.Enrole_date = Mentor.EnroleDate;
                            AppInfo.Mentor_ID = Mentor.Client.Entity.UID;
                            AppInfo.Mentor_Mesh = Mentor.Client.Entity.Mesh;
                            AppInfo.Mentor_Name = Mentor.Client.Entity.Name;
                            AppInfo.Type = 2;
                            Mentor.Client.Send(AppInfo);
                        }
                    }

                    #endregion
                    #region Team
                    /* if (Team != null)
                    {
                        if (Team.TeamLeader)
                        {
                            Network.GamePackets.Team team = new Network.GamePackets.Team();
                            team.UID = Account.EntityID;
                            team.Type = Network.GamePackets.Team.Dismiss;
                            foreach (Client.GameState Teammate in Team.Teammates)
                            {
                                if (Teammate != null)
                                {
                                    if (Teammate.Entity.UID != Account.EntityID)
                                    {
                                        Teammate.Send(team);
                                        Teammate.Team = null;
                                    }
                                }
                            }
                        }
                        else
                        {
                            Network.GamePackets.Team team = new Network.GamePackets.Team();
                            team.UID = Account.EntityID;
                            team.Type = Network.GamePackets.Team.ExitTeam;
                            foreach (Client.GameState Teammate in Team.Teammates)
                            {
                                if (Teammate != null)
                                {
                                    if (Teammate.Entity.UID != Account.EntityID)
                                    {
                                        Teammate.Send(team);
                                        Teammate.Team.Remove(this);
                                    }
                                }
                            }
                        }
                    }*/
                    #endregion
                    if (Team != null)
                    {
                        Team.Remove(this, true);
                    }
                }
                catch (Exception e)
                {
                    Program.SaveException(e);
                }
                finally
                {
                    Kernel.DisconnectPool.Remove(this.Entity.UID);
                    Console.WriteLine("Player " + this.Entity.Name + "*Has logged off*" + "[IP]" + this.Account.IP + "" , ConsoleColor.Red);
                }
            }
        }


ودا الايرور الى بيجيلى

معلش ي صحبى هتعبك معايا بس انا نفسى احل المشكله دى


https://www2.0zz0.com/2020/02/19/00/780827033.png


الساعة الآن 01:37 AM

مرحبا بكم في منتدي اكواد لتطوير الالعاب