Jump to content

Improvements for the dedicated server


Alloc

Recommended Posts

I just noticed and i dont know how long its broken, checked it last time during A16:

 

My hooks are broken.

the chat hook for example passes the instance name but all other values are empty.

playerConnect works fine.

Anyone got an idea?

This mod does not have any hooks. If you're talking about the Linux scripts please use the appropriate thread, you will probably get more help there :)

 

 

@alloc Is there a way to add our own permission to be used in the webpermission.xml file ?

 

It would be handy for when adding new stuff to the map, like the earlier mentioned traders locations, so you have your own specific permission setting for that instead of having to use one of the already defined once?

Currently not without changing and recompiling the mod's code yourself.

Link to comment
Share on other sites

@alloc I found an bug with v18_21_31 and a17.2 b27 stable

 

Before the stable (a17.2 b20 experimental) I was able to set the web permissions to 2000 so everyone that's not logged in could see the map.

 

With the current version I can still set the permissions to 2000, but when I try logging in via the steam login, it looks like it's logging in, but once returning to the map, it shows as not logged in.

 

Occasionally it does show me as logged in, but once I refresh the browser, I'm logged out again.

 

If I change the permissions back to 1000, everything works fine and I stay logged in, even on browser refresh.

 

EDIT:

Just noticed some times it logs me out when permissions are set to 1000 and I refresh the browser, so it not just with the permissions set to above 1000

Edited by Satis
More info (see edit history)
Link to comment
Share on other sites

With the current version I can still set the permissions to 2000, but when I try logging in via the steam login, it looks like it's logging in, but once returning to the map, it shows as not logged in.

 

Occasionally it does show me as logged in, but once I refresh the browser, I'm logged out again.

 

If I change the permissions back to 1000, everything works fine and I stay logged in, even on browser refresh.

 

EDIT:

Just noticed some times it logs me out when permissions are set to 1000 and I refresh the browser, so it not just with the permissions set to above 1000

There's basically two things that make you lose your login status: Your (server facing) IP changes (e.g. by getting a new one assigned from your ISP on a reconnect) or your browser forgets the cookie with the session ID. Of course if the server is restarted you also have to relogin.

 

 

Hey Alloc,

i like your server fixes!

I hope you will release a version that is compatible with 17.2 stable :-)

Doesn't look like there's an issue with the current ones and 17.2.

Link to comment
Share on other sites

@alloc That was it...... totally forgot that I had ZenGuard running in the background that was preventing this.

 

Oh and I can confirm the Allocs Server Fixes v18_21_31 works on a17.2 b27 with no issue on my end now.

Link to comment
Share on other sites

  • 3 weeks later...

I made a wrapper around the web API a while ago. I just updated it to v1.3.1 to support the new 'count' parameter in the getLog endpoint. This will work in a browser or on a server (nodejs). It's written in Typescript so you will get intellisense on the responses in most IDEs.

 

Maybe it'll be useful for someone ^^

 

https://github.com/CatalysmsServerManager/7-Days-to-Die-API-wrapper

Link to comment
Share on other sites

@Annihlator

I used the map.js provided (and tried the one from Prisma), added a cart.png to the images folder, verified permissions and I copied the prefabs.xml from folder into webserver folder but there is still no icon.

I am obviously not sane, could you please provide some more detail what step I could have missed or done wrong?

 

Nvm, probably a rights or size problem. Got a 32x32 cart.png and made sure it had the same rights as the others and now it seems to work...

Edited by Dirtylobster (see edit history)
Link to comment
Share on other sites

  • 3 months later...

Hm, yeah, basically it's not much of an issue, just has to be configurable ... And configuration is something I wanted to wait on til I can provide some generic storage for mods in 7dtd so it's not like it is now with everyone using his own stuff :D

I'll see about some simpler solution for now and get that added, but *most likely* not within the next two weeks.

Link to comment
Share on other sites

Hm, yeah, basically it's not much of an issue, just has to be configurable ... And configuration is something I wanted to wait on til I can provide some generic storage for mods in 7dtd so it's not like it is now with everyone using his own stuff :D

I'll see about some simpler solution for now and get that added, but *most likely* not within the next two weeks.

 

That's cool! No hurry or anything. For now, I've got a little hack in place that proxies the commands through an API I control so I bypass CORS :p

 

Since I'm a bit further in my app now, I think that browser requests to the API will fail anyway because of mixed content (app is served through https but 99% of server maps aren't available over SSL).

 

Thanks for replying ^^

Link to comment
Share on other sites

  • 1 month later...

Hey Alloc. I was curious - what's the limiting factor keeping this on .NET 2.0/3.5? There's a lot of cool libraries I'd like to use in mods going forward, but the mod loader cannot "iterate over the types" in a .NET 4.0 mod because of 2.0->4.0 compatibility. 4.0 can load in 2.0 modules but not the other way around.

Link to comment
Share on other sites

There's a lot of cool libraries I'd like to use in mods going forward,

Me too ;)

 

I was curious - what's the limiting factor keeping this on .NET 2.0/3.5?

The game running on .NET 3.5 up to A17. A18 will finally run on .NET 4.5.

Link to comment
Share on other sites

NICE! I like your built-in server and all, and seriously - props to you for writing it, because I started writing my own before I saw you already did it, but I'd really like to use my .NET WebAPI controllers with the .NET self-host and Newtonsoft.Json. There's a lot of nice libraries we can finally use now! Thanks!

Link to comment
Share on other sites

  • 4 weeks later...

I have one question for the "hooks" section of your tools, Alloc.

 

As stated in the screenshots the hook files have to be in the hooks folder in the SDTD_BASE folder. Which one is that ? Im a bit lost since there is no folder named like this and i have no example folder to put stuff in.

 

Hooks are a way to add additional behaviour to the scripts. They are basically custom scripts that are called upon specific events. For example one could define a hook which is called on player connects and then send a message in the in-game chat to greet the new player.

 

All hooks have to executable files that are either placed in SDTD_BASE/hooks/<name of hook>/<any name>.sh for global hooks that apply to all instances or SDTD_BASE/instances/<name of instance>/hooks/<name of hook>/<any name>.sh for hooks that only apply to that specific instance. The folder <name of hook> has to be in exactly the same case as the hook name column in the table below shows it.

 

If you want to use the functions of the management scripts in your hook you can add this to the start of your script:

 

I just want to make an automated message before server restart happens.

 

PS: or is it possible to do that via cronjob too ?

Edited by Sam_Neill (see edit history)
Link to comment
Share on other sites

  • 4 weeks later...

Getting a server setup for the A18 release.

Tried to look back a few posts to see if this was discussed, so sorry if it has been answered / asked.

 

Do you have a day 0 release for when A18 experimental comes out, or know if the present build works with the internal A18 build?

 

Thanks for your your time and insight.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...