Hi! I have recently bought Appgamekit and I started programming right away. Years ago, I was a fan of DarkBasic but I have never created something big. Now I decided to do a multiplayer 2D game but apparently I could not connect host with the client. Here's the part of code that I use. I am really a beginner but I don't see what am I missing.
Addvirtualbutton(1,100,100,100)
Addvirtualbutton(2,250,100,100)
SetVirtualButtonText(1,"Host")
SetVirtualButtonText(2,"Join" )
do
print (ip$)
print (host)
print (connection)
sync()
if GetVirtualButtonState(1)=1
net = HostNetwork("Eren","Host",8912)
if GetNetworkExists(net)=1
host=1
Print ("Server Kuruldu")
else
host=0
endif
sleep(2000)
endif
if GetVirtualButtonState(2) = 1
StartTextInput()
endif
if GetTextInputCompleted() = 1
StopTextInput()
ip$ = GetTextInput()
net = JoinNetwork(ip$,8912,"Guest")
sleep(3000)
if GetNetworkNumClients(net) > 1
connection=1
else
connection=0
endif
endif
loop
BTW, this is my first post on this forum. I don't know if it is the right place to post. Sorry if not.