Function calling. What did I do wrong? menu

User Tag List

Results 1 to 3 of 3
  1. #1
    cortexio's Avatar Member
    Reputation
    1
    Join Date
    Mar 2013
    Posts
    12
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Function calling. What did I do wrong?

    So i was able to inject my dll. But when calling the ingame Cast spell function my game crashes.
    I'm pretty sure the address is right. I used m_controlledChar -> 0x1a0 (skillbar) -> 0x0 (vtable) -> 0x58 (castSpellBySlot)
    = 0x00B908F0

    Code:
    if(msg == "Cast4"){
    typedef int ( __stdcall *Spellcast)(DWORD , DWORD);
    Spellcast castmyspell = (Spellcast)0x00B908F0;
    castmyspell(6, 0);
    }
    IDA:
    Function calling. What did I do wrong?-c8bbf058c0-png

    CE: +registers at function call breakpoint
    Function calling. What did I do wrong?-775e021a13-jpg
    Attached Thumbnails Attached Thumbnails Function calling. What did I do wrong?-e7d2ad2943-png  
    Last edited by cortexio; 05-11-2013 at 03:21 PM.

    Function calling. What did I do wrong?
  2. #2
    JuJuBoSc's Avatar Banned for scamming CoreCoins Purchaser
    Reputation
    1019
    Join Date
    May 2007
    Posts
    922
    Thanks G/R
    1/3
    Trade Feedback
    1 (100%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    its thiscall, you must pass ChCliSkillBar as this.

  3. #3
    KingOfCats's Avatar Private
    Reputation
    1
    Join Date
    Sep 2012
    Posts
    5
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    This isn't the same function but I think my problem may be similiar to yours. I am trying to call the settarget function and I am nearly certain my issue is TLS related I am just unsure how to fix it.
    Code:
    __asm {PUSHAD}
    __asm {PUSHFD}
    void * AsContext;
    *(DWORD*)AsContext = 0x01733970;
    typedef void (__thiscall *SetTarget)(void*,DWORD);
    void *vtable=(void*)(*(void **)AsContext);
    void *addr=((void**)vtable)[0x58]; 
    ((SetTarget)addr)(AsContext, 0);
    __asm {POPAD}
    __asm {POPFD}
    I get a crash when i try to call like this and the function I am hooking to do the call from is located by this pattern:
    Code:
    byte GameHookPattern[] = { 0xD9, 0x5F, 0x78, 0xD9, 0x46, 0x04 };
    I can call the sendpacket function fine from this hook but no success with the set target or castspell functions. I would be quite happy if someone could help me out with my TLS issues.

Similar Threads

  1. [Question] What did I do wrong?
    By Karamin in forum WoW ME Questions and Requests
    Replies: 0
    Last Post: 12-18-2010, 07:45 PM
  2. 3h ban, what did I do wrong?
    By nuffed in forum WoW Scams Help
    Replies: 15
    Last Post: 04-20-2009, 01:42 PM
  3. What did i do wrong?
    By dunno100 in forum WoW Scams Help
    Replies: 11
    Last Post: 10-31-2008, 03:37 PM
  4. [Furbolg To Arokka] What did i do wrong? :(
    By mantorkel in forum WoW ME Questions and Requests
    Replies: 0
    Last Post: 05-20-2008, 07:48 AM
  5. [Question] What did i do wrong here?
    By ti0r in forum WoW ME Questions and Requests
    Replies: 6
    Last Post: 04-25-2008, 08:38 AM
All times are GMT -5. The time now is 04:52 PM. 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