Jump to content

True LAN Coop - Proposition


Crynux

Recommended Posts

.

 

 

You make sense. The only problem is that there are people with dynamic IP addresses, so there would be no means to identify someone without a username or password. Additionally, it would be possible with such a system to have servers where nobody joins forever, as some players had already joined, and decided not to play there anymore, locking all of the character slots

 

I think that there should be at most four people per server, not just four at one time playing, and you couldn't switch characters when rejoining a server you have already entered as a certain character. That would prevent all the slots from being locked. I don't know how you could identify people, though. 

 

What might be a semi-plausible workaround is that there is a lobby where people choose the characters before the game is started. Then the server would be locked to anyone else. It doesn't allow the game to start and the world to be generated if two players have the same character selected. So when people came back they could only resume playing that world on their character, which would be determined locally, not by the server, and you said you can save inventory by character.

Link to comment
Share on other sites

Sooo. I got cut short on my comment I was skyped by a friend and well I never came back.

 

Here I am today, all I was sawing was that I liked option 3 the most. The fact that the data is saved on character (Wilson, Wx, etc) rather than any of the other alts.

 

On the talk about caves, I would love to be able to be in a cave while a friend is not but I understand just how hard that would probably be to make. If you are determined to then go right ahead I'm right here to support you, as I would prefer this. However in the case of starting off simple, make it that when a player tries to enter a cave it notifies everyone on the server to accept coming or not. If everyone accepts then you all enter. The only problem is I am basing this off how I will be using the mod. With friends, some others may just hook up with random people and then it might not be as good. Just wanted to say that as how I will suggest & comment will be biased in this way.

Link to comment
Share on other sites

When a player enters a cave, adventure mode, etc., the current game state is terminated and another one is started (the game calls StartNextInstance, which in turn calls SimReset, which performs the "reboot", usually passing some parameters to the next instance of the game state which is carried along by the game engine and plops up as the global Settings table when the next state reaches gamelogic.lua); a new state is completely independent from the previous ones, sharing no global variables. Since the game cannot run more than one state at the same time, if you'd like to allow for different players to be in different levels at the same time you would have to implement dynamic client-server switching on a level basis (i.e., if a host is the first one to enter a level, it becomes the server for that level, even if it was a client in its previous level). Since this adds some complexity to the implementation and decentralizes control of game state, you may want to force all players to switch levels together (though allowing the dettaching would sure be fun).

 

Thank you for the info on caves. I had already kind of thought that they would have involved some sort of world change, but if it is as you've said, it shouldn't be too difficult to add caves in the future.

 

 

I think that there should be at most four people per server, not just four at one time playing, and you couldn't switch characters when rejoining a server you have already entered as a certain character. That would prevent all the slots from being locked. I don't know how you could identify people, though. 

 

What might be a semi-plausible workaround is that there is a lobby where people choose the characters before the game is started. Then the server would be locked to anyone else. It doesn't allow the game to start and the world to be generated if two players have the same character selected. So when people came back they could only resume playing that world on their character, which would be determined locally, not by the server, and you said you can save inventory by character.

 

The problem becomes, once again, how do you identify a player without a username of sorts? I agree that there should only be a few players per server in the final version of the mod, for beta, however, there will be no limit, as I want to stress test the server.

 

A lobby is an interesting idea, but if we do make one, and I can't say that there are plans to do so at the moment, it would take quite some time. When reading your comment, I understood it as some sort of a Left 4 Dead lobby concept, which I think would be nice, but given the possible length of gameplay in Don't Starve, it would also need usernames to identify players on reconnect.

 

 

Sooo. I got cut short on my comment I was skyped by a friend and well I never came back.

 

Here I am today, all I was sawing was that I liked option 3 the most. The fact that the data is saved on character (Wilson, Wx, etc) rather than any of the other alts.

 

On the talk about caves, I would love to be able to be in a cave while a friend is not but I understand just how hard that would probably be to make. If you are determined to then go right ahead I'm right here to support you, as I would prefer this. However in the case of starting off simple, make it that when a player tries to enter a cave it notifies everyone on the server to accept coming or not. If everyone accepts then you all enter. The only problem is I am basing this off how I will be using the mod. With friends, some others may just hook up with random people and then it might not be as good. Just wanted to say that as how I will suggest & comment will be biased in this way.

 

