TShock icon indicating copy to clipboard operation
TShock copied to clipboard

max player/server port/server password aren't configurable in the same manner

Open OnsenManju opened this issue 7 years ago • 7 comments

As mentioned here, these 3 settings are allowed to set at startup (before loading world) and config.json though, these values won't be reflected in the same manner.

(a) max players : will use config value even if you input desired value at startup (it can be overridden by -maxplayers command line option) (b) server port : will use input value at startup, or use config value when -world option is used (but -port option overrides it) (c) server password : won't use any value no matter what you input or set in config

(b) makes sense, but (a) is slightly confusing. (c) looks like a bug.

OnsenManju avatar Jan 09 '17 09:01 OnsenManju

It's worth noting that the precedence we should follow is:

  1. Command line arguments take priority (because those are typically either set at runtime or before the server boots by a GSP).
  2. Interactive options take priority next, because a user at a console should be able to modify their config on the fly if they're booting their server. However, if command line arguments are set, those are respected above all else.
  3. Terraria config options should be taken into account next.
  4. TShock config options should be taken into account last.

hakusaro avatar Jan 10 '17 20:01 hakusaro

@NyxStudios/tshock thoughts on this?

hakusaro avatar Mar 21 '17 02:03 hakusaro

I agree with your earlier comment

QuiCM avatar Mar 21 '17 02:03 QuiCM

I agree with Hakusaro's order of preference, but feel that an important 5th item exists that is merely implied instead of made an explicit part of the specification.

  1. (well, always last) Default settings

mjevans avatar Nov 15 '17 07:11 mjevans

We should probably do this

QuiCM avatar Dec 11 '17 07:12 QuiCM

Is this still relevant?

AxisKriel avatar Oct 22 '18 13:10 AxisKriel

Yes

hakusaro avatar Oct 22 '18 16:10 hakusaro