Multiplayer only mods

Place to post guides, observations, things related to modding that are not mods themselves.
hangwire
Manual Inserter
Manual Inserter
Posts: 3
Joined: Thu Mar 31, 2016 1:17 pm
Contact:

Multiplayer only mods

Post by hangwire »

Hello,

First of all ... I bought Factorio some days ago and absolutely love it. It is a dream for engineer geeks that love to optimize things.

I started playing around with the mod api and noticed that there is no possibility for server-only mods. When the server decides to destroy an entity the client gets disconnected because it is not synced. Will there be a future release where the server can send ticks or updates to the client? This could make Anti-Griefing mods a lot easier to do.

At this moment I could only think of a very hard to implement solution (the server sends orders to the client via json or sth.).

I also noticed that you can't uniquely identify a user because everybody is able to change his multiplayer username. Could you please add an unique identifier to the player object?

I think both things could offer the community to make the game even better!

Greetings,

hangwire
Rseding91
Factorio Staff
Factorio Staff
Posts: 14806
Joined: Wed Jun 11, 2014 5:23 am
Contact:

Re: Multiplayer only mods

Post by Rseding91 »

There is no concept of a "server" or "client" with the multiplayer model we use. Only peers. All peers are required to run the same set of mods in order for multiplayer to work.

The name "Dedicated server" should really be "Dedicated Peer" but at this point it's too late to change it :)

As for the identifying of players: that's planned for 0.13.
If you want to get ahold of me I'm almost always on Discord.
hangwire
Manual Inserter
Manual Inserter
Posts: 3
Joined: Thu Mar 31, 2016 1:17 pm
Contact:

Re: Multiplayer only mods

Post by hangwire »

So it is not possible for the "dedicated peer" to act alone (e.g. destroy an entity) but all peers must have the same decision to get in sync? That sounds like mods will never be able to keep someone from griefing?
User avatar
DaveMcW
Smart Inserter
Smart Inserter
Posts: 3731
Joined: Tue May 13, 2014 11:06 am
Contact:

Re: Multiplayer only mods

Post by DaveMcW »

hangwire wrote:That sounds like mods will never be able to keep someone from griefing?
You can force everyone to install the same mod to join your server. (In 0.13 clients will auto-download the correct mods.) If a griefer tries to edit your mod they will be desynced.

I believe there is a way for mods to discriminate between players. For example, only player 1 is allowed to use the destroy entity command.
hangwire
Manual Inserter
Manual Inserter
Posts: 3
Joined: Thu Mar 31, 2016 1:17 pm
Contact:

Re: Multiplayer only mods

Post by hangwire »

Yes maybe, but it is not possible to have a database with user information on one side. It must be synced to all peers right?
Post Reply

Return to “Modding discussion”