DoString("CastSpellByName()") Crashes Randomly. menu

User Tag List

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

    DoString("CastSpellByName()") Crashes Randomly.

    Hey guys I got the DoString ( what I think is dostring ) function working for casting spell, but I keep running into a problem with it crashing.

    The situation is I got a rogue that I set up a simple loop( to call "Hemorrhage" every 2 seconds, it does this perfectly a couple times and then issues a "Error Reading 0xADDRESS" then crashes.

    Code:
    Instruction at "0x00A9..." refrenced memory at "0x0000000024".
    I can't figure out what the conditions are that cause this crash. Sometimes it will only call the spell once before it crashes, other times I can go 2-3 minutes of mob killing before it crashes.

    I check to make sure, I have a target, and its attackable, and the target is attacking me before making these calls but it still just crashes RANDOMLY....

    This is the code for everything

    PHP Code:
    if( targetObj->GetTargetGUID() == player->GetGUID() && player->IsStealth() == false ) {
        if( 
    this->timerPtr_->IsRunning(1337) == false ) {
            
    LOG_INF"Casting: Hemorrphage" << std::endl );
            
    player->GetSpellBook()->CastSpellByName"Hemorrhage");
        }


    PHP Code:
    LUA_DO_STRING 0x4FD26 
    PHP Code:
    typedef void (__cdecl *pDoString) ( const char *spellName_1, const char *spellName_2int un_1 );
    pDoString oDoString reinterpret_castpDoString >( doStringAddr->GetFullAddress() );
    oDoStringstr.c_str(), str.c_str(), ); 
    Last edited by cenron; 05-25-2014 at 08:38 PM.

    DoString(&quot;CastSpellByName()&quot;) Crashes Randomly.
  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)
    Are you calling it from main thread ?

  3. #3
    cenron's Avatar Member
    Reputation
    12
    Join Date
    Mar 2008
    Posts
    93
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by JuJuBoSc View Post
    Are you calling it from main thread ?
    No, I am calling it from a thread I created.....do you have to? I use to work with WoW....back when they use to store the object manager in the TlsIndex, so you either patched your TlsIndex, Hook EndScene, or Hook the MainThread to make any calls.....

    I thought that i read somewhere that they dont store the object manager in the TlsIndex. So I figured you didn't have to be selective about the threads you run your code in....

    I guess the other question is, why does it work sometimes for 5 min continuously and then crash and then other times only work for 5 seconds.

    I am always nervous about hooking any D3D functions, or threads cause of warden.....is there a patch I can do to my thread so that I can call stuff from it?
    Last edited by cenron; 05-26-2014 at 12:11 AM.

  4. #4
    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)
    It's not thread sade, so you have to call it from main thread, just hook any d3d function of your choice, if your project is private, you don't need to care about the warden at all.

  5. #5
    cenron's Avatar Member
    Reputation
    12
    Join Date
    Mar 2008
    Posts
    93
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by JuJuBoSc View Post
    It's not thread sade, so you have to call it from main thread, just hook any d3d function of your choice, if your project is private, you don't need to care about the warden at all.
    Oooooohhhh that makes a lot of sense now....I was wondering why it was so random.

Similar Threads

  1. Quotes from Steven Write
    By Amedis in forum Community Chat
    Replies: 2
    Last Post: 11-14-2022, 10:26 AM
  2. WoW crashes randomly
    By Jinrohk in forum WoW ME Questions and Requests
    Replies: 2
    Last Post: 04-06-2008, 03:35 PM
  3. WTB Powerleveling - Need Quotes!!
    By Drovos in forum Members Only Gold And Powerleveling Buy Sell
    Replies: 7
    Last Post: 10-14-2007, 10:26 AM
  4. Funny GM quotes
    By shadowfox47 in forum World of Warcraft General
    Replies: 9
    Last Post: 08-13-2007, 07:24 PM
  5. Random Teleporting With Crashing
    By Premium-mmo in forum World of Warcraft Exploits
    Replies: 22
    Last Post: 05-08-2007, 07:56 AM
All times are GMT -5. The time now is 01:35 PM. 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