Deathmatch Spawn Plugin v188.8.131.52
This is a plugin I developed through the need for random spawn points for my other plugin, Nightfire Assassination.
As soon as I work on disabling the relevant logic for whatever mode of map Assassination may start up on, I'll distribute this plugin with it.
See attachments at the bottom of this post. To install from the zip file, which contains the dialogue text, the plugin and some sample spawn files, extract the contents to your orangebox/tf
folder, keeping the file structure intact.
Any bugs you find, let me know. If the server crashes, a crash dump or error log file would be helpful.
What does it do?
If a spawn file is present for the current map, the plugin will move any players that spawn to the spawn points specified in the spawns file, to allow for deathmatch-style spawning. Admins with the appropriate level of authority (those who have config access) can edit the spawn files for maps through this plugin.
What does it not do?
This plugin only handles player spawning; it will not modify the game mode the map is running (apart from allowing access to former enemy spawn rooms, if you so choose). It is the responsibility of other plugins to disable control points and other such map logic if they wish.
ConVars and commands:
- Prohibit spawns from being created if the editing player is crouching. This would stop spawns from being created in places where there is not enough room to stand up. As it is, make sure to only create spawn points in areas where there is enough headroom to stand.
- Speculation: Allow the creation of barricades to limit where players can go on maps that would otherwise be very large for deathmatch games.
will toggle the enabled state of deathmatch respawns.
is the radius around the spawn points within which enemy clients and buildings will be destroyed if a client spawns there. Note that this is a *cheap* checking method in that the radius still takes effect through walls and objects. Default radius is 24 units.
will toggle the display of particle effects at active spawn points. Useful when using the spawn editing commands (see below).
will toggle the enabled state of resupply lockers, respawn rooms and respawn visualizers (the no entry signs) respectively.
will cause all doors in the map to be re-opened once a second (the same way as this works in Vs Saxton Hale) if set to 1. This is to prevent players being able to camp in their team's original spawn room.
will add a spawn point at your current position. Passing "red" as an argument will create the spawn for red; anything else (or no argument at all) will create the spawn for blue.
will remove the spawn you are standing nearest to if no argument is specified; if a number is specified (see dmspawn_dump), the spawn point with the specified number will be removed. If "all" is specified, all spawn points will be removed.
saves all the current spawn points to a file in scripts/dmspawn. Your spawn points will not be saved until you execute this command.
will reload the spawn points from the map's file. Useful if you want to revert immediately to a previous save after making unwanted changes.
will dump all spawn point info to the console. By default all spawn points present in the map will be dumped, but min and max arguments can be specified. For example, dmspawn_dump 5 10 will output information about spawn points 5 to 10. The max value can go higher than the amount of spawn points that are currently present in the map.
How to Edit Spawn Files
In the zip file attached to this post I have included some default spawn files for 2Fort, Junction
and the following KOTH maps: Badlands, Harvest Event, Lakeside, Nucleus, Sawmill
If you wish to create spawn files for other maps, follow these steps:
- Ensure you are a SourceMod admin with permission to modify configs.
- Execute "dmspawn_spawn_markers 1". If any spawn points are currently present in the map they will become visible.
- "dmspawn_add red" will create a Red spawn point where you are currently standing. "dmspawn_add blue" will create a Blue point.
- Once you are finished adding points, "dmspawn_save" will save them to the file. Your points will not be saved until you do this. Switch off spawn markers if you want.
184.108.40.206 - 29/06/12
- Fixed bugs, simplified editing commands.
- Removed queueing behaviour since it seemed superfluous. It may be re-implemented and improved in the future if need be.
v220.127.116.11 - 31/08/11
- Added a queued mode.
- Fixed a code problem that could occur when attempting to remove the most recently placed spawn point.
- Changed admin command permission flags to ADMFLAG_CONFIG (one level above the previous) to better reflect their intended usage.
- Added sounds for extra feedback on actions.
- Method for choosing a spawn point can now be either random or random queued.
-- Random is the same as before, where a point is chosen completely at random.
-- Random queued is a random succession of all the active spawn points. When the ene of the queue is reached, it is reset back to the start.
v18.104.22.168 - 19/08/11
- Initial release.
v22.214.171.124 - http://www.mediafire.com/?yo65tc4bxjalyxm
v126.96.36.199 - http://www.mediafire.com/?m8cabc4d29r2eb1