So I tried moving the console that I'm opening, and found about SetWindowPos method inside user32.dll and so I tried it using the code below
hwnd = Win32API.new('user32.dll', 'FindWindow', 'PP','N').call(0, game_title) Win32API.new('kernel32.dll', 'AllocConsole', '', '').call ...