Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / AGKv1 Tier 1 and TCP

Author
Message
CodeTrasher
12
Years of Service
User Offline
Joined: 18th Jul 2012
Location: Tampere, Finland
Posted: 21st Jan 2015 15:10
Hi all,

the company I'm working for is hosting an internal AI programming event. One of my colleagues is working on a server which will be running on Tomcat. The idea of the event is to program an AI bot client which will fight against another bots, and these clients will communicate with the server over TCP. The participant can choose which programming language they are going write the bot with.

I would like to join the event and try to code my bot with AppGameKit but because I haven't tried any commands related to networking or multiplayer in AppGameKit, I'm not sure can I use it. So, I'd like to know is the multiplayer functionality supported only on AppGameKit client-server connections or will I be able to write my client by using AppGameKit? The data to be sent in TCP messages will be JSON strings so I have to figure a way around this by myself.

I hope someone would be able to clarify this to me. If I did explain myself clearly enough, ask me for more information.

Thanks!
Paul Johnston
TGC Developer
22
Years of Service
User Offline
Joined: 16th Nov 2002
Location: United Kingdom
Posted: 21st Jan 2015 16:35
If you use Tier 2 then you'll have access to the AGKSocket class for raw TCP sockets, but currently this is not exposed to Tier 1. I hope to open this up at some point in the future.
CodeTrasher
12
Years of Service
User Offline
Joined: 18th Jul 2012
Location: Tampere, Finland
Posted: 21st Jan 2015 16:45
Thanks for your reply, Paul! I was wondering, how about multiplayer commands in v1 such as JoinNetwork? Will this work only if the host itself is made with AppGameKit?
Paul Johnston
TGC Developer
22
Years of Service
User Offline
Joined: 16th Nov 2002
Location: United Kingdom
Posted: 21st Jan 2015 17:38
Officially, yes, although some people have built a compatible version in C# that can communicate with an AppGameKit client here
Markus
Valued Member
20
Years of Service
User Offline
Joined: 10th Apr 2004
Location: Germany
Posted: 21st Jan 2015 20:52
if this webserver using a web interface i think u can use the http commands
in tier1.
creating json strings is not the problem, but if u get this json
u need a class for handle this content.
http://json.org/

AGK 108 (B)19 + AppGameKit V2 Alpha .. : Windows 8.1 Pro 64 Bit : AMD Radeon R7 265 : Mac mini OS X 10.10 (Yosemite)
BatVink
Moderator
21
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 21st Jan 2015 23:01
I have the solution Paul has mentioned working, but it's not ready to publish here yet. I won't be finishing it until after the next newsletter is finished.

Check the thread above and grab all the code that had been posted, it shouldn't take too much effort to get it up and running.

Quidquid latine dictum sit, altum sonatur
CodeTrasher
12
Years of Service
User Offline
Joined: 18th Jul 2012
Location: Tampere, Finland
Posted: 22nd Jan 2015 10:04
Thanks all for your replies! I will take a closer look in to this and view those other threads your guys suggested.

Login to post a reply

Server time is: 2024-11-25 15:19:38
Your offset time is: 2024-11-25 15:19:38