Two programs to receive keyboard input simultaneously?

Click For Summary

Discussion Overview

The discussion revolves around the challenge of controlling two or more programs simultaneously, specifically in the context of running multiple full-screen games on a single PC. Participants explore potential solutions and tools that might allow for simultaneous keyboard input or control.

Discussion Character

  • Exploratory
  • Technical explanation
  • Debate/contested

Main Points Raised

  • One participant suggests that it is not possible to give focus to two programs at the same time but mentions that keystrokes can be sent to a background program, allowing for a practical form of simultaneous control.
  • Another participant proposes using C programming techniques to open a second program as a file descriptor, allowing for keyboard input to be sent through socket communication, although this may not be suitable for real-time input.
  • A different participant mentions using Cheat Engine to freeze or pause multiple games simultaneously but notes that it does not allow for character movement, seeking further solutions for simultaneous control.
  • ISBoxer is recommended as a dedicated solution for controlling multiple games at once, with features that allow for managing multiple game UIs on a single screen.

Areas of Agreement / Disagreement

Participants express varying opinions on the feasibility of controlling multiple programs simultaneously. While some propose specific tools and methods, there is no consensus on a definitive solution that meets all requirements.

Contextual Notes

Participants mention limitations related to the capabilities of the suggested tools, such as the inability to move characters in games when using Cheat Engine and the complexity of implementing socket communication for real-time control.

Who May Find This Useful

This discussion may be useful for gamers looking to control multiple games simultaneously, programmers interested in input handling between applications, and users seeking software solutions for multitasking on a single PC.

Juzernejm
Messages
2
Reaction score
0
Hi,

A tough one here. Does anyone know a way to control 2 or more programs simultaneously? i.e. give focus to two programs?

My brother wants to control two games (full screen), on the same PC, at once, I assume that he only needs one to be maximized at a time, but the trouble is giving focus to one will cut the keyboard off from the other, Any way he can make this work?
 
Technology news on Phys.org
From within one program, you can open another one as a file descriptor and read and write to it.#include <cstdio> //<stdio.h> in C
FILE * fp = popen("yoursecondprogram --withargs", "w"); //write mode
if (fp == NULL) exit(1); //ERROR
fwrite(fp, 6, 1, "hello\r"); //Sends "hello" to the secondary program's stdin.

This is useful for proxying keyboard input, if you want things like key control for a game or something more real-time reactive, stdin is likely not what you want. You'll have to open up a socket communication between the two programs: The receiving program would have to open up a listening socket and the main program would have to send keyboard statuses through it. I have a similar issue right now where I want two different computers to control one two player game. I need a small helper program on the second computer to send commands over the network.
 
Hi everyone! I have the same problem!
I found a program called Cheat Engine, you can use the hotkey option and freeze/pause every game by clicking any key.
I just have to turn on 2 Cheat Engines and select a hotkey for processes for 2 opened games. When I push the key it freezes two games at the same time, so I think it's possible to control it simultaneously. But there's a problem, There is no option for moving characters in the game, just freezing or changing values. so I have a question is there a program which will let me select a procceses and control games simultaneously? Sorry for my English
 
Juzernejm said:
Hi,

A tough one here. Does anyone know a way to control 2 or more programs simultaneously? i.e. give focus to two programs?

My brother wants to control two games (full screen), on the same PC, at once, I assume that he only needs one to be maximized at a time, but the trouble is giving focus to one will cut the keyboard off from the other, Any way he can make this work?

For games use ISBoxer. It's purpose built for this.

http://isboxer.com/

It has a lot of features. For example it can chop up the game UI and display all the UIs from all your clients onto a separate screen.

Here's a guy playing 5 clients at once with ISBoxer

http://imgur.com/8IitCv1

Edited to change the screenshot. I just remembered that no-one who doesn'tplay Eve understands Eve screenshots ;-)
 
Last edited:
Thanks Carno and everyone who tried to help me. ISBoxer is the solution of my problem.
 

Similar threads

  • · Replies 2 ·
Replies
2
Views
4K
  • · Replies 11 ·
Replies
11
Views
3K
Replies
2
Views
3K
  • · Replies 6 ·
Replies
6
Views
9K
Replies
9
Views
3K
  • · Replies 3 ·
Replies
3
Views
1K
  • · Replies 3 ·
Replies
3
Views
2K
Replies
21
Views
4K
Replies
29
Views
6K
  • · Replies 1 ·
Replies
1
Views
3K