I'm starting to become quite fond of the characters keeping their data. It's somewhat easier to do, and people seem to like it.

 

Regarding caves, if they are setup as simplex had suggested above, then there would be no reason why players couldn't enter a cave, and still have other people playing up above.

 

The main things keeping us from making caves work in the beta at this moment are:

  1. We want to make sure everything else works first... drops/mobs/fire sync/ weather sync, etc
  2. We're not sure what do do about the physics of falling rocks in the cave... I'm not sure if they tend to slide or bounce around, and if they do, then it'll be more difficult to synchronize them.

 

 

When you say this will be a non-Steam mod, do you mean if you own DS on Steam, you won't be able to play the mod?

 

Well, the steam version of the game seems to not have LuaSockets, which means no networking. The standalone version, however, does have LuaSockets for windows only (at least in the build I'm using). Those with steam can actually download the standalone version with their steam key.

 

Read How to get the stand-alone version. (Scroll down the page, near the bottom)

 

That will also be another factor into the possibility of the mod supporting the DLC... does the DLC have LuaSockets? I'm not sure, and haven't checked.

 

 

Once again, thanks to all for the comments and suggestions/tips.

-Crynux

Link to comment
Share on other sites

Well, the steam version of the game seems to not have LuaSockets, which means no networking. The standalone version, however, does have LuaSockets for windows only (at least in the build I'm using). Those with steam can actually download the standalone version with their steam key.

 

Read How to get the stand-alone version. (Scroll down the page, near the bottom)

 

That will also be another factor into the possibility of the mod supporting the DLC... does the DLC have LuaSockets? I'm not sure, and haven't checked.

 

 

Once again, thanks to all for the comments and suggestions/tips.

-Crynux

 

Tanks, bruv.


^^^^^Woops, I apparently don't know how to quote.

Link to comment
Share on other sites

 

The problem becomes, once again, how do you identify a player without a username of sorts? I agree that there should only be a few players per server in the final version of the mod, for beta, however, there will be no limit, as I want to stress test the server.

 

A lobby is an interesting idea, but if we do make one, and I can't say that there are plans to do so at the moment, it would take quite some time. When reading your comment, I understood it as some sort of a Left 4 Dead lobby concept, which I think would be nice, but given the possible length of gameplay in Don't Starve, it would also need usernames to identify players on reconnect.

 

 

Not to put even more of a workload on your shoulders, but why can't you do usernames? I mean to say that in a purely inquisitive, not snobby way. Before you could choose to play on a sever, you would have to decide on a username.

Link to comment
Share on other sites

I've only now stumbled upon this mod, and I must say that I am amazed! Thank you very much for putting so much effort into an endevour like this, I'm sure you'll make many people happy with this ;)

Thanks for the comments! It will take quite some time... but it's doable.

 

 

 

Tanks, bruv.

^^^^^Woops, I apparently don't know how to quote.

 

No problem! :cool2:

 

 

Not to put even more of a workload on your shoulders, but why can't you do usernames? I mean to say that in a purely inquisitive, not snobby way. Before you could choose to play on a sever, you would have to decide on a username.

 

I'm not saying usernames will never be done... it's just they won't be done in the Beta. I was looking for suggestions on what to do with the inventory in the Beta version only. I don't want to get into usernames and such in the beta, but rather a simpler, less complex inventory system. For usernames, we'd need a username UI, username control and management on the server, etc, etc. Usernames at this point would only delay the beta longer.

 

A password-locked chest is more complex than any of the other options, besides usernames themselves, but it would give the option for players to keep their inventory despite not having a username, which was why I added it to the 3 options in an earlier post.

 

Try to keep in mind that we're trying to lay down and test the major features in the Beta... usernames/logins, etc can be added once the base gameplay is tested and proved to be working well.

 

 

Another way I could imagine is that you could lock the character you selected with a password directly, so that (if all goes by plan) only you have access to him.

 

This wouldn't work well in the Beta, as for the beta we plan to have no limit on characters per server... I want to stress test the server in the beta, to see how well it can handle things, and at what number of players does it start falling apart.

 


 

I'd like to clarify that the inventory system for the beta will not necessarily be the final inventory system. We just need a simple alternative to usernames and passwords.

 

This can be said for many things in the beta... at the moment, there is no plan to have caves in the beta. However, in the final version, I would like to have caves.

 

So as you see, just because we're avoiding something now doesn't mean it will not be in the final version. My approach is to avoid all of the fancy stuff, and just have a concrete base system for the beta. Once the beta release is tested and proved to be stable, then we can add in usernames and passwords, even scoreboards and such.

 

For beta suggestions... keep the KISS principle in mind. Anything more will likely slow and complicate things.

 

Thanks again, I appreciate all input.

-Crynux

Link to comment
Share on other sites

Hello Crynux! First of all I want to congratulate you for this mod and the amount of dedication you and Desblat are putting into getting it done.

 

Second, about the characters and inventory, in order to keep it simple for beta, just have it saved on the user's pc (encrypted if possible, if not just leave it be while it's on beta, Don't starve probably won't be much about competition)

 

I have zero understanding of coding so I might be spewing crap here but I hope you find a feasible way to do it, and again, congratulations for the mod.

Link to comment
Share on other sites

For how to actually create the server, a good idea is too make it so that you can choose a maximum number of players to join your server but the maximum you can have up to is eight. So that if someone has a lot of friends who wants to join there server then they can but if you only want one to join your server then you can do that too. For generally setting up a server, click on multiplayer and then there would be a join server button where you would type in the ip and port and then there would be a connect button which when clicked tries to connect you to the server, and another button for create server where you can increase the amount of players up to eight and then it will go back down to one and a port which you can type in like five thousand and eleven and then click the done button to go to select character and once you done that it will create the world and the server will be running. You don't have to do this but it would be a good idea, well in my opinion. This would probably be really difficult to do and maybe some of it impossible but if you try you can probably do it.

Link to comment
Share on other sites

 

I'm not saying usernames will never be done... it's just they won't be done in the Beta. I was looking for suggestions on what to do with the inventory in the Beta version only. I don't want to get into usernames and such in the beta, but rather a simpler, less complex inventory system. For usernames, we'd need a username UI, username control and management on the server, etc, etc. Usernames at this point would only delay the beta longer.

 

A password-locked chest is more complex than any of the other options, besides usernames themselves, but it would give the option for players to keep their inventory despite not having a username, which was why I added it to the 3 options in an earlier post.

 

Try to keep in mind that we're trying to lay down and test the major features in the Beta... usernames/logins, etc can be added once the base gameplay is tested and proved to be working well.

 

Gotcha. For now my thoughts are "insert weird chanting"

 

"Chest! Is the best! Chest is the best so ya best not mess with the chest!  Is the best! Chest is the best so ya best not mess with the chest! Is the best! Chest is the best so ya best not mess with the chest!" and so on.

Link to comment
Share on other sites

Hello Crynux! First of all I want to congratulate you for this mod and the amount of dedication you and Desblat are putting into getting it done.

 

Second, about the characters and inventory, in order to keep it simple for beta, just have it saved on the user's pc (encrypted if possible, if not just leave it be while it's on beta, Don't starve probably won't be much about competition)

 

