⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 gameobjects.cs

📁 EBot source for the popular MMORPG World of Warcraft
💻 CS
📖 第 1 页 / 共 3 页
字号:
            }
            return 0;
        }

        public static object ShowType3()
        {
            try
            {
                if (Main.NeedInject == 0)
                {
                    Offset();
                    for (int i = 0; i <= 0xff; i++)
                    {
                        tab2_GUID[i] = "";
                        tab2_tName[i] = "";
                        tab2_tHealth[i] = "";
                        tab2_tLevel[i] = "";
                        tab2_tMaxHealth[i] = "";
                        tab2_tX[i] = "";
                        tab2_tY[i] = "";
                    }
                    int num5 = 0;
                    int curObj = GameObjects.curObj;
                    string[] strArray = new string[0x100];
                    int index = 0;
                    int num7 = 0;
                    int num10 = 0;
                    int num9 = 0;
                    int num11 = 0;
                    int num12 = 0;
                    int num6 = Conversions.ToInteger(func.ReadInt32(Offsets.PlayerTargetGUID));
                    while (GameObjects.curObj != 0)
                    {
                        if (Conversions.ToLong(func.ReadInt32(GameObjects.curObj + Offsets.ObjType)).ToString() == "3")
                        {
                            long num8 = Conversions.ToLong(func.ReadInt32(GameObjects.curObj + 0x30));
                            string str = Conversions.ToString(func.ReadASCIIString(Conversions.ToInteger(func.ReadInt32(Conversions.ToInteger(Operators.AddObject(func.ReadInt32(GameObjects.curObj + Offsets.UnitName1), Offsets.UnitName2))))));
                            num7 = Conversions.ToInteger(func.ReadInt32(Conversions.ToInteger(Operators.AddObject(func.ReadInt32(GameObjects.curObj + 8), Offsets.UnitHealth))));
                            num10 = Conversions.ToInteger(func.ReadInt32(Conversions.ToInteger(Operators.AddObject(func.ReadInt32(GameObjects.curObj + 8), Offsets.UnitMaxHealth))));
                            num9 = Conversions.ToInteger(func.ReadInt32(Conversions.ToInteger(Operators.AddObject(func.ReadInt32(GameObjects.curObj + 8), Offsets.UnitLevel))));
                            num11 = Conversions.ToInteger(func.ReadSingle(GameObjects.curObj + Offsets.UnitPos, 0));
                            num12 = Conversions.ToInteger(func.ReadSingle(GameObjects.curObj + Offsets.UnitPos, 4));
                            tab2_GUID[index] = num8.ToString();
                            tab2_tName[index] = str.ToString();
                            tab2_tHealth[index] = num7.ToString();
                            tab2_tLevel[index] = num9.ToString();
                            tab2_tMaxHealth[index] = num10.ToString();
                            tab2_tX[index] = num11.ToString();
                            tab2_tY[index] = num12.ToString();
                            strArray[index] = str.ToString();
                            index++;
                        }
                        num5 = Conversions.ToInteger(func.ReadInt32(GameObjects.curObj + 60));
                        if (num5 == GameObjects.curObj)
                        {
                            break;
                        }
                        GameObjects.curObj = num5;
                    }
                    GameObjects.curObj = curObj;
                    int num2 = 0;
                    MyProject.Forms.Config.ObjectListType3.Items.Clear();
                    while (num2 < index)
                    {
                        MyProject.Forms.Config.ObjectListType3.Items.Add(strArray[num2]);
                        num2++;
                    }
                }
            }
            catch (Exception exception1)
            {
                ProjectData.SetProjectError(exception1);
                Exception exception = exception1;
                ProjectData.ClearProjectError();
            }
            return 0;
        }

        public static object ShowType5()
        {
            try
            {
                if (Main.NeedInject == 0)
                {
                    Offset();
                    int num4 = 0;
                    int curObj = GameObjects.curObj;
                    string[] strArray = new string[0x100];
                    int index = 0;
                    while (GameObjects.curObj != 0)
                    {
                        long num7 = Conversions.ToLong(func.ReadInt32(GameObjects.curObj + Offsets.ObjType));
                        string str = Conversions.ToString(func.ReadASCIIString(Conversions.ToInteger(func.ReadInt32(Conversions.ToInteger(Operators.AddObject(func.ReadInt32(GameObjects.curObj + 420), 0x88))))));
                        float num5 = Conversions.ToSingle(func.ReadSingle(Conversions.ToInteger(Operators.AddObject(func.ReadInt32(Conversions.ToInteger(Operators.AddObject(func.ReadInt32(GameObjects.curObj + 0x1a0), 4))), 0xe8)), 0));
                        float num6 = Conversions.ToSingle(func.ReadSingle(Conversions.ToInteger(Operators.AddObject(func.ReadInt32(Conversions.ToInteger(Operators.AddObject(func.ReadInt32(GameObjects.curObj + 0x1a0), 4))), 0xe8)), 4));
                        if (num7.ToString() == "5")
                        {
                            string str2 = str.ToString();
                            string str3 = num5.ToString();
                            string str4 = num6.ToString();
                            strArray[index] = " X : " + str3 + " Y : " + str4 + " | " + str2;
                            index++;
                        }
                        num4 = Conversions.ToInteger(func.ReadInt32(GameObjects.curObj + 60));
                        if (num4 == GameObjects.curObj)
                        {
                            break;
                        }
                        GameObjects.curObj = num4;
                    }
                    GameObjects.curObj = curObj;
                    int num = 0;
                    MyProject.Forms.Config.ObjectListType5.Items.Clear();
                    while (num < index)
                    {
                        MyProject.Forms.Config.ObjectListType5.Items.Add(strArray[num]);
                        num++;
                    }
                }
            }
            catch (Exception exception1)
            {
                ProjectData.SetProjectError(exception1);
                Exception exception = exception1;
                ProjectData.ClearProjectError();
            }
            return 0;
        }

        public static object Target()
        {
            try
            {
                if (Main.NeedInject == 0)
                {
                    Offset();
                    int num2 = 0;
                    int curObj = GameObjects.curObj;
                    int num5 = 0;
                    int num8 = 0;
                    int num7 = 0;
                    int num10 = 0;
                    int num11 = 0;
                    int num3 = Conversions.ToInteger(func.ReadInt32(Offsets.PlayerTargetGUID));
                    while (GameObjects.curObj != 0)
                    {
                        int num12 = Conversions.ToInteger(func.ReadInt32(GameObjects.curObj + Offsets.ObjType));
                        if ((num12.ToString() == "3") | (num12.ToString() == "4"))
                        {
                            long num6 = Conversions.ToLong(func.ReadInt32(GameObjects.curObj + 0x30));
                            int num4 = Conversions.ToInteger(func.ReadInt32(Conversions.ToInteger(Operators.AddObject(func.ReadInt32(GameObjects.curObj + 8), Offsets.UnitFaction))));
                            string str = Conversions.ToString(func.ReadASCIIString(Conversions.ToInteger(func.ReadInt32(Conversions.ToInteger(Operators.AddObject(func.ReadInt32(GameObjects.curObj + Offsets.UnitName1), Offsets.UnitName2))))));
                            num5 = Conversions.ToInteger(func.ReadInt32(Conversions.ToInteger(Operators.AddObject(func.ReadInt32(GameObjects.curObj + 8), Offsets.UnitHealth))));
                            num8 = Conversions.ToInteger(func.ReadInt32(Conversions.ToInteger(Operators.AddObject(func.ReadInt32(GameObjects.curObj + 8), Offsets.UnitMaxHealth))));
                            num7 = Conversions.ToInteger(func.ReadInt32(Conversions.ToInteger(Operators.AddObject(func.ReadInt32(GameObjects.curObj + 8), Offsets.UnitLevel))));
                            num10 = Conversions.ToInteger(func.ReadSingle(GameObjects.curObj + Offsets.UnitPos, 0));
                            num11 = Conversions.ToInteger(func.ReadSingle(GameObjects.curObj + Offsets.UnitPos, 4));
                            int num9 = Conversions.ToInteger(func.ReadInt32(Conversions.ToInteger(Operators.AddObject(func.ReadInt32(GameObjects.curObj + 8), Offsets.UnitTarget))));
                            if (num3 == 0)
                            {
                                MyProject.Forms.Main.TargetLevel.Text = "- - -";
                                MyTargetGUID = 0;
                                MyProject.Forms.Main.TargetHealthBar.Value = 0;
                                MyProject.Forms.Main.TargetHealth.Text = "- - - / - - -";
                            }
                            if ((num6.ToString() == num3.ToString()) && (num3 != 0))
                            {
                                Main.tFaction = num4;
                                Main.targethealthamount = num5;
                                MyProject.Forms.Main.TargetLevel.Text = Conversions.ToString(num7);
                                Main.targetx = num10;
                                Main.targety = num11;
                                MyProject.Forms.Main.TargetHealth.Text = num5.ToString() + " / " + num8.ToString();
                                MyProject.Forms.Main.TargetHealthBar.Value = Conversions.ToInteger(func.percentdecimal(num5.ToString(), num8.ToString()));
                                Main.targettarget = num9;
                                MyTargetGUID = Conversions.ToInteger(num6.ToString());
                                MyTargetNAME = str;
                                Main.TargetObj = GameObjects.curObj;
                            }
                        }
                        num2 = Conversions.ToInteger(func.ReadInt32(GameObjects.curObj + 60));
                        if (num2 == GameObjects.curObj)
                        {
                            break;
                        }
                        GameObjects.curObj = num2;
                    }
                    GameObjects.curObj = curObj;
                }
            }
            catch (Exception exception1)
            {
                ProjectData.SetProjectError(exception1);
                Exception exception = exception1;
                func.logmsg("[ERROR] Unable to read memory");
                ProjectData.ClearProjectError();
            }
            return 0;
        }
    }
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -