I would like to make a program that can move a lot of windows into a grid-like pattern.
I am trying to make something for agar.io. I found out a way to get a lot of free "dummy" cells that I can eat to grow. I open two agar.io windows, and then use one for my main "cell/character". In the other one, I make a new cell, then move the mouse to one of the corners, and then out of the window. The cell will still travel in that direction, so if I stay in that corner of the map, the new cell will get there eventually, and I can eat it. Of course, this is very time consuming, however. I want to open a bunch of agar.io windows, because if i open those windows and then move the cursor off of each one, it will make all of them go to the corner.
So here's the question:
Is there a way to split ~30 or so windows into a grid pattern? They don't have to be tabs of one google window, if that makes it easier. I think I can get a way for the script to open the ~30 windows, and I know there is winmove, but writing that many winmove commands seems redundant. Is there one command that can do it? Or will i have to do each winmove command? I can probably do a loop for the window coords, but it may be hard for the script to catch when it is at the edge of the screen.
Move Windows into a grid
-
- Posts: 6
- Joined: 15 Mar 2016, 10:28
Re: Move Windows into a grid
This example creates 9 Notepad windows in a grid:Edit: or... http://www.howtogeek.com/howto/11073/st ... windows-7/
Code: Select all
Columns := 3
Rows := 3
CellW := 300
CellH := 300
Loop, % Rows {
ThisRow := A_Index
Loop, % Columns {
Run, Notepad,,, WinPID
WinWait, % "ahk_pid " WinPID
WinMove, % "ahk_pid " WinPID,, (A_Index - 1) * CellW, (ThisRow - 1) * CellH, CellW, CellH
}
}
-
- Posts: 6
- Joined: 15 Mar 2016, 10:28
Re: Move Windows into a grid
Thanks kon! That's exactly what I was looking for! I knew about the howtogeek thing where you can tile horizontally or vertically, or show side by side. It doesn't do what I wanted. I needed it tiles in squares to save screen real estate. Thanks!
Who is online
Users browsing this forum: No registered users and 57 guests