I have zero understanding of coding so I might be spewing crap here but I hope you find a feasible way to do it, and again, congratulations for the mod.

 

 

Hi, thank you for the congratulations.

 

Regarding you suggestion that we store inventory on the client/user's pc, this will unfortunatley not work for the beta. Since I don't know how or if we'd be able to generate a new map on the server, we have to provide a base map with the mod for people to connect to the server with. Behind the scenes, when you click on "Multiplayer", the game loads a map seperate from the normal savegames. If we were to store your inventory IN the map savegame, as is done in normal single player, then you'd be able to keep inventory across servers.... which would be strange.

 

In addition, however, this would cause issues, as everything in the multiplayer gameplay is planned to have a server id. Reconnecting, and loading inventory from a local source may provide inconsistent ids for the items, which could cause issues. It would be possible to make it so that the items saved locally would poll the server for new/old ids, but this wouldn't be an optimal solution.

 

However, in writing this response... you caused me to think of some other ideas to consider. Thank you!

 

Yo Crynux, how you gonna deal with Chester's bone and touchstones and stuff like that?

 

At the moment, the idea of having Chester in the beta is up in the air, so to speak. We haven't looked into synchornizing him/it... but there still is the question whether or not to have multiple or just one Chester... thoughts?

 

For how to actually create the server, a good idea is too make it so that you can choose a maximum number of players to join your server but the maximum you can have up to is eight. So that if someone has a lot of friends who wants to join there server then they can but if you only want one to join your server then you can do that too. For generally setting up a server, click on multiplayer and then there would be a join server button where you would type in the ip and port and then there would be a connect button which when clicked tries to connect you to the server, and another button for create server where you can increase the amount of players up to eight and then it will go back down to one and a port which you can type in like five thousand and eleven and then click the done button to go to select character and once you done that it will create the world and the server will be running. You don't have to do this but it would be a good idea, well in my opinion. This would probably be really difficult to do and maybe some of it impossible but if you try you can probably do it.

 

