[Help] Vanilla Looting/Interacting with NPCs menu

User Tag List

Results 1 to 9 of 9
  1. #1
    drassian's Avatar Member
    Reputation
    1
    Join Date
    May 2012
    Posts
    15
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    [Help] Vanilla Looting/Interacting with NPCs

    Hi guys, I'm trying to make a bot for 1.12.1 in C# ive got click to move working by writing to the x/y/z and flag(Not sure what to call this but i set it to '4' when just moving normally). Looking for some guidance on how to get looting/attacking/interacting to work. When I manually ctm on a mob the flag shows up as 10 but I couldn't find the mob ID anywhere in the memory.

    Is it possible in vanilla to use CTM to loot, vendor and attack mobs ect? I had a search though the forums and saw alot of people 'hook' or execute wow commands but I don't really know where to start with that.

    Just wondering if anyone could give me some direction on where to go next?



    Vanilla WoW 1.12.1 Click to Move Bot Test - YouTube is a vid of me checking the accuracy of the CTM

    For some reason it breaks unless you manually click to move when you first login. After that though you can even disable the option and it will keep running.
    Code:
     
            uint ctmX = 0xC4D894;
            uint ctmY = 0xC4D890;
            uint ctmZ = 0xC4D898;
            uint ctmFlag = 0xC4D888;
    
            BlackMagic myMagic = new BlackMagic();
    
            public void ClickToMove(float X, float Y, float Z, int Flag, IntPtr hWnd)
            {
                myMagic.Open(hWnd);
                myMagic.WriteFloat(ctmX, X);
                myMagic.WriteFloat(ctmY, Y);
                myMagic.WriteFloat(ctmZ, Z);
                myMagic.WriteInt(ctmFlag, Flag);
                myMagic.Close();
            }
    Last edited by drassian; 04-29-2013 at 10:20 PM.

    [Help] Vanilla Looting/Interacting with NPCs
  2. #2
    CreativeXtent's Avatar Moderator Authenticator enabled
    Reputation
    580
    Join Date
    Jun 2011
    Posts
    1,594
    Thanks G/R
    242/148
    Trade Feedback
    3 (100%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    care to share code?
    "the true wow experience is Maclone"

  3. #3
    drassian's Avatar Member
    Reputation
    1
    Join Date
    May 2012
    Posts
    15
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Ok so I found some code written by "yellow82"

    Code:
            private void RightClickObject( BlackMagic wow , uint _curObject)
            {
                uint codecave = wow.AllocateMemory();
                wow.Asm.Clear();
                wow.Asm.AddLine("mov ecx, {0}", _curObject);
                wow.Asm.AddLine("call {0}", (uint)wow.MainModule.BaseAddress + ADDRESSES.objectRightClick);
                wow.Asm.AddLine("retn");
                wow.Asm.InjectAndExecute(codecave);
            }
    So i figure all i need to make this work is the "ADDRESSES.objectRightClick" to be updated for 1.12.1? Or would this not work for vanilla wow?

  4. #4
    Corthezz's Avatar Elite User Authenticator enabled
    Reputation
    386
    Join Date
    Nov 2011
    Posts
    325
    Thanks G/R
    183/98
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Iterate through the object manager until you find the object you want to interact with.
    Read the objects guid and write it into CTM Guid address and write the right CTM action.
    Beside the object manager it takes ~5 minutes to get all needed addresses by scanning with Cheat Engine.

  5. #5
    drassian's Avatar Member
    Reputation
    1
    Join Date
    May 2012
    Posts
    15
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks for the help, atm I can open vendors ect (only I start further away than 2~ yards for some reason) using the code below but when It comes to 'attacking' I cant seem to do it yet, my guy just runs over ontop of the mob atm. But i'll keep trying, ty for helping

    Code:
            uint factionId = 0xC4D980;
            uint targetId = 0xC4D984;
     
            public void InteractWith(long faction, long target, int flag, IntPtr hWnd)
            {
                myMagic.Open(hWnd);
                myMagic.WriteInt64(factionId, faction);
                myMagic.WriteInt64(targetId, target);
                myMagic.WriteInt(ctmFlag, flag);
                myMagic.Close();
            }

    Edit: ok so looting also works with that funciton - I can live without attack-CTM and just use macros to make sure auto-attack is on. But my next challenge is dealing 'picking up' items once loot window is open and 'selling' items to the vendor without mouse input.

    Edit2: I found an addon for vanilla called "autoprofit" and modified it to sell all greys without any user input. I'm looking for one for looting atm but it doesn't look as though it was possible to do though addons in vanilla
    Last edited by drassian; 04-30-2013 at 08:10 PM.

  6. #6
    Corthezz's Avatar Elite User Authenticator enabled
    Reputation
    386
    Join Date
    Nov 2011
    Posts
    325
    Thanks G/R
    183/98
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    There is a minimal range for CTM to work which you can change by writing to one address. Just search for float values near the CTM addresses you already got and lower the value to 0 and you can interact from any distance with your desired object.

    For looting you need to find a way to toggle shift loot with memory write or patch LootSlot(x) lua function. Dont bother trying to send shift while CTM looting, I had the same problem you had and it just dont work

    Edit: You got skype? It seems that we are working on the same stuff

  7. #7
    drassian's Avatar Member
    Reputation
    1
    Join Date
    May 2012
    Posts
    15
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    yeah tried shift looting too, ill take a look for the ctm distance/toggle autoloot now thanks for all the help!

  8. #8
    Shock18's Avatar Member
    Reputation
    1
    Join Date
    Nov 2010
    Posts
    35
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by drassian View Post
    Hi guys, I'm trying to make a bot for 1.12.1 in C# ive got click to move working by writing to the x/y/z and flag(Not sure what to call this but i set it to '4' when just moving normally). Looking for some guidance on how to get looting/attacking/interacting to work. When I manually ctm on a mob the flag shows up as 10 but I couldn't find the mob ID anywhere in the memory.

    Is it possible in vanilla to use CTM to loot, vendor and attack mobs ect? I had a search though the forums and saw alot of people 'hook' or execute wow commands but I don't really know where to start with that.

    Just wondering if anyone could give me some direction on where to go next?



    Vanilla WoW 1.12.1 Click to Move Bot Test - YouTube is a vid of me checking the accuracy of the CTM

    For some reason it breaks unless you manually click to move when you first login. After that though you can even disable the option and it will keep running.
    Code:
     
            uint ctmX = 0xC4D894;
            uint ctmY = 0xC4D890;
            uint ctmZ = 0xC4D898;
            uint ctmFlag = 0xC4D888;
    
            BlackMagic myMagic = new BlackMagic();
    
            public void ClickToMove(float X, float Y, float Z, int Flag, IntPtr hWnd)
            {
                myMagic.Open(hWnd);
                myMagic.WriteFloat(ctmX, X);
                myMagic.WriteFloat(ctmY, Y);
                myMagic.WriteFloat(ctmZ, Z);
                myMagic.WriteInt(ctmFlag, Flag);
                myMagic.Close();
            }
    Will this bot be released to the public? If so im not a coder or anything but i would love to donate to help with your work.. I have been waiting for a long time to get a working bot for 1.12.1

  9. #9
    namreeb's Avatar Legendary

    Reputation
    658
    Join Date
    Sep 2008
    Posts
    1,023
    Thanks G/R
    7/215
    Trade Feedback
    0 (0%)
    Mentioned
    8 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by Corthezz View Post
    There is a minimal range for CTM to work which you can change by writing to one address. Just search for float values near the CTM addresses you already got and lower the value to 0 and you can interact from any distance with your desired object.

    For looting you need to find a way to toggle shift loot with memory write or patch LootSlot(x) lua function. Dont bother trying to send shift while CTM looting, I had the same problem you had and it just dont work

    Edit: You got skype? It seems that we are working on the same stuff
    Note that servers will often enforce a maximum interact distance, as well.

Similar Threads

  1. Interact with NPC via C++
    By SoIAS in forum WoW Bots Questions & Requests
    Replies: 0
    Last Post: 10-26-2013, 03:09 PM
  2. [Autoit][3.1.3] Problem with interact with npcs
    By grigitokarz in forum WoW Memory Editing
    Replies: 1
    Last Post: 08-19-2009, 03:40 PM
  3. Help with NPC Code
    By Fuynuns93 in forum World of Warcraft Emulator Servers
    Replies: 7
    Last Post: 07-03-2008, 11:34 AM
  4. [Help][Ascent] Something wrong with my NPC's
    By jklei18 in forum World of Warcraft Emulator Servers
    Replies: 2
    Last Post: 04-15-2008, 05:43 AM
  5. Help with NPC Teleporters
    By KnownReason in forum World of Warcraft Emulator Servers
    Replies: 3
    Last Post: 09-11-2007, 05:22 PM
All times are GMT -5. The time now is 10:45 AM. Powered by vBulletin® Version 4.2.3
Copyright © 2024 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search