.:: Bots United ::.

.:: Bots United ::. (http://forums.bots-united.com/index.php)
-   Half-Life 1 SDK (http://forums.bots-united.com/forumdisplay.php?f=33)
-   -   [CZ/CS]Map specific MOTD.txt? (http://forums.bots-united.com/showthread.php?t=4230)

Rusty Le Cyborg 19-07-2005 21:36

[CZ/CS]Map specific MOTD.txt?
 
Hi there

Just thinking out loud here, but as I have been playing with Lazy's Model Changer Plugin I wondered if the above could be possible.

What I envisaged was an MOTD which would display the map overview and the models used in the map (using HTML obviously). The problem with the "mapname".txt file in the maps directory is that it doesn't seem to support HTML :(

Has one of these ever been made? I saw some sort of MOTD stuff mentioned in AMXMod, but I don't think it is map specific.

Any ideas would be much appreciated. Especially if somoene knows how to do it using the mapname.txt files... :D

Cheers for now

Lazy 19-07-2005 21:50

Re: [CZ/CS]Map specific MOTD.txt?
 
I think you can do this without any plugins, taking a look at the sdk shows that it opens up the motd with the path in the "motdfile" cvar.
All you'd need to do is change it in the map's cfg file, like ...

motdfile "maps/assault_motd.txt"

Rusty Le Cyborg 19-07-2005 22:06

Re: [CZ/CS]Map specific MOTD.txt?
 
Oh right. So this would be added to the server.cfg file? (or listenserver.cfg...)

Lazy 19-07-2005 22:12

Re: [CZ/CS]Map specific MOTD.txt?
 
Well, I think it loads map configs automatically.
Like maps/MAPNAME.cfg

Rusty Le Cyborg 19-07-2005 22:15

Re: [CZ/CS]Map specific MOTD.txt?
 
Hmm.. interesting... I shall try it out :) Thanks!!!

Rusty Le Cyborg 20-07-2005 00:10

Re: [CZ/CS]Map specific MOTD.txt?
 
Couldn't get this to work, but checking on Google it seems that this is actually for Source only and may be a command line only option...

Could be wrong though...

Lazy 20-07-2005 00:15

Re: [CZ/CS]Map specific MOTD.txt?
 
Hmm, I'll see if this can be done once I finish writing a plugin for someone else ( small bugfix ).

Rusty Le Cyborg 20-07-2005 00:40

Re: [CZ/CS]Map specific MOTD.txt?
 
Cool. In the past I had used Environskin to do the skin changing, but this also uses the botprofile.db etc. and has the entity limit problem as detailed in the other thread.

What it does is puts cfg.dll which runs a "mapname".cfg file as a "listenserver".cfg file. I am not sure if this could be used as a Metamod plugin, but I doubt it.

It was actually written by Splorygon I believe.

From his readme : czero/dlls/cfg.dll:
executes .cfg's with the same name as the
loading map. ex: server executes <map>.cfg on
level change, which contains console commands.
See czero/de_dust_cz.cfg in notepad for details.
Also includes custom czero/liblist.gam to direct
the game to load cfg.dll


So I don't think it can be used instead of mp.dll when Metamod is in use... :(

Now, if there was a plugin similar to the model_changer one you made, which made motd.txt into maps/mapname_motd.txt, then maybe it would work. I honestly don't know.

Thanks for any help you may be able to give!

Lazy 20-07-2005 00:43

Re: [CZ/CS]Map specific MOTD.txt?
 
Since its only one file and I know how it's opened it should be possible to do, I'll have a look once I get this other plugin tested and sent out.

Lazy 20-07-2005 01:21

Re: [CZ/CS]Map specific MOTD.txt?
 
1 Attachment(s)
Allright, I have done some basic testing and this plugin works.
What you need to do is create a new directory in your mod root folder called "motd".
Then, in that directory create files called mapname.txt for the maps where you want custom motds.

These work in the exact same way, meaning you can have the contents as a url and it will load a web page or just plain text.
If there is no matching file in the motd directory the default motd pointed to by the "motdfile" cvar will be used.


All times are GMT +2. The time now is 20:09.

Powered by vBulletin® Version 3.8.2
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.