Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using vendor mounts #27

Open
BanditTech opened this issue Dec 31, 2020 · 1 comment
Open

Using vendor mounts #27

BanditTech opened this issue Dec 31, 2020 · 1 comment

Comments

@BanditTech
Copy link

We can send a string to the window by calling this function:

public int sendWindowsStringMessage(int hWnd, int wParam, string msg)
{
    int result = 0;
    
    if (hWnd > 0)
    {
        byte[] sarr = System.Text.Encoding.Default.GetBytes(msg);
        int len = sarr.Length;
        COPYDATASTRUCT cds;
        cds.dwData = (IntPtr)100;
        cds.lpData = msg;
        cds.cbData = len + 1;
        result = SendMessage(hWnd, WM_COPYDATA, wParam, ref cds);
    }
    
    return result;
}

And passing lines such as "/use Grand Expedition Yak" and "/target Cousin Slowhands" to then press the interact with target button... and pause for addons to do their magic.

Interesting?

@julianperrott
Copy link
Owner

Hi, I tried to get this working on classic, but have failed :(

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants