node.js – How to use Function in discordbot using client.commands.get(“servertest”).run(client, message)

i want that it start my function,
So what happens now it executes the function but it spams the execution unlimited times…
The data from data.ref is a number and when it matches the number it executes the function, but its only now and then..

what can i do to prevent this? a timeout function doesnt work.. it still keeps spamming

for (var i in config.Extra) {
        if (myData.ref == config.Extra(i).ref) {
            var Alert1Type = config.Extra(i).Alert1; // type of the device show
            var Alert1Name = config.Extra(i).name; // Custom name show

            test() //starts the function

function test(){

    client.on('message', message => {
    client.commands.get('servertest').run(client, message); 


windows – Simulate mouse input message for free look in fps games

This question was previously asked in stackoverflow where no one gives an answer. I also found a similiar question here, but in my situation, I hook and simulate mouse inputs and send them to the game window.

Here is the body of the original question:

After hooking windows mouse and keyboard APIs, I wanted to simulate the mouse input message for free look technique (Move the mouse to rotate the player character’s view). Before coding, I used spy++ to monitor a fps game observing which mouse-related message was sent to the window of the game’s program. I got these following lines when I moved the mouse:

P WM_INPUT nInputCode:RIM_INPUT hRawInput:065A04FD
S WM_NCHITTEST xPos:2504 yPos:889
S WM_SETCURSOR hwnd:0016089A nHittest:HCLIENT wMouseMsg:WM_MOUSEMOVE
R WM_SETCURSOR fHaltProcessing:True
P WM_MOUSEMOVE fwKeys:0000 xPos:419 yPos:183

So I wrote these lines of codes (sent WM_INPUT message using codes in How to simulate raw input / Send a WM_INPUT message to an application the right way?, Simulating Raw Input on Windows, and codes in github):

// ...
// mData->px and mData->py indicating the mouse position in client window are double type.
WORD xCor = static_cast<WORD>(mData->px);
WORD yCor = static_cast<WORD>(mData->py);
LPARAM lParamMouseMove = (yCor << 16) | (xCor & 0xFFFFFFFF); // lParam for mouse movement message

// prepare for sending WM_INPUT
LONG _mouse_position.x = static_cast<long>(mData->px);
LONG _mouse_position.y = static_cast<long>(mData->py);
WPARAM wParamRawMouse = RIM_INPUT;
HGLOBAL hRaw = ::GlobalAlloc(GHND, sizeof(RAWINPUT));
RAWINPUT* pRaw = reinterpret_cast<RAWINPUT*>(::GlobalLock(hRaw));

memset((void*)pRaw, 0, sizeof(RAWINPUT));
pRaw->header.dwType = RIM_TYPEMOUSE;
pRaw->header.dwSize = sizeof(RAWINPUT);
pRaw->header.hDevice = GetRawMouseDevice();  // can return the mouse HANDLE correctly
pRaw->header.wParam = wParamRawMouse;

RAWMOUSE rawMouseInfo;
memset((void*)&rawMouseInfo, 0, sizeof(RAWMOUSE));
rawMouseInfo.usFlags = MOUSE_MOVE_RELATIVE;
rawMouseInfo.lLastX = _mouse_position.x - _last_mouse_position.x;  // get the mouse's location change
rawMouseInfo.lLastY = _mouse_position.y - _last_mouse_position.y; = rawMouseInfo;
rawMouseInfo.ulExtraInformation = 0;
rawMouseInfo.ulButtons = 0;
rawMouseInfo.usButtonFlags = 0;
rawMouseInfo.ulRawButtons = 0;
pRaw = &rawMouseInput;


// mainGameWnd is the main window handle
PostMessageA(mainGameWnd, WM_INPUT, wParamRawMouse, (LPARAM)hRaw);
SendMessageA(mainGameWnd, WM_NCHITTEST, 0, MAKELPARAM(_mouse_position.x, _mouse_position.y));
PostMessageA(mainGameWnd, WM_MOUSEMOVE, 0, lParamMouseMove);
// ...

And I used spy++ to monitor my own program:

P WM_INPUT nInputCode:RIM_INPUT hRawInput:0000023822711808
S WM_NCHITTEST xPos:492 yPos:373
S WM_SETCURSOR hwnd:001B0794 nHittest:HCLIENT wMouseMsg:WM_MOUSEMOVE
R WM_SETCURSOR fHaltProcessing:True
P WM_MOUSEMOVE fwKeys:0000 xPos:492 yPos:373

It didn’t work, when I moved the mouse, the character’s view didn’t change and the cursor just moved.
So how to correctly send the four message? Do some magics beyond sending message for free look in games? By the way, this question mentions camera, I think in this hooking situation, the camera is still handled by the game and I just need to send mouse-related message to the game. No need to consider the camera. Am I right?

python – Get the message object of a message you replied to (

How would I get the message object of a message I replied to? E.g. Someone said “Hello, How are you!”. And I replied to that message calling the .good command, it would print the message (Hello, How are you!)’s message object. I’ve looked all over docs but haven’t seen a thing mentioning something like this.

rest – Which message pattern should I use for synchronous communincation in Nodejs Microservices?

My Nodejs microservices currently running on Kubernetes are communicating over REST. Does the request-reply model of NATS, which replier needs to return (large data ~ 500kb currently single endpoint response), cause performance increase? Some benchmarks say it’s 10 times faster (1), but I got a bad result on a little test I did at my local (but the conditions weren’t equal, I’ll repeat the test on more equal terms). On the other hand, I have read that RabbitMQ does not have a good performance on request-reply. I want to discuss here, how can I decide which communication model is advantageous / performance in situations that require synchronous communication?

In addition, when REST is used, resources can be documented with Swagger. What needs to be done when using NATS?


customization – Change Successful password reset message

After password is reset in WordPress, the message comes as “Your password has been reset. Login”
How do I customise this message?

        do_action( 'validate_password_reset', $errors, $user );

        if ( ( ! $errors->has_errors() ) && isset( $_POST('pass1') ) && ! empty( $_POST('pass1') ) ) {
            reset_password( $user, $_POST('pass1') );
            setcookie( $rp_cookie, ' ', time() - YEAR_IN_SECONDS, $rp_path, COOKIE_DOMAIN, is_ssl(), true );
            login_header( __( 'Password Reset' ), '<p class="message reset-pass">' . __( 'Your password has been reset.' ) . ' <a href="' . esc_url( wp_login_url() ) . '">' . __( 'Log in' ) . '</a></p>' );

This is the code I am looking at in wp-login.php. I just want to change the message alone. Any help is appreciated.

Board Message

Sorry, an error occurred. If you are unsure on how to use a feature, or don’t know why you got this error message, try looking through the help files for more information.

The error returned was:

You must register a free account with us and stay logged in to see this forum.

Post, Read around and Network with the Like-Minded Money Makers.

Expand your Network and Start Making Some New Friends!

DTM Network – A Social Money Making Network where People from all over the World Meet, Share Ideas and Grow as a TEAM!

Register an account here now to view the full forum and enjoy all the benefit for free.

Use the form below to log in if you already have an account.

What does this annoying message mean in Google search engine? [closed]

Every time you search in Google search engine, you come across this annoying and meaningless message.

What does this message mean?

mac – Message app is extremely slow to open Big Sur

mac – Message app is extremely slow to open Big Sur – Ask Different

I want to clear data on whatsapp to recover my messages but i lost the number would whatsapp send a message to the umber?

Your privacy

By clicking “Accept all cookies”, you agree Stack Exchange can store cookies on your device and disclose information in accordance with our Cookie Policy.

Sucess and Error Message is not shown on Contact Form

I am using Magento version 2.4, When i submit the contact Form it not shown Error or success message.Mail For contact form is working properly.

Please Let me know the solution.

Thanks in Advance.

DreamProxies - Cheapest USA Elite Private Proxies 100 Private Proxies 200 Private Proxies 400 Private Proxies 1000 Private Proxies 2000 Private Proxies - Buy Cheap Private Proxies Buy 50 Private Proxies Buy 100 Private Proxies Buy 200 Private Proxies Buy 500 Private Proxies Buy 1000 Private Proxies Buy 2000 Private Proxies ProxiesLive New Proxy Lists Every Day Proxies123