Hey guys,
So I have been developing a multiplayer game for a while now and decided to try and play the game via 2 different computers in my home. Problem is I cant seem to get the client to find the host. I'am quite sure I have the native DBP commands set up right. Before this test I was successfully running multiple instances of the game on one computer with the connection set to Internet TCP/IP and the IP address set to localhost 127.0.0.1 ... One issue that is unclear to me is what host address should I use/search for.. The computer that I host from has a local IP 192.168.0.X and the client IP is 192.168.0.X+3, Both comps are connected to the same modem and have the same masked IP as found at www.ipchicken.com... I have tried hosting and searching the local and masked IP with no success. I have also tried Port forwarding the direct play ports TCP 2300-2400 to the 192.168.0.X .. Any Ideas what I have done Wrong?
This is the connection functions I have been using for host and client...
function CreateNetGame(B$)
connection = findTCPIPconnectionNumber()
center text 300,20,"Creating Net Game: "
center text 300,40,B$
sync
sleep 200
set net connection connection,B$
create net game "Game1", myname, 8,1
endfunction
function findTCPIPconnectionNumber()
perform checklist for net connections
for x = 1 to checklist quantity()
service$ = checklist string$(x)
if left$(service$,15) = "Internet TCP/IP"
connection = x
endif
next x
endfunction connection
function JoinNetGame(B$)
connection = findTCPIPconnectionNumber()
center text 300,90,"Joining Net Game: "
center text 300,110,B$
fastsync
sleep 200
set net connection connection,B$
perform checklist for net sessions
numberofgames = checklist quantity()
if numberofgames = 0
center text 300,90,"No Games Found! :("
sync
wait key
end
endif
join net game 1,myname
endfunction
Thanks!