I understand that custom server settings will be needed/wanted... for the moment though, we need to keep things simple. As an alternative to the ip and port idea... we could also have a server list... similar to games like Garrys Mod and such, where you can find other games to join. But this is far off at the moment. Thanks for the comments!

 

 

<33 guys i love you !! http://www.reddit.com/r/dontstarve/comments/2242zl/true_lan_coop_desblat_and_some_other_guys_are_on/ a reddit thread i started to catch some attention

 

Checked it out... noticed that you hadn't mentioned me, which is strange as I'm the one who started this mod. Thanks for making the post, I'm not much of a redditer to be honest... :-)

 

 

Gotcha. For now my thoughts are "insert weird chanting"

 

"Chest! Is the best! Chest is the best so ya best not mess with the chest!  Is the best! Chest is the best so ya best not mess with the chest! Is the best! Chest is the best so ya best not mess with the chest!" and so on.

 

lol, I just came from a 75 minute history class, read this, and now my brain is comepletely fried... :hypnotized:

 

Thanks to all for the comments!

 

-Crynux

Link to comment
Share on other sites

(...)If we were to store your inventory IN the map savegame, as is done in normal single player, then you'd be able to keep inventory across servers.... which would be strange.

 

 

Not really strange, some games like Diablo, Torchlight, Terraria and Starbound have 'client side' inventories.

Link to comment
Share on other sites

Yoo, I saw you need a Dont Starve expert for your CO-OP project, I know quite abit about all the ingame stuff. Message me on steam on /id/kaaswater or add me on skype at ariedeknak if you want to discuss it further

Link to comment
Share on other sites

Not really strange, some games like Diablo, Torchlight, Terraria and Starbound have 'client side' inventories.

 

Hmmm... true, but it would be strange in regard to Don't Starve. Keeping one inventory forever, across multiple servers, doesn't make sense. Each server is a world... items and the like should be seperate, tied to the world.

 

The only way to make client side inventories work would be to have some sort of save based on the server you connect to... which is messy.

 

If anything, in the mod, everything will be stored on the server... think of it like how Minecraft works. Character/inventory information is kept with the server.

Link to comment
Share on other sites

Hello, Crynux!

I was thinking on creating a mod with multiplayer with a server-client structure, than I found your post. Great work you've done!

 

Concerning the structure, I said that the server is dedicated. Since the login or server chooser is not implemented (At least in the last video you uploaded), how players choose which server they join (e.g. if 2 players create servers and then switch to the same network, is it even possible?).. The whole server is a black-box for me atm.

You also said that the first player that sees a mob has its brain. So server doesn't handle all mobs? Also if players disconnect, the mob's brain are lost and mobs freezes?

Sorry for asking dev questions with you. I'm a university student too and I know every single project we try to do consume alot of time...

I'm just trying to clarify things, since my basic objective is to play DS on LAN with some friends.
 

I don't know who is working with you (if there's anybody), but If you need some help, I'm up to it. I'm a C++ (mainly) program with some experience in scripting (Lua, python). And if you have a github/bitbucket account for the project, I'd be very happy to see it and could even try implementing lobby/login stuff or anything else.

 

Loved to see all the great work you have already done and all the dedication you have to improve DS playability!

If you ever stop the project for any reason, please ensure to hand the project files to other dedicated modder xD

 

