• Welcome to SC4 Devotion Forum Archives.

Automatized and synchronized multiplayer region for sc- our questions and ideas.

Started by kbieniu7, May 01, 2016, 03:22:34 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

kbieniu7

Hello there! Once again I've got a question to smart guys moving around this community  ;)

I have an existing region. It is - let's say - 5x5 tiles wide. I need to make it bigger. So, I open config.bmp and enlarge the picture to - let's say - 15x15.



I reopen the game and have a region, that became bigger eastwards and southwards.



But, I need to make it larger in each direction: not only east- and south-, but north- and westwards as well. :-\

I know, that I can create a new region, big enough and shaped appropiately and then import the cities from old region tile by tile. But that takes a lot of time (in reality, my region is not 5x5 like in the example, but 20x15). 

Is it somehow possible? ( Does anybody know something about that? Or, at least, is there any way to speed up importing cities?

Thanks in advance!



Thank you for visiting Kolbrów, and for being for last ten years!

art128

As far as  I know it's not possible to enlarge in all direction, game limitation. However you can move the tiles around in the region view to where you want. (even move them between regions!)  :)
I'll take a quiet life... A handshake of carbon monoxide.

Props & Texture Catalog

kbieniu7

Quote from: art128 on May 01, 2016, 03:52:13 AM
As far as  I know it's not possible to enlarge in all direction, game limitation. However you can move the tiles around in the region view to where you want. (even move them between regions!)  :)

You mean "import city" tool? If so - yes, I know that. But as I mentioned, when I enlarge the region it has around 30x30, it slows down the game (even with no plugins installed). I still can do this, but more time is needed.

Anyway, thanks for help :)
Thank you for visiting Kolbrów, and for being for last ten years!

TheoMarque

My Idea, but will be need to create specific tool:

Cities in region are connected by own borders, for example, we have 4x4 cities region

A B C D
E F G H
I J K L
M N O P


When game loading city K, all cities- G, J, L, O will be loaded too but only into memory without simulation (as file probably).
When game save city K situation as above (dumping memory edited city).
So, Sim City creates virtual region in memory.

Extending example for multiplayer, when someone (1) load city K and someone (2) load city J parallel - game grate big mess. Booth players have in memory state of City (1) J and (2) K. If Player (1) save game - it overwrite neighbour cities - nothing happen wrong now, overwriting not affect to player (2). But when player (2) save city - it simply overwrite progress of city K, because he had in memory previous state of city K.
If virtual regions in players memories are not connected (for example, City A and K are loaded) nothing wrong happen and both players can safely save own progress.

I think, game can write proper connections to region cities when we save progress.
Something about is in the Wiki: http://www.wiki.sc4devotion.com/index.php?title=Region_View_Subfiles

Now, I see the way to create tool to resize and shrinking region without annoying load cities. It - I believe - making door of multiplayer game open wide.

gtaman

your idea is really cool, becasue multyplayer is only thing, which is missed in this game

TheoMarque

Now I work about semi-multiplayer app.
Are two ways of playing, simulation and plop.
Second will be less confusing than first.
Safe simulation is very hard and demand high discipline from players. Not for large public multi-player region.

Second problem, despite sim or plop is Plugins folder integrity. As above, are two ways. All players have identical Plugins and Players have different Plugins.
First situation - is very easy to synchronize and build together.
Second - so... - access to other cites built with other plugins must be restricted.

Other limitation are city borders. Between two players must be "demilitarized zone" size one city "buffer" contain green border (forest for example) or water border (large lake, sea). Yes, I can tell you, that playing on one city two players is not possible when they have different plugins (of course sometimes can be possible but that situation is very rare).

On simcitypolska.pl we try to test that idea and we show our investigation for multilayer simciting.  It will be much easier if we can write region data to savegame directly.

mgb204

Such multiplayer regions have been done before. I honestly don't think it's sensible to approach this, unless all players sharing a region have/use an identical plugins folder, keeping them synchronised. The risks of wiping out the save data otherwise are quite large. One of the worst things you can do is save a city when content previously saved has been removed from your plugins folder.

As for modifying the way the game saves, or simply editing save-game data in any way, I think this is simply not going to be possible. Thus far no one has been able to understand much about the saves for SC4. One thing we do know, they are protected by a checksum. In essence, even if we did understand how to manipulate such data, it would be useless. Because the slightest of edits would invalidate the checksum and cause the game to reject the save when you attempted to load it.

TheoMarque

QuoteOne of the worst things you can do is save a city when content previously saved has been removed from your plugins folder.
I know.
In my idea:
Player use launcher. In launcher he login to OWN portion of region and be able to synchronize OWN plugins folder and only OWN portion od region connected to that plugins folder - is not possible to play with plugins on city deigned with other plugins. Buffer cities are not protected, but when player try to play at buffer region can download and synchronize that buffer city region. What may happen wrong in buffer city? Anything.
Additional protection is rename online part of region which we play. Only after successful synchronize new files will be uploaded and older renamed - deleted. Is not possible to play one portion of region when someone load (locking files to download and operate) citeis. Of course you can load other portion of region which is not connected to portion what are already played.

Editing region data - importing cities and previously generated region.bmp are very repeatable work - some script can do It! Reading from savegame information about place of other cities scriprt can use Sim City4.exe to put proper city to prpoper place. Region Census do this very good, placing PNG data in corret way. For example, python script can do it.

vortext

Quote from: TheoMarque on May 02, 2016, 08:11:15 AM
Player use launcher. In launcher he login to OWN portion of region and be able to synchronize OWN plugins folder and only OWN portion od region connected to that plugins folder - is not possible to play with plugins on city deigned with other plugins.

Things is though, afaik there's no way the launch the game with a portion of the region off limits. Let alone somehow check the city beforehand to see if the content of the plugins folder matches that of the content in the city. If it were possible it'd be a huge breakthrough, not only for multi-play but also single player plugin management.

For Noro we have a reservation system in a private thread, in addition to a little tool whereby we can quickly see who is working on which cities, and consequently which cities are off limits. But again, this is not a bullet-proof system and indeed relies very much on the discipline of the players involved.

Honestly it's not so difficult to setup a multiplayer region through GoogleDrive or Dropbox, as long as everyone involved knows what they're doing and there's good communication - which are pretty much basic requirements for every online multiplayer ever.  :D
time flies like a bird
fruit flies like a banana

TheoMarque

QuoteHonestly it's not so difficult to setup a multiplayer region through GoogleDrive or Dropbox,
This cloud systems have much lag (indexing) on PC when someone change in plugins or save region.

You say - good communication - of course, but no one promise that will by play regular and nothing go wrong.
Every player have  large co-op region on own PC bu synchronize both direction only own cities and other cites are read only. Marking file .sc4 in Regions folder as Read-Only prevent game to overwrite neighbour city (of course if not had administrative privileges).
Before the game launcher (after typing key) download region, on server, rename files to prevent downloading by others, local mark other cities as read-only, and run. In game - play as usual. After game, launcher checks which cities changed and which cites may be upload on server and uploads. Usual player can use only own region and plugins, but when you share your key - you share your plugins and cities.