When testing the connection between your Windows install and a Virtual Box Ubuntu instance on the same PC you may enounter errors when establishing communications. If you do, please check the following settings are applied correctly. Note that you should have the command window set to be shown in GameMaker before doing any of this, as this is where you get your feedback and any error messages.
Checking SSH on the VM
First of all, on the Ubuntu VM, open a Terminal and run the following two commands to confirm that your Ubuntu machine is capable of listening for network traffic from GameMaker.
sudo apt-get install openssh-server
sudo /etc/init.d/ssh restart
Obviously, if you get any errors about missing packages or other issues, you will need to fix these at this point. Refer to our other Ubuntu setup guides or apt-get's documentation for more information on packages you need and how to get them.
If there are no errors in Terminal, try checking the connection inside GameMaker: Studio once again to see if that's fixed your issue already. If not, check the action required for the specific error messages below.
Connection Errors Inside GameMaker: Studio
FATAL ERROR: Network error: Connection Timed out. - This is that the IP you are specifying in Preferences might not be correct. Here, you should provide a connection to "localhost" (i.e., the same PC you're connecting from), rather than the actual IP of the PC as it appears on the network. So the IP you should have entered in GameMaker: Studio on the Preferences > Ubuntu screen is 127.0.0.1, as shown below:
FATAL ERROR: network error: Connection refused. - On checking the connection again now you have changed the IP to be correct, you may recieve this error, which means you can see the machine, but it won't respond to your connection request. To fix this you will need to manage your network setup within Virtual Box.
Go to the Machine menu and choose Settings, then Network. Ensure "Adapter 1" is enabled and attached to NAT, as shown below:
Now click the Port Forwarding button near the bottom of that dialogue. You should have an entry in here in order to talk to your VM over the network, so ensure that you add a new entry (use the little green + button on the right of this new dialogue) which matches the following:
Now OK all Virtual Box setup windows to apply the changes, then check your connection inside GameMaker once more. You should now be able to communicate with your VM and start working with Ubuntu inside Studio.