AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Plugins (https://forums.alliedmods.net/forumdisplay.php?f=108)
-   -   [ANY] HTTP Text MOTD (https://forums.alliedmods.net/showthread.php?t=229395)

Dr. McKay 11-06-2013 21:09

[ANY] HTTP Text MOTD
 
[ANY] HTTP Text MOTD

v1.0.1

Description:
On startup, downloads a file via HTTP and uses it as the server's text MOTD (for those who have HTML MOTDs disabled).

Cvars:
  • motd_text_version - plugin version
  • motd_text_auto_update - enables automatic updating (has no effect if Updater is not installed)
  • motd_text_host - host to download file from (domain or IP)
  • motd_text_port - port your HTTP server is running on (defaults to 80)
  • motd_text_path - path to request the file from on your server (defaults to /)
  • motd_text_write_file - if 1, also writes the content of the downloaded file to motd_text.txt (defaults to 1)

Plugin creates and loads cfg/sourcemod/plugin.motd_text_http.cfg.

Commands:
  • sm_motd_text_redownload - redownloads the file specified by the cvars, restricted to root by default

Requirements:
Requires the Socket extension.

Installation:
Install Socket if you don't have it already, put motd_text_http.smx into /addons/sourcemod/plugins, type "sm plugins load motd_text_http" into your console or rcon, set your cvars in cfg/sourcemod/plugin.motd_text_http.cfg, and reload the plugin ("sm plugins reload motd_text_http").

Auto Update:
Install Updater. The plugin will be auto-updated according to your Updater settings. It'll work without Updater.

Changelog:
  • v1.0.0 (11/6/13)
    • Initial release

Download Plugin (motd_text_http.smx)
View Source (motd_text_http.sp)


Requires updater.inc, socket.inc, and mckayupdater.sp to compile.

nineteeneleven 11-06-2013 21:19

Re: [ANY] HTTP Text MOTD
 
Wow that was fast. Thanks

KyleS 11-06-2013 21:25

Re: [ANY] HTTP Text MOTD
 
I'm not that familiar with the Socket API, but it looks like you leak the Socket if everything works.

Dr. McKay 11-06-2013 22:04

Re: [ANY] HTTP Text MOTD
 
Quote:

Originally Posted by KyleS (Post 2057766)
I'm not that familiar with the Socket API, but it looks like you leak the Socket if everything works.

Good catch, fixed.

Ixel 11-07-2013 05:31

Re: [ANY] HTTP Text MOTD
 
Useful plugin, although quickly approved too I noticed (in comparison to other plugins).

napalm00 11-07-2013 05:40

Re: [ANY] HTTP Text MOTD
 
Quote:

Originally Posted by Ixel (Post 2057854)
although quickly approved too I noticed (in comparison to other plugins).

You'll get used to it :3

404UserNotFound 11-08-2013 03:28

Re: [ANY] HTTP Text MOTD
 
Quote:

Originally Posted by napalm00 (Post 2057855)
You'll get used to it :3

I have. We have numerous wonderful plugins sitting in New Plugins waiting to be reviewed/approved, and this gets approved because it was made by the magical Doctor McKay :P

I'm totally ok with this.

Powerlord 11-08-2013 14:16

Re: [ANY] HTTP Text MOTD
 
Quote:

Originally Posted by napalm00 (Post 2057855)
You'll get used to it :3

In a way I'm glad you said that, because it gives me a chance to vent about it.

Getting used to it and blindly accepting it are two different things.

For instance, I've had two sitting in New Plugins marked "Waiting for Review" since April and May respectively. One is somewhat complicated and in theory could take time to check. The other is a simple player_death hook that checks some values and calls inputs on the player entity.... it's an example of how to manipulate the TF2 Player Response system; in theory the system works in all games that use SpeakResponseConcept on the player entity.

(Incidentally, I found out that the latter plugin's two sibling plugins weren't marked as ready for review... whoops)

KyleS 11-08-2013 14:29

Re: [ANY] HTTP Text MOTD
 
Quote:

Originally Posted by Powerlord (Post 2058456)
In a way I'm glad you said that, because it gives me a chance to vent about it.

If it's an exploit fix to me that's a pretty high priority. If Valve destroys an existing method, and is a fix for keeping relevant existing behaviour active, that's the same to me. If they're marked as ANY I go through that list and let some cook for a bit. I definitely don't feel qualified to review most TF2/L4D(2) plugins from time to time as I don't know what's going on as there's significant game-isms. I'm sure every Approve-r has their things.


If anyone is qualified, please check this thread.

Venting about this in McKay's thread isn't great, for instance.

friagram 11-11-2013 10:37

Re: [ANY] HTTP Text MOTD
 
I have had stuff marked for ages, and no comment. It doesn't really matter though, except for the fact that the version tracking convar and link for deps dont work. You guys should fix this, so new plugins can have tracking/deendency links (but not unapproved).


All times are GMT -4. The time now is 04:39.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.