Non real-time multiplayer

Share your ideas about possible future content here.
User avatar
MaxOrlovsky
Settler
Reactions:
Posts: 6
Joined: 17 Oct 2017, 17:44

Non real-time multiplayer

#1

Post by MaxOrlovsky »

Hi.

Before Lobby comes and say that it's a no-no hear me out please :)

I love TheoTown and playing the game for quite some time. I love sim-city games and TheoTown is the best there is! One thing that I miss though is that I would like to play with my wife. I recently introduced her to the game and she played few hours non-stop the first day.

I would like to suggest NON-REAL-TIME multiplayer to the game that shouldn't be hard to implement. As a developer myself I have understanding how everything works and realize that for 1 developer implementing multiplayer is an insanely hard task. And from perspective of the City Simulation game it's stupidly hard in terms of "game mechanic".

But TheoTown have small uniqueness in this regard that makes everything really easy. On a MAP of the world you see different location, where you can start your cities. Those can be manipulated by different people, once at a time. It means that both can't enter same city at the same time and do anything with it. But me and my wife for example can start building nearby cities and when she is offline, I can enter her town and do something with it.
So it's definitely not ideal "online" solution, but for "LAN"-kind multiplayer should be great. That only people with login/password can enter that specific world.

It can work this way:
- Players will need to have login/reg/authentication option, google can be used for that.
- Player 1 set up name/password for a world, where name is the World name. Like Theonia for example - should be unique of course. So first come first serve basis.
- Player 1 level up first location to open up nearby locations
- Player 2+ enter same login/password to enter the same world
- When any Player stop playing or exit city - JSON of that city is sent to server DB and stored there.
- When any Player opens the app - it will synchronize all JSON changes.
- While Players are actively playing - data is synchronized every 30 minutes (and can be changed to 5-10-15-30-60 from settings). With option to on-click synchronization update.
Now here's the tricky and "hard" part:
- When Player 1 enters a city, request should be sent to server DB "locking down" this city, by user-id/session-id/mobile-id or whatever ID is possible to get from Java. I'm no Java/Android expert, sorry.
- Until city is locked, nobody else can join this city.
- In case of a game crash / mobile force turn off city will remain lock until someone from this world won't run synchronization again, if timestamp is > 30 minutes, lock is removed.
- If player leaves a city, lock is removed and JSON sent to server.
- Now in a worse case scenario when 2 players already entered a city and in case of synchronization error. Latest JSON that was sent to server should overrides other ones. So it's up to players, not to mess up each other cities. This can also be used for users who were playing with no internet and then connected to internet - latest JSON is considered "original"

This should be really easy to do. I can even help with API/Synchronization (non-client-app-related) part.
But because data needs to be stored somewhere, even though it's just a "text". It's still take some space and developer need to pay for such server. It can be behind paywall, like 3-5 EUR per world. With possibility to extend world location for additional payment. Like 3 small, 2 medium, 1 large location per additional 1 EUR.
To not make server go crazy, inactive worlds can be removed in 6 months time.
So there wouldn't be DDoS kind of attack on a server, there should be limit of 5 - 10 players per world.

I just love this game and would love to continue playing it as long as possible. And I'm up to help not only with words, but with actions (code) if required :)

User avatar
Mg3094066
Inhabitant of a Supercluster
Reactions:
Posts: 3223
Joined: 28 May 2017, 01:50
Location: Venezuelan Republic of Mexico
Plugins: Showcase Store
Version: Beta

Plugin Creator

Platform

Re: Non real-time multiplayer

#2

Post by Mg3094066 »

No mames, that is impossible

User avatar
MaxOrlovsky
Settler
Reactions:
Posts: 6
Joined: 17 Oct 2017, 17:44

Re: Non real-time multiplayer

#3

Post by MaxOrlovsky »

Mg3094066 wrote:
17 Oct 2017, 19:44
No mames, that is impossible
How come? From technical and game-mechanic perspective It is possible. From time consuming perspective, it shouldn't take long either.
I would genuinely would like to know, why it's impossible?

Online
User avatar
CommanderABab
AB
Reactions:
Posts: 11086
Joined: 07 Jun 2016, 21:12
Plugins: Showcase Store
Version: Beta

Plugin Creator

Platform

Re: Non real-time multiplayer

#4

Post by CommanderABab »

