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

Multiple Instances #3

Open
MdBourg98 opened this issue Dec 29, 2019 · 7 comments
Open

Multiple Instances #3

MdBourg98 opened this issue Dec 29, 2019 · 7 comments
Assignees
Labels
enhancement New feature or request Fix Later Will add to list of issues to fix later on
Milestone

Comments

@MdBourg98
Copy link

In the newer video it showed this running on 3 different instances of Minecraft. I cant figure that out.

@monpjc monpjc self-assigned this Jan 15, 2020
@monpjc monpjc added enhancement New feature or request help wanted Extra attention is needed labels Jan 15, 2020
@monpjc monpjc added this to the GUI XAHK V1.0 milestone Jan 15, 2020
@monpjc
Copy link
Collaborator

monpjc commented Jan 15, 2020

Hi @MdBourg98 Its currently only for use with one client - Xisuma used a cheet. I am now back on this project and will be updating the code to support multi-client.

Thanks for you commnets

@MdBourg98
Copy link
Author

Hi @monpjc I actually found what he did afterwords and forgot to update this. F3+P lets you Alt+Tab without the game pausing. Not exactly a cheat, just a debug option.

@monpjc
Copy link
Collaborator

monpjc commented Jan 26, 2020

This appears to be a issue within AHK that gets confused as to what keys strokes should be sent to witch window. I think AHK was designed to assist people working one screen more than a addition to game play.
Will mark as fix later as will need some work to program correctly.
However will talk to Xisuma about how he 'tricked' the program into working and if repeatable will post this as a work around for people to use.

@monpjc monpjc added Fix Later Will add to list of issues to fix later on and removed help wanted Extra attention is needed labels Jan 26, 2020
@felixfong227
Copy link

I manage to kinna make this work my modifying one line on the source code( #11) on my local machine and get a great result on my fishing farm 😄

@Fran314
Copy link

Fran314 commented Mar 15, 2020

Hey @monpjc ! Did you ever find out how he managed to 'trick' the program? I'm using this (very useful, thank you) source code to creating a similar version of this program (redoing a bit of the GUI and adding a couple of farms I use a lot) and I have no idea how to make that work! I've tried looking into the #SingleInstance part, and while I can run multiple instances of the program, once I select a window with the second instance, the first instance just stop sending keys. No idea how to get around this

@XPcrafter
Copy link

Hey @Fran314
I actually managed to get it to work for several minecraft windows at once with my first try ages ago.
My approach was to make two different files with the start picture and the script in them, then I renamed one of the scripts itself differently to the other (You could probably have them in one file, I haven't tried that though yet). Then you start one of the instances and assign it to an MC window. Then start the mode you want to use and get it running. With ALT + TAB you switch to the XAHK menu and by double-clicking the minimize button on the top Right of the MC window you minimize it. Then you start the next instance and also start the selected mode. Now you have two accounts farming whatever you configured them to! :)
Stopping is a bit more complicated though (not really, just if you want to Restart it afterwards again- for example you want to check you fish farm chests for a second and then start farming again). This is when you have to close all AHK instances and do the Setting up all over again. Depending on the number of MC Windows you have running at once it can take a Moment :/

So here a bit Shorter:

  1. Make copies of the file with XAHK and the start Image in them.
  2. rename the files and actual scripts uniquely
  3. start the instances singularly and start the mode before starting the next instance

Hope this helps! If you didnt understand my chaotic answer please tell me ;)

@histefanhere
Copy link
Owner

This is quite an important issue! There should totally be support for controlling multiple instances of Minecraft at the same time on the same machine. An issue to sort out for this is shortcut conflicts, i.e. if they're all running in the same mode, which one should start on hotkey press?

As discussed already, there are two options for how to implement this feature:

  1. Support multiple instances of minescript
    As @XPcrafter has found you can kinda get multiple instances of the AHK script running if you jiggle some stuff around and remove the #SingleInstance Force line, as was tried in this pr. This kinda still feels like a work around though, and a better option might be:
  2. Control multiple instances of MC through one script
    The UI would need a big rework for this, but this would be by far the most elegant solution.

This feature is by no means an easy feat and should probably be done after the UI is sorted out.

@histefanhere histefanhere changed the title Only 1 window? Multiple Instances Feb 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request Fix Later Will add to list of issues to fix later on
Projects
None yet
Development

No branches or pull requests

6 participants