Cya,

kogyblack

Link to comment
Share on other sites

Hmmm... true, but it would be strange in regard to Don't Starve. Keeping one inventory forever, across multiple servers, doesn't make sense. Each server is a world... items and the like should be seperate, tied to the world.

 

The only way to make client side inventories work would be to have some sort of save based on the server you connect to... which is messy.

 

If anything, in the mod, everything will be stored on the server... think of it like how Minecraft works. Character/inventory information is kept with the server.

 

To create client-side inventory you just need to add a hash/id of the server (can be done in the name of the file to avoid loading all files searching the server id. Only tries to load the file named with the server id, if it doesn't exists, it's a new player).

This one suited better at first glance, but concerning items ids and sync, it can be messy, as you said. But if server holds the ids of all items, ensuring that the inventory is only loaded for the correct server, ids wouldn't break, I assume..

Link to comment
Share on other sites

Hello, Crynux!

I was thinking on creating a mod with multiplayer with a server-client structure, than I found your post. Great work you've done!

 

Concerning the structure, I said that the server is dedicated. Since the login or server chooser is not implemented (At least in the last video you uploaded), how players choose which server they join (e.g. if 2 players create servers and then switch to the same network, is it even possible?).. The whole server is a black-box for me atm.

You also said that the first player that sees a mob has its brain. So server doesn't handle all mobs? Also if players disconnect, the mob's brain are lost and mobs freezes?

Sorry for asking dev questions with you. I'm a university student too and I know every single project we try to do consume alot of time...

I'm just trying to clarify things, since my basic objective is to play DS on LAN with some friends.

 

I don't know who is working with you (if there's anybody), but If you need some help, I'm up to it. I'm a C++ (mainly) program with some experience in scripting (Lua, python). And if you have a github/bitbucket account for the project, I'd be very happy to see it and could even try implementing lobby/login stuff or anything else.

 

Loved to see all the great work you have already done and all the dedication you have to improve DS playability!

If you ever stop the project for any reason, please ensure to hand the project files to other dedicated modder xD

 

Cya,

kogyblack

Hi, glad to know you're interested in the mod.

 

The server is dedicated, it handles all spawns, and manages all ids for mobs/items/players. You're right in saying that there is no login/server chooser. At the moment I'm focused on getting the base game working. Later there will likely be some sort of server chooser or ip address field, but not right now.

 

When the beta goes live, I plan to stress test the server... I want to see how many players it can handle without crashing and without too much lag.

 

Regarding mobs, at the moment the general idea is to have the first player who sees the mob serve the brain; when that player is no longer available, the next 'closest' player will become the brain host. In this way, the whole project is easier as we don't have to recode all of the mob brains on the server; which is written in C. (~3000 lines so far)

 

Don't Starve is a great game, there are no doubts about that. I've seen/worked with multiplayer mods in the past... mostly for games like GTA: San Andreas. I did quite a bit of game-mode writing for SA:MP, and that community has only grown over the years since I've last played. If anything, the existence of a multiplayer mod for the game made the game last longer, as people kept coming back for the experience.

 

I have A LOT of ideas and plans for this mod... and although it will take time, as long as there is support and people want the mod, I'll continue working on it (but at the moment I'll work on it even without support, as I want to play multiplayer in don't starve REALLY bad... having access to the semi-working beta is a huge tease... believe me).

 

To create client-side inventory you just need to add a hash/id of the server (can be done in the name of the file to avoid loading all files searching the server id. Only tries to load the file named with the server id, if it doesn't exists, it's a new player).

This one suited better at first glance, but concerning items ids and sync, it can be messy, as you said. But if server holds the ids of all items, ensuring that the inventory is only loaded for the correct server, ids wouldn't break, I assume..

 

True, using a hash or some kind of server id would work. The problem once again comes down to validating the items in the inventory. Unless the local file is encrypted in some form, it would be simple for a player to open it and change the values. I rather not get into client-side encryption at the moment, and stay focused on base development.

 