It would be far simpler to just make and send a copy of the region to the other when you are finished playing.

User avatar
MaxOrlovsky
Settler
Reactions:
Posts: 6
Joined: 17 Oct 2017, 17:44

Re: Non real-time multiplayer

#5

Post by MaxOrlovsky »

Would you prefer Google Drive/Dropbox or CD disks to move files back and forth?

If there is an "easier" solution as you stated, it doesn't mean that it's can't be improved. What I ask for is not something unrealistic and shouldn't be hard to implement. There isn't much code-logic required.

User avatar
Josh
Graphic designer
Reactions:
Posts: 2214
Joined: 11 Mar 2017, 19:20
Location: The Netherlands
Plugins: Showcase Store
Version: Beta

Plugin Creator

Platform

Re: Non real-time multiplayer

#6

Post by Josh »

@MaxOrlovsky you can share the city stores, so you and your wife can play the same map ;)

User avatar
Lobby
Developer
Reactions:
Posts: 3705
Joined: 26 Oct 2008, 12:34
Plugins: Showcase Store
Version: Beta

Platform

Re: Non real-time multiplayer

#7

Post by Lobby »

Hi @MaxOrlovsky, I have this idea in mind, too. I think the major problem (besides that I currently have no time) is that a single city file can have multiple mb in size (compressed). So it's not as simple as moving around some small Json files...

User avatar
MaxOrlovsky
Settler
Reactions:
Posts: 6
Joined: 17 Oct 2017, 17:44

Re: Non real-time multiplayer

#8

Post by MaxOrlovsky »

Josh wrote:
18 Oct 2017, 11:12
@MaxOrlovsky you can share the city stores, so you and your wife can play the same map ;)
Can you tell me more please? How to do it? And is it possible not to have the "same" map, but "close-by" maps :)
Lobby wrote:
18 Oct 2017, 11:34
Hi @MaxOrlovsky, I have this idea in mind, too. I think the major problem (besides that I currently have no time) is that a single city file can have multiple mb in size (compressed). So it's not as simple as moving around some small Json files...
Thank you for your answer. I see.
So the problem might be in data transfer? There can be an option for automatic-sync only on WiFi connection. I don't know how hard it is to implement though. This is out of my scope of knowledge, sadly.
Because for the storage, if you put it behind paywall it shouldn't be really a problem as HDD space nowadays don't cost a lot.

If you're busy right now and don't have time, Is there any way to help you practically? Not only spitting out ideas? :)

User avatar
Josh
Graphic designer
Reactions:
Posts: 2214
Joined: 11 Mar 2017, 19:20
Location: The Netherlands
Plugins: Showcase Store
Version: Beta

Plugin Creator

Platform

Re: Non real-time multiplayer

#9

Post by Josh »

@MaxOrlovsky if you go to your internal storage and then to theotown there is a folder called "maps" with all the saved city stores. You can send these stores to you wife to play the same map. It's not efficient but you can still use it.

And about helping Lobby, you can create graphics for theotown if they have the quality of theo's buildings (Who was the graphic designer a long time, but stopped) But I can tell you it takes a lot of your time, it can be fun if you like it :D

You can find theo's buildings here: http://www.theotown.com/forum/viewtopic ... &start=325

User avatar
MaxOrlovsky
Settler
Reactions:
Posts: 6
Joined: 17 Oct 2017, 17:44

Re: Non real-time multiplayer

#10

Post by MaxOrlovsky »

I suck as designer :D I can code though.
Thank you for explaining how it work.

User avatar
Josh
Graphic designer
Reactions:
Posts: 2214
Joined: 11 Mar 2017, 19:20
Location: The Netherlands
Plugins: Showcase Store
Version: Beta

Plugin Creator

Platform

Re: Non real-time multiplayer

#11

Post by Josh »

MaxOrlovsky wrote:
18 Oct 2017, 18:33
I suck as designer :D I can code though.
Thank you for explaining how it work.
We have coders enough, unless you are really good with java

User avatar
MaxOrlovsky
Settler
Reactions:
Posts: 6
Joined: 17 Oct 2017, 17:44

Re: Non real-time multiplayer

#12

Post by MaxOrlovsky »

Nope, I'm afraid not :)

Thanks again for answers.

Post Reply Previous topicNext topic

Return to “Suggestions”