# Forum > World of Warcraft > World of Warcraft Bots and Programs > WoW Memory Editing >  Communicating between wow client <> external

## SinnerG

Does anyone know of a clean method of exposing info (by setting it lua-wise) to an external application?

The work-around I use for now is I do a FontString and set the text to something like UNIQUENAME:<data goes here>

I then search the memory for UNIQUENAME and read it in as an ASCII string (\0 terminated)

It works, but atm it takes (on my PC, setting the starting offset @ 0x0F000000) around 300-400ms 'per call'

This should do for now. I'm trying to expose as much information as possible, without injecting anything! So only 'non injecting' solutions guys :P

----------


## Cypher

I know I know, I'm not answering your question, but.. why do you need to do this with Lua? It would be about 100x easier to just use a named pipe or something.

----------


## SinnerG

Care to explain Cypher? Keep in mind, I want to stay out-of-process  :Smile:

----------


## flo8464

You are executing lua code but you want to stay out-of-process?

----------


## Cypher

> Care to explain Cypher? Keep in mind, I want to stay out-of-process


http://www.mmowned.com/forums/wow-me...cess-bots.html

----------


## SinnerG

Yes, I read that. I see no way that Warden can detect it as long as I keep it private (or people modify the required addon so they cant simply ban the addon ^^)

The only thing I do in the wow client is setting a text field to a certain text :P (and reading it back from memory using a 'memory search', much like cheat engine does it)

I don't hook anything.

----------


## MaiN

He's probably using a LUA add-on or something like that.

----------


## Cypher

> Yes, I read that. I see no way that Warden can detect it as long as I keep it private (or people modify the required addon so they cant simply ban the addon ^^)
> 
> The only thing I do in the wow client is setting a text field to a certain text :P (and reading it back from memory using a 'memory search', much like cheat engine does it)
> 
> I don't hook anything.


Yeah... I'm too tired for this right now. Someone else wanna take over?




> He's probably using a LUA add-on or something like that.


His latest post does indeed imply that, however it doesn't really change my point.

If your hack is private it's no more detectable to just inject a DLL and do what I said (use a named pipe, memory mapped file, etc). Not to mention it would be over nine thousand times faster.

----------


## SinnerG

Well, it is more for learning purposes so maybe I'll switch to the 'alternative' method at some point, but for now I'm happy as is  :Smile: 

And yeah, its a seperate wow addon, doing regular things :P

----------


## Cypher

> Well, it is more for learning purposes so maybe I'll switch to the 'alternative' method at some point, but for now I'm happy as is 
> 
> And yeah, its a seperate wow addon, doing regular things :P


If you're happy with it how it is, then why are you asking if anyone has an alternative method you can replace it with?

----------


## SinnerG

Well, I was asking if anyone know a better way to SET data @ wow and retrieve it by reading its memory (a static or more static address?) since currently it takes 500ms to retrieve the data (since it needs to scan for the 'keyword') - thats why I was asking  :Smile:

----------


## Cypher

Zzzzzz .

----------


## adaephon

LUA Addon write to file, your external whatever read from file?

----------


## Cypher

> LUA Addon write to file, your external whatever read from file?


Afaik Lua addons can't write to files.

----------


## flo8464

> Afaik Lua addons can't write to files.


Sure they can, or at least they can store data. 
Think of Auctioneer databases etc

----------


## Cypher

> Sure they can, or at least they can store data. 
> Think of Auctioneer databases etc


The data storage methods WoW expose are useless for exposing data to an external application, because I'm pretty sure the data on disk is only updated when the user reloads the UI, logs out, etc. You can't just read and write 'on the fly'.

If this is incorrect I withdraw my objection, but I'm pretty sure I'm correct.

----------


## SinnerG

> The data storage methods WoW expose are useless for exposing data to an external application, because I'm pretty sure the data on disk is only updated when the user reloads the UI, logs out, etc. You can't just read and write 'on the fly'.
> 
> If this is incorrect I withdraw my objection, but I'm pretty sure I'm correct.


You are correct. If you want to force a save, you have to indeed reload the ui (/console reloadui) to 'flush' it to the hd.

----------


## FenixTX2

I'm using an LUA gui to control my application. 

First I create a CVar at a specified location in memory, 
then use my LUA addon to write to that CVar. i.e. set_FreeCam = 1;

My main app cycles through all of the memory locations I feed it looking for updates, executes the necessary function and resets the CVar to a base value.

----------


## adaephon

> The data storage methods WoW expose are useless for exposing data to an external application, because I'm pretty sure the data on disk is only updated when the user reloads the UI, logs out, etc. You can't just read and write 'on the fly'.
> 
> If this is incorrect I withdraw my objection, but I'm pretty sure I'm correct.


Fair enough, I've never actually looked into LUA. I just assumed based off evidence of Auctioneer etc. 'Research' into file writing in LUA addons didn't extend beyond ... well it didn't start, so I stand rightly corrected.

----------