At the moment, there are only a few things left to do, but given the fact that it's April, I have finals in the coming weeks, in addition to assignments yet to be finished. The past few days I've been lazy, as for the weekend past, I worked on the mod for 4 days non-stop (I need a break every now and then... given that I'm a computer science major... I often feel glued to my computer).

 

I hope to get some more of the item drops synchronizations done tomorrow... there was a slight issue with the server, in which I have a solution to, but haven't gotten around to implementing yet.

 

With that in mind... I would really like to get another demo video out sometime this weekend. This, of course, depends on how much I get done tomorrow.

 

Don't about me dropping the mod, I have no plans to do so with so much work put into it. I want to see this project get finished.

 

Thanks,

-Crynux

Link to comment
Share on other sites

Hi, glad to know you're interested in the mod.

 

The server is dedicated, it handles all spawns, and manages all ids for mobs/items/players. You're right in saying that there is no login/server chooser. At the moment I'm focused on getting the base game working. Later there will likely be some sort of server chooser or ip address field, but not right now.

 

When the beta goes live, I plan to stress test the server... I want to see how many players it can handle without crashing and without too much lag.

 

Regarding mobs, at the moment the general idea is to have the first player who sees the mob serve the brain; when that player is no longer available, the next 'closest' player will become the brain host. In this way, the whole project is easier as we don't have to recode all of the mob brains on the server; which is written in C. (~3000 lines so far)

 

Don't Starve is a great game, there are no doubts about that. I've seen/worked with multiplayer mods in the past... mostly for games like GTA: San Andreas. I did quite a bit of game-mode writing for SA:MP, and that community has only grown over the years since I've last played. If anything, the existence of a multiplayer mod for the game made the game last longer, as people kept coming back for the experience.

 

I have A LOT of ideas and plans for this mod... and although it will take time, as long as there is support and people want the mod, I'll continue working on it (but at the moment I'll work on it even without support, as I want to play multiplayer in don't starve REALLY bad... having access to the semi-working beta is a huge tease... believe me).

 

 

True, using a hash or some kind of server id would work. The problem once again comes down to validating the items in the inventory. Unless the local file is encrypted in some form, it would be simple for a player to open it and change the values. I rather not get into client-side encryption at the moment, and stay focused on base development.

 

At the moment, there are only a few things left to do, but given the fact that it's April, I have finals in the coming weeks, in addition to assignments yet to be finished. The past few days I've been lazy, as for the weekend past, I worked on the mod for 4 days non-stop (I need a break every now and then... given that I'm a computer science major... I often feel glued to my computer).

 

I hope to get some more of the item drops synchronizations done tomorrow... there was a slight issue with the server, in which I have a solution to, but haven't gotten around to implementing yet.

 

With that in mind... I would really like to get another demo video out sometime this weekend. This, of course, depends on how much I get done tomorrow.

 

Don't about me dropping the mod, I have no plans to do so with so much work put into it. I want to see this project get finished.

 

Thanks,

-Crynux

 

Thank you for the response!

 

I'll follow the project 'til I can! Great job so far and keep going!

Link to comment
Share on other sites

Considering the thing with "followers", I think it would be better to keep there being just 1 Chester so each player has to share him (That's the main reason I want to play Multiplayer, because of all the strained resources.). As for Smallbirds, there would be a way to "gain" the smallbird, causing it to follow you instead. This would allow each player to switch control of the Smallbird.

 

I also have a kind of funny idea, you don't have to add it in if you don't want to, or you could use a .ini file to make it optional. Basically, when a player is below a certain amount of hunger (I am thinking around 10 for most players), they can attack other players. Along with the loot that they normally drop, each player will also drop 8 Monster Meat. Yay for cannibalism. 

 

Oh, by the way, how many players can be in the game at once? Because if there's only two, I can't see the above idea working out all that well.

Link to comment
Share on other sites

I'll definitely be following this mod for quite a while, I've bookmarked it and will be checking daily. ^.^

 

I don't have any "real" coding experience, mostly just adding and changing functions, but I learn fast if it matters to you at all.

 

As for what the person above me (doom) said, I really wouldn't like only having one chester. My main concern about multiplayer would be that there won't be ENOUGH resources for two people to survive reliably, and limiting chester for example isn't in my opinion a very good idea. Of course, after a stable working build is out, an .ini could do the trick.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

Please be aware that the content of this thread may be outdated and no longer applicable.

×
  • Create New...