Ulysses

General => Developers Corner => Topic started by: Zarken on August 18, 2018, 10:02:21 AM

Title: Stop MOTD from Opening for x Seconds?
Post by: Zarken on August 18, 2018, 10:02:21 AM
Is there a way to stop the MOTD from opening on "PlayerInitialSpawn" for x amount of seconds?

I'm looking to code my own spawn menu, and dont want the motd to open till after my menu has closed.

Thanks!
Title: Re: Stop MOTD from Opening for x Seconds?
Post by: JamminR on August 18, 2018, 12:50:12 PM
You could use timer.simple, but that probably isn't best method for waiting. It would be better if you use a method to detect when the close button is pressed. Sorry I can't do the research to link how right now, I'm not at my normal computer setup this week.
Title: Re: Stop MOTD from Opening for x Seconds?
Post by: Zarken on August 18, 2018, 02:13:38 PM
Hey, I only have a timer on the custom spawn menu anyhow, so a timer would be perfect. I just cannot find where to put it :S
Title: Re: Stop MOTD from Opening for x Seconds?
Post by: Zarken on August 21, 2018, 01:04:52 PM
Has anyone got any idea?
Title: Re: Stop MOTD from Opening for x Seconds?
Post by: Timmy on August 22, 2018, 02:08:25 AM

I just cannot find where to put it :S
You want to modify a server-side hook so this would go in a Lua file that runs on the server.
Title: Re: Stop MOTD from Opening for x Seconds?
Post by: JamminR on August 22, 2018, 11:08:13 PM
What Timmy says.  ;)
Sorry, Lane is causing delay to returning to my computer for easy research for you. You're going to have to check his post, gmod wiki, and ulib docs and github code for functions.