Call LUA and poppin that stack menu

User Tag List

Results 1 to 2 of 2
  1. #1
    ggg898's Avatar Member
    Reputation
    10
    Join Date
    Jan 2009
    Posts
    39
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Call LUA and poppin that stack

    First of all Im a total beginner of this, but thanks to all ppl in this forum I have got some nice things up and running in a pretty short time period. Especially big thanks to Cypher, Kynox and Shynd, whos valuable information and findings pointed me in a good direction to start.

    Well on to it, call LUA and get return values have been covered in lots of threads here, but from what Ive seen theres a missconception that the Lua_ToXXX (String, Int, etc) pops the LUA stack, this is not the case. So if you have problems with growing stacks, you want to call

    lua_settop at 0x007ADAF0 for 3.0.9 (havnt seen it in dump lists dunno why)

    use it from c you do like this to empty the stack (pop it all, see LUA docs for more info)

    typedef void (__cdecl * tLuaSetTop)(LPDWORD luaState, int idx);
    tLuaSetTop luaSetTop = (tLuaSetTop)0x007ADAF0;
    luaSetTop(state, 0)

    I know that escpecially Cyper now will point out that there are ways to call LUA without you having to manage youre stack, and there are. Just wanted to share this finding since I havnt seen it covered before, but on the other hand, I cant even search this forum...
    Last edited by ggg898; 02-16-2009 at 04:01 PM.

    Call LUA and poppin that stack
  2. #2
    Sillyboy72's Avatar Member
    Reputation
    13
    Join Date
    Jan 2009
    Posts
    66
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Rock on brother, been looking for that function all day

Similar Threads

  1. Call lua function and get result
    By starfish99 in forum WoW Memory Editing
    Replies: 4
    Last Post: 12-26-2008, 05:15 AM
  2. [Need Host Private Server] Best SPecs Will Get GM And All That
    By sublimepwns in forum World of Warcraft Emulator Servers
    Replies: 30
    Last Post: 02-02-2008, 06:57 PM
  3. Items that work on some servers, and some that don't
    By volvagia in forum World of Warcraft General
    Replies: 1
    Last Post: 10-14-2007, 12:01 PM
  4. hack's and all that....
    By Trustdale in forum World of Warcraft General
    Replies: 1
    Last Post: 09-19-2006, 04:04 AM
All times are GMT -5. The time now is 05:48 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