Jump to content

Can Leadwerks Make Co-Op Game?


MadCat
 Share

Recommended Posts

RakNet is free. Leadwerks actually has ENet already built into it, and of course there's the Steam networking API. I would not say it is presently easy, but those are the three best networking libs and they're readily available.

My job is to make tools you love, with the features you want, and performance you can't live without.

Link to comment
Share on other sites

First are you talking about playing on the same PC or actual multiplayer? Also, why would you think it would cost you $50,000? The answer is no, but curious why you think it would?

 

@Josh, is enet exposed to Lua within Leadwerks?

Link to comment
Share on other sites

Making a multiplayer game gives 2 problems you would need to research first before you start developing. It can get really complicated and messy if you don't really know what you're doing. It's definitely possible in Leadwerks to make an online game. For example, I made Siege online during the Halloween game tournament.

 

The problems are:

- Finding a networking library

- Setting up your game to use networking

 

For the networking library, like above I can really recommend RakNet and ENet if you're new to networking. If you're more advanced, I can recommend looking into Boost.Asio and WinSock as it takes it to an ever lower level, giving you more control to the data you're sending out and receiving in.

 

However, RakNet is known for stuttering as their networking tends to use TCP for reliable messages. Stuttering is where data like damage arrives later than it should. For the player it can be unpleasant as it causes things like

. For a side project I've used ENet which didn't give that problem. So if I had the choice, I would pick ENet. Although, Ken Claassen made a
on how to use RakNet with Leadwerks 2.0 (previous version of Leadwerks), but the idea behind it still works. You can check that out as well.

 

Then for the implementation, there are two approaches to a co-op game. The first approach is to make the game able to host a networked game (also known as listen server), and the second option is to make a dedicated server. In Leadwerks it's easier to make a listen server as creating a dedicated server requires you to make a separate project which you will need to update constantly. A simple listen server is easier to manage both development-wise and release-wise.

 

So whenever you finish the game, you can release it like the following:

- Dedicated server: You can give the server to everyone or keep it yourself, make sure the game will still be sent to the players

- Listen server: You only give the game (as setting up the server is all in the game), but tell the players to forward a port that the networking is using to establish a connection.

 

There's still a lot to talk about for networking, but these are the basics. I'll be watching this thread for if you have further questions smile.png Good luck in the meantime.

 

@Josh, is ENet actually implemented into Leadwerks? Haven't seen that yet.

  • Upvote 1

Using Leadwerks Professional Edition (Beta), mainly using C++.

Windows 10 / Linux Mint, Visual Studio 2017. GPU: NVidia GeForce GTX970, CPU: Intel i7 7700K @ 4.20 GHz

Previously known as Evayr.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...