Question:In combat/Out of combat flag menu

User Tag List

Results 1 to 15 of 15
  1. #1
    violentmagician's Avatar Member
    Reputation
    1
    Join Date
    Dec 2008
    Posts
    8
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Question:In combat/Out of combat flag

    Hi ppl i want to know if it is possible...
    is there a flag in wow local memory that signifies to the client that the toon is in combat...if it is , is it possible to toggle this flag off to instantly go out of combat?

    Applications:
    stuck in combat bug -> major reason for asking
    PVP -> maybe...

    Thoughts....:confused:

    Question:In combat/Out of combat flag
  2. #2
    Intu's Avatar Banned
    Reputation
    95
    Join Date
    Feb 2009
    Posts
    303
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Just afk out.

    If you know how manipulate your ram, then you can.

  3. #3
    ramey's Avatar Member
    Reputation
    45
    Join Date
    Jan 2008
    Posts
    320
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by Intu View Post
    Just afk out.

    If you know how manipulate your ram, then you can.
    LOL??

    Start by reversing lua function UnitAffectingCombat and you will probably be in the right direction.

  4. #4
    violentmagician's Avatar Member
    Reputation
    1
    Join Date
    Dec 2008
    Posts
    8
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    k will try that...
    the main question remains would this actually work or the flag will be reset on server sync?

  5. #5
    ramey's Avatar Member
    Reputation
    45
    Join Date
    Jan 2008
    Posts
    320
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Holy shit, I didn't read your thread fully. I thought you were just asking to get a flag for InCombat.

    Um, no, it is not possible.
    Last edited by ramey; 08-19-2009 at 01:19 PM.

  6. #6
    Nesox's Avatar ★ Elder ★
    Reputation
    1280
    Join Date
    Mar 2007
    Posts
    1,238
    Thanks G/R
    0/3
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Code:
            private long Flags
            {
                get
                {
                    return GetKnownField<uint>((uint)WoWUnitFields.UNIT_FIELD_FLAGS, BaseAdress);
                }
            }
    
            /// <summary>
            /// Returns true if the unit is in combat
            /// </summary>
            public bool Combat
            {
                get
                {
                    return Convert.ToBoolean(Flags & 0x0080000);
                }
            }
    Here you go.. Nom nom

  7. #7
    testout's Avatar Member
    Reputation
    7
    Join Date
    May 2008
    Posts
    44
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    BaseAdress -> BaseAddress

    Dude, haven't you paid nothinglol yet?

    Check signature at:

    http://www.mmowned.com/forums/wow-me...ml#post1538491

    I lol'd.

  8. #8
    namreeb's Avatar Legendary

    Reputation
    668
    Join Date
    Sep 2008
    Posts
    1,029
    Thanks G/R
    8/222
    Trade Feedback
    0 (0%)
    Mentioned
    9 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by violentmagician View Post
    k will try that...
    the main question remains would this actually work or the flag will be reset on server sync?
    My guess is that you might fool the UI, until you try and do something that requires you not be in combat, at which point the server would re-affirm your state.

  9. #9
    donth8me's Avatar Member
    Reputation
    3
    Join Date
    Apr 2009
    Posts
    9
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I've been cutting and pasting my arse off, but can't seem to get a "true" return on testing for combat. This is what I have going...

    Code:
    public static BlackMagic Memory = new BlackMagic();
            Descriptors descriptor = new Descriptors(Memory);
    
            public Descriptors getDescriptors
            {
                get
                {
                    return descriptor;
                }
            }
    
    	public bool Combat
            {
                get
                {
                    return Convert.ToBoolean(Flags & 0x0080000);  //tried return (Flags & 0x80000) == 0x80000) 
                }
            }  
     
    
            public long Flags
            {
                get
                {
                    try
                    {
                        Process[] process = Process.GetProcessesByName("Wow");
                        return getDescriptors.GetKnownField<uint>(Descriptors.WoWUnitFields.UNIT_FIELD_FLAGS, GetBaseAddress(process[0].Id, "wow.exe"));
                    }
                    catch
                    {
                        return 0;
                    }
                }
            }
          
    
            public uint GetBaseAddress(int processID, string moduleName)
            {
                Process process = Process.GetProcessById(processID); 
                ProcessModuleCollection Modules = process.Modules; 
                ProcessModule pModule;
                uint baseAddress = 0;
    
                for (int i = 0; i < Modules.Count; i++)
                {
                    pModule = Modules[i];
                    if (pModule.ModuleName.Equals(moduleName))
                    {
                        baseAddress = (uint)pModule.BaseAddress;
                        break;
                    }
                }
                return baseAddress;
            }
            
    
    
        public class Descriptors
        {
            public enum WoWUnitFields : uint
            {
                UNIT_FIELD_FLAGS = 0x34  //tried 0x35 which is UNIT_FIELD_FLAGS2
            };
            private BlackMagic wow { get; set; }
    
            public Descriptors(BlackMagic _BlackMagic)
            {
                this.wow = _BlackMagic;
            }
            public T GetKnownField<T>(WoWUnitFields field, uint obj) where T : struct
            {
                return (T)wow.ReadObject(wow.ReadUInt(obj + 0x08) + (uint)field * 4, typeof(T));
            }
        }
    its always false if I'm in combat or not.

  10. #10
    Apoc's Avatar Angry Penguin
    Reputation
    1388
    Join Date
    Jan 2008
    Posts
    2,750
    Thanks G/R
    0/13
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by donth8me View Post
    I've been cutting and pasting my arse off, but can't seem to get a "true" return on testing for combat. This is what I have going...

    Code:
    public static BlackMagic Memory = new BlackMagic();
            Descriptors descriptor = new Descriptors(Memory);
    
            public Descriptors getDescriptors
            {
                get
                {
                    return descriptor;
                }
            }
    
        public bool Combat
            {
                get
                {
                    return Convert.ToBoolean(Flags & 0x0080000);  //tried return (Flags & 0x80000) == 0x80000) 
                }
            }  
     
    
            public long Flags
            {
                get
                {
                    try
                    {
                        Process[] process = Process.GetProcessesByName("Wow");
                        return getDescriptors.GetKnownField<uint>(Descriptors.WoWUnitFields.UNIT_FIELD_FLAGS, GetBaseAddress(process[0].Id, "wow.exe"));
                    }
                    catch
                    {
                        return 0;
                    }
                }
            }
          
    
            public uint GetBaseAddress(int processID, string moduleName)
            {
                Process process = Process.GetProcessById(processID); 
                ProcessModuleCollection Modules = process.Modules; 
                ProcessModule pModule;
                uint baseAddress = 0;
    
                for (int i = 0; i < Modules.Count; i++)
                {
                    pModule = Modules[i];
                    if (pModule.ModuleName.Equals(moduleName))
                    {
                        baseAddress = (uint)pModule.BaseAddress;
                        break;
                    }
                }
                return baseAddress;
            }
            
    
    
        public class Descriptors
        {
            public enum WoWUnitFields : uint
            {
                UNIT_FIELD_FLAGS = 0x34  //tried 0x35 which is UNIT_FIELD_FLAGS2
            };
            private BlackMagic wow { get; set; }
    
            public Descriptors(BlackMagic _BlackMagic)
            {
                this.wow = _BlackMagic;
            }
            public T GetKnownField<T>(WoWUnitFields field, uint obj) where T : struct
            {
                return (T)wow.ReadObject(wow.ReadUInt(obj + 0x08) + (uint)field * 4, typeof(T));
            }
        }
    its always false if I'm in combat or not.
    Seriously... do some research. You're not even using the correct descriptors.

    UNIT_FIELD_FLAGS = 0x3A,
    UNIT_FIELD_FLAGS_2 = 0x3B,

  11. #11
    Viano's Avatar Active Member
    Reputation
    37
    Join Date
    May 2008
    Posts
    172
    Thanks G/R
    0/1
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by donth8me View Post
    Code:
    ...          
    Process[] process = Process.GetProcessesByName("Wow");
    return getDescriptors.GetKnownField<uint>(Descriptors.WoWUnitFields.UNIT_FIELD_FLAGS, GetBaseAddress(process[0].Id, "wow.exe"));
    ...
    Dude, I copy&paste a lot. But this ... lol. Calling GetProcessByName() each time you need the descriptor?
    Viano

  12. #12
    donth8me's Avatar Member
    Reputation
    3
    Join Date
    Apr 2009
    Posts
    9
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by Viano View Post
    Dude, I copy&paste a lot. But this ... lol. Calling GetProcessByName() each time you need the descriptor?
    LOL, sometimes in a mans life, he just needs a quick fix to get his motor running.

    Apoc, thanks for the right info. I though I got it from the 3.2 offsets list but I guess I didn't.

    Still doesn't work though. In Flags it fails at try and returns what is in the catch.
    Last edited by donth8me; 08-19-2009 at 09:42 PM.

  13. #13
    ramey's Avatar Member
    Reputation
    45
    Join Date
    Jan 2008
    Posts
    320
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by donth8me View Post
    LOL, sometimes in a mans life, he just needs a quick fix to get his motor running.

    Apoc, thanks for the right info. I though I got it from the 3.2 offsets list but I guess I didn't.

    Still doesn't work though. In Flags it fails at try and returns what is in the catch.
    Try this, it's what I do in-process.

    Code:
    bool CGUnit_C::InCombat()
    {
    	return ( GetObjectField<unsigned long>( UNIT_FIELD_FLAGS ) & UNIT_FLAG_IN_COMBAT ) != 0;
    }
    OBJECT_END = 0x18
    UNIT_FIELD_FLAGS = OBJECT_END + 0xD0

    UNIT_FLAG_IN_COMBAT = 0x00080000

    Don't even know if it works currently but it should.

  14. #14
    evil2's Avatar Active Member
    Reputation
    27
    Join Date
    Feb 2009
    Posts
    172
    Thanks G/R
    31/9
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    from InCombatLockdown 004B2300 (3.2.0)

    [10a1b68]+0124c -> 0=incombat


    edit:
    same for 3.2.0a
    Last edited by evil2; 08-20-2009 at 12:15 AM.

  15. #15
    donth8me's Avatar Member
    Reputation
    3
    Join Date
    Apr 2009
    Posts
    9
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I'm drunk, it's my birthday, I just highlighted and backspaced code in my project and deleted any and all class' that had anything to do with reading Unit_Field_Flags.. I come from a background of hardcore win apps that do basic database reading/writing and make 70k a year doing it. This is all new to me and looks Chinese. I figured after a few days of copy/paste, google and a bit of now how I'd be able to figure out what was going on but who am I kidding? I don't even want to make a bot and never set out to make a bot, I just want to return true when I'm in combat.

    Reading the WoW chat log was a cake walk. I even figured out how to return the offsets from a new update. I'm not over it but I need to sit back, learn more on reading different hex paths and start from scratch, I guess.
    Last edited by donth8me; 08-20-2009 at 02:08 AM.

Similar Threads

  1. Model Edit Question - Model turn out GREEN in game?
    By jho369 in forum WoW ME Questions and Requests
    Replies: 5
    Last Post: 04-20-2010, 10:21 PM
  2. Replies: 9
    Last Post: 04-27-2009, 10:55 AM
  3. [QUESTION] Screen blacking out after model change
    By Jo_Vo in forum WoW ME Questions and Requests
    Replies: 3
    Last Post: 02-16-2009, 04:53 AM
  4. QUESTION: changing combat stances
    By rites in forum WoW ME Questions and Requests
    Replies: 0
    Last Post: 03-14-2008, 10:10 AM
  5. Get out of WSG flag room before match starts *Horde Only*
    By Feronn in forum World of Warcraft Exploits
    Replies: 4
    Last Post: 01-02-2007, 12:00 AM
All times are GMT -5. The time now is 05:41 AM. Powered by vBulletin® Version 4.2.3
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Google Authenticator verification provided by Two-Factor Authentication (Free) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search