在steam上有人分享的script內容:
#ifwinactive ahk_exe ItTakesTwo.exe ;WinMove, WinTitle, WinText, X, Y , Width, Height, ExcludeTitle, ExcludeText F11::WinMove, A,, 0, 0 , 3840, 1080 F10::WinMove, A,, 0, 0 , 1920, 1080 F6::WinMove, A,, 0, 0, A_ScreenWidth, A_ScreenHeight F7::WinMove, A,, 0, 0, (A_ScreenWidth*2), A_ScreenHeight |
雙人成行本身不支援獨占畫面必須分割畫面,他的作法是借助AutoHotkey將整體畫面放大後並且只在自己螢幕範圍內顯示科迪或小梅的畫面,缺點是會佔用多一倍的顯示記憶體,盡量降低畫質取得較好的遊戲體驗.
先解釋原先熱鍵對應的功能
按F11鍵為使用3840*1080螢幕解析度
按F10鍵為使用1920*1080螢幕解析度
按F6鍵為使用自身螢幕解析度
按F7鍵為將自身螢幕解析度寬度*2,高度不變
當初製作的人可能是考慮到每個人的的螢幕解析度不一樣才會設定兩套解析度,不過這兩套作法都只能將小梅畫面放大,實際上科迪的畫面會被放大到螢幕外造成必須真的有兩個實體螢幕才能看到科迪的畫面.
所以必須要在script上調整一下讓只有一個螢幕的人將科迪的畫面偏移到螢幕內,而要調整的數值為X值,也就是說為了將科迪畫面向左偏移所以必須要把X值設定為負的螢幕寬度,可以另外增加一個F8鍵顯示科迪畫面,並且以參數A_ScreenWidth作為偏移值
F8::WinMove, A,, -(A_ScreenWidth), 0 , (A_ScreenWidth*2), A_ScreenHeight
再來是上下切割畫面可以使用高度*2,寬度不變的方式來顯示,偏移Y值來顯示科迪畫面,但是大部分切割上下時的情況通常更強調合作默契,遊戲挑戰難度更大.
小梅畫面(放大並只顯示上方切割畫面)
F9::WinMove, A,, 0, 0, A_ScreenWidth, (A_ScreenHeight*2)
科迪畫面(放大並只顯示下方切割畫面)
F10::WinMove, A,, 0, -(A_ScreenHeight), A_ScreenWidth, (A_ScreenHeight*2)
最後script被改寫為:
#ifwinactive ahk_exe ItTakesTwo.exe ;WinMove, WinTitle, WinText, X, Y , Width, Height, ExcludeTitle, ExcludeText F6::WinMove, A,, 0, 0, A_ScreenWidth, A_ScreenHeight F7::WinMove, A,, 0, 0, (A_ScreenWidth*2), A_ScreenHeight F8::WinMove, A,, -(A_ScreenWidth), 0, (A_ScreenWidth*2), A_ScreenHeight F9::WinMove, A,, 0, 0, A_ScreenWidth, (A_ScreenHeight*2) F10::WinMove, A,, 0, -(A_ScreenHeight), A_ScreenWidth, (A_ScreenHeight*2) |
F6為原始解析度
F7為小梅畫面(左)
F8為科迪畫面(右)
F9為小梅畫面(上)
F10為科迪畫面(下)
如果是試玩版(同樂版)的話使用者要將ItTakesTwo.exe改偵測為ItTakesTwo_Trial.exe
#ifwinactive ahk_exe ItTakesTwo_Trial.exe ;WinMove, WinTitle, WinText, X, Y , Width, Height, ExcludeTitle, ExcludeText F6::WinMove, A,, 0, 0, A_ScreenWidth, A_ScreenHeight F7::WinMove, A,, 0, 0, (A_ScreenWidth*2), A_ScreenHeight F8::WinMove, A,, -(A_ScreenWidth), 0, (A_ScreenWidth*2), A_ScreenHeight F9::WinMove, A,, 0, 0, A_ScreenWidth, (A_ScreenHeight*2) F10::WinMove, A,, 0, -(A_ScreenHeight), A_ScreenWidth, (A_ScreenHeight*2) |
附上快速執行檔
也可以下載AutoHotkey主程式,將上方的script存放在記事本後再另存副檔名為ahk的檔案也是一樣效果,而且還能自行編輯所需功能,像是使用更順手的熱鍵.