First off, I would like to say two things. One, this is not for beginners; if you don't feel that you understand this how-to at all, do not try it. Second, never ever install random software or change settings if you do not trust the source.
If I haven't scared you yet, here is a trick you can use to let someone who isn't on the same local network access a world you have "Open to LAN". Since local addresses aren't routed onto the Internet, you need some trick to be able to allow others to connect.
For this, you need a friend who has a computer running Linux (or any other Unix-like system... I did this on FreeBSD), an account on that machine, and PuTTY, which is a program that lets you log in on remote computers.
SSHD is running by default on most Linux-distributions. But you need to change some settings to allow the tunnel you are about to create to accept connections from the outside. So, open /etc/ssh/sshd_config and set (or add) "GatewayPorts yes", and then restart sshd._
Back on your computer, download and install "a Windows installer for everything except PuTTYtel" from here.
Open Notepad and save it to a file with the suffix ".bat". I called mine mctunnel.bat:
set /P MCREMOTEHOST="Remote host: "
set /P REMOTEUSER="Username: "
set /p MCMYPORT="LAN address to share: "
"c:\Program Files (x86)\PuTTY\plink.exe" -v -x -a -T -C -noagent -ssh -P %SSHPORT% -R %MCREMOTEPORT%:%MCMYPORT% %REMOTEUSER%@%MCREMOTEHOST%
Note: That last line is supposed to be a very long line without any breaks.
You might want to change some settings. For example, I have my ssh-server running on another port that the standard port 22 and port 12345 can be changed to anything between 1025 and 65535. Check with the person who owns the Linux-computer which port he/she thinks is best. Also, your installation might have put plink.exe somewhere else, check that.
And you can change all of the "set /p" to something static, like "set REMOTEUSER=yownas" since it won't change..
Mmm, yea. Think most of you know how to do this.
Press ESC and click on "Open to LAN". The chat window should say something like: "Local game hosted on 192.168.1.67:50664".
Double-click your bat-script. It should ask you for "Remote host:" which is your friends Linux-computer, "Username:" which is the username you use to log in on that computer, and "LAN address to share:", just copy the string, in my case 192.168.1.67:50664, Minecraft told you.
You should now see a lot of text flashing by, and at the bottom it asks for your password to the Linux-machine. Enter it and you are done. :)
SSH has now set up a tunnel between your machine and the Linux-computer. The local LAN-port for Minecraft has been mirrored to port 12345 on the other side.
So, instead of the disappointing "Connection refused: connect" when people try to connect to your local LAN-address, they can connect to your.friends.linux.computer:12345 and join you in killing creepers and walk into your redstone traps. :)
Want to master Microsoft Excel and take your work-from-home job prospects to the next level? Jump-start your career with our Premium A-to-Z Microsoft Excel Training Bundle from the new Gadget Hacks Shop and get lifetime access to more than 40 hours of Basic to Advanced instruction on functions, formula, tools, and more.