October 24, 20241 yr This is my code, when I traverse through the object, I do "ObjectManager.Me.Target = target. Guid; "Select the target, but the bot will attack the target, and enter the battle, I just want to select the target and not attack, how do I need to change the code. string[] objectNames = new string[] { "血色信徒"}; while (true) { WoWUnit target = ObjectManager.GetObjectWoWUnit() .Where(o => objectNames.Contains(o.Name) && o.IsAlive) .OrderBy(o => o.GetDistance) .FirstOrDefault(); if (target != null) { ObjectManager.Me.Target = target.Guid; SpellManager.CastSpellByNameLUA("偷窃"); Thread.Sleep(100); } Thread.Sleep(1000); }
Create an account or sign in to comment