Raised This Month: $409 Target: $400
 102% 

[TF2] It's Raining Men 0.1 (07/10)


Post New Thread Reply   
 
Thread Tools Display Modes
Author
Jindo
SourceMod Donor
Join Date: May 2009
Location: England, UK
Plugin ID:
1206
Plugin Version:
0.1
Plugin Category:
Fun Stuff
Plugin Game:
Team Fortress 2
Plugin Dependencies:
    Servers with this Plugin:
     
    Plugin Description:
    Spawns ragdolls of random classes + teams at a position relative to a client.
    Old 10-05-2009 , 17:34   [TF2] It's Raining Men 0.1 (07/10)
    Reply With Quote #1

    It's Raining Men v0.1

    Description: This plugin spawns ragdolls of random classes and teams at a height/distance defined by cvars, their spawning location is relative to a live player.

    Screenshots:




    ---

    Usage:

    sm_rainmen: <optional target> - Activates Raining Men, if a target is not specified, the person running the command is used. (Use of @red/@blue/@all is highly discouraged if you want a nice and smooth running server), but just incase:

    sm_rm_panic: - Removes all ragdolls and disables the plugin for 5 seconds.

    sm_rm_stop: - Stops spawning ragdolls but doesn't remove previously spawned ragdolls.

    Both of these commands require the ROOT admin flag, if there is a preference I'm happy to change it.

    CVars: (Default settings should be safe (no insane lagging/crashes))

    rainingmen_version: 0.1 - Current version of the plugin.
    sm_rainmen_enable: 1 - Enable/Disable the plugin (1 = Enabled, 0 = Disabled)
    rm_message_enable: 1 - Enable/Disable the "It's Raining Men" message
    sm_rainmen_radius: 100.0 - Distance around the target to spawn ragdolls
    sm_rainmen_height: 500.0 - Distance above the target to spawn ragdolls
    sm_rainmen_frequency: 1 - Ragdolls to spawn per second (Anything higher than 10 is highly discouraged, higher than 5 discouraged on busy servers)
    sm_rainmen_burn: 2 - Spawn burning ragdolls (0 = off, 1 = on, 2+ = random)
    sm_rainmen_elec: 0 - Spawn electrocuted ragdolls (0 = off, 1 = on, 2+ = random)
    sm_rainmen_remove: 6.0 - Time after a ragdoll has spawned in which it is removed.

    So that above config:

    Code:
    sm_rainmen_enable    1
    rm_message_enable 1
    sm_rainmen_radius    100.0
    sm_rainmen_height    500.0
    sm_rainmen_frequency    1
    sm_rainmen_burn        2
    sm_rainmen_elec        0
    sm_rainmen_remove    6.0
    Should be safe on any server without lag issues. I managed to get as far as having a frequency of 20 without lag on an empty server, but on a full server it is not recommended.

    If you do manage to lag your server to the point that it may crash (due to a high frequency setting most likely), you can use the aforementioned sm_rm_panic to kill the plugin temporarily and restore order.

    The plugin can be used to have a trail of ragdolls following a player, or fall around them, or fall all over the place.

    Code:
    sm_rainmen_radius    2500.0
    sm_rainmen_height    500.0
    The above config would spawn ragdolls pretty much anywhere near to the player (feel free to increase the radius). You could also define the height and radius in map-specific configs to prevent ragdolls getting stuck in the ceilings on certain maps.

    If I made this right, the plugin should auto-created a config containing the default values titled 'plugin.rainingmen.cfg' found in your cfg/sourcemod folder.

    ---

    Version History:

    • Public release


    TO DO:

    • Allow for control over the ragdolls' class/team skins
    • Tidy the code where necessary (if necessary)
    • Perhaps put a video together of it
    • Attach a default config
    • Add an additional argument to the sm_rainmen command to specify the duration of 'human precipitation' (where no argument = permanant until death).


    ---

    I believe that's everything, enjoy the plugin, if there are any huge issues with it, I will attempt to correct them when I can (and of course if there is any thing I'm doing wrong in terms of general SourcePawn scripting, feel free to correct me!)

    (The plugin has been tested and worked successfully on a Linux server running a 1.3 build, and a Windows server running a 1.2.4 build of Sourcemod)

    Have fun!
    Attached Files
    File Type: sp Get Plugin or Get Source (rainingmen.sp - 3141 views - 5.3 KB)
    __________________

    Last edited by Jindo; 12-13-2009 at 10:09.
    Jindo is offline
    emuzombie
    Member
    Join Date: Sep 2009
    Location: Wisconsin, US
    Old 10-05-2009 , 20:35   Re: [TF2] It's Raining Men 0.1 (05/10)
    Reply With Quote #2

    Haha, this looks great, can't wait to try it
    __________________
    emuzombie is offline
    retsam
    Veteran Member
    Join Date: Aug 2008
    Location: so-cal
    Old 10-05-2009 , 20:36   Re: [TF2] It's Raining Men 0.1 (05/10)
    Reply With Quote #3

    Very odd. :p
    retsam is offline
    noodleboy347
    SourceMod Donor
    Join Date: Mar 2009
    Old 10-05-2009 , 21:37   Re: [TF2] It's Raining Men 0.1 (05/10)
    Reply With Quote #4

    This looks cool, a bit strange. Does this lag the server at all, or cause FPS drop?

    And the electric/burning thing looks interesting! Good job!
    noodleboy347 is offline
    Jindo
    SourceMod Donor
    Join Date: May 2009
    Location: England, UK
    Old 10-06-2009 , 02:39   Re: [TF2] It's Raining Men 0.1 (05/10)
    Reply With Quote #5

    Thanks for the comments!

    Quote:
    Originally Posted by noodleboy347 View Post
    This looks cool, a bit strange. Does this lag the server at all, or cause FPS drop?
    As I said in the first post, certain settings (such as a frequency of 10 or higher) can cause massive FPS drop, but a low frequency (1-5) has proven safe on my 28 man server (while full).

    If you do end up with a setting that's too high, I've added the sm_rm_panic command to stop spawning, remove all ragdolls and temporarily disable the plugin for 5 seconds.

    Loading the plugin without a config file will leave you with the default settings, which are intended to be perfectly safe, if you're unsure of what settings to use, I recommend this.
    __________________

    Last edited by Jindo; 10-06-2009 at 02:51.
    Jindo is offline
    Jamster
    Veteran Member
    Join Date: Jun 2008
    Old 10-06-2009 , 06:05   Re: [TF2] It's Raining Men 0.1 (05/10)
    Reply With Quote #6

    Probably the best plugin on SM forums? I think so.
    Jamster is offline
    noodleboy347
    SourceMod Donor
    Join Date: Mar 2009
    Old 10-06-2009 , 22:31   Re: [TF2] It's Raining Men 0.1 (05/10)
    Reply With Quote #7

    Just tried this, it's absolutely awesome! But there's no stop command, besides the panic.

    Is it possible to change the starting animation? They always spawn in the default animation.

    EDIT: Also, a convar to disable to center text? Please? It's funnier when ragdolls randomly start falling on people.

    Last edited by noodleboy347; 10-06-2009 at 22:38.
    noodleboy347 is offline
    Jindo
    SourceMod Donor
    Join Date: May 2009
    Location: England, UK
    Old 10-07-2009 , 02:39   Re: [TF2] It's Raining Men 0.1 (05/10)
    Reply With Quote #8

    Quote:
    Originally Posted by noodleboy347 View Post
    Just tried this, it's absolutely awesome! But there's no stop command, besides the panic.
    I'll add a command for this, glad it's working!

    Quote:
    Is it possible to change the starting animation? They always spawn in the default animation.
    I'll look in to it. (No promises though)

    Quote:
    EDIT: Also, a convar to disable to center text? Please? It's funnier when ragdolls randomly start falling on people.
    No problem at all.

    ---

    I'll add those in later when I get time!

    EDIT: This is untested, but I have no reason to believe that it shouldn't work!

    Changes include:

    • Cvar rm_message_enable (0/1) to enable/disable the center text "It's Raining Men"
    • Command sm_rm_stop which stops the plugin briefly (without removing the ragdolls)
    I'll update the plugin to v0.2 once I've got a few things sorted out.
    Attached Files
    File Type: sp Get Plugin or Get Source (rainingmen.sp - 746 views - 5.1 KB)
    __________________

    Last edited by Jindo; 10-07-2009 at 17:02.
    Jindo is offline
    Spazman0
    Member
    Join Date: Jul 2008
    Old 10-09-2009 , 22:26   Re: [TF2] It's Raining Men 0.1 (07/10)
    Reply With Quote #9

    I think what noodleboy meant was that there is no way to stop it spawning on a certain person, unless the command is a toggle command, in which case can you specify? I'm gonna try to convince the server owner that I play on to load this on, it looks pretty cool.
    Spazman0 is offline
    Jindo
    SourceMod Donor
    Join Date: May 2009
    Location: England, UK
    Old 10-10-2009 , 07:40   Re: [TF2] It's Raining Men 0.1 (07/10)
    Reply With Quote #10

    Ah, so if you switch targets, the previous target is no longer used as a spawn point? I could do that.
    __________________
    Jindo is offline
    Reply


    Thread Tools
    Display Modes

    Posting Rules
    You may not post new threads
    You may not post replies
    You may not post attachments
    You may not edit your posts

    BB code is On
    Smilies are On
    [IMG] code is On
    HTML code is Off

    Forum Jump


    All times are GMT -4. The time now is 09:05.


    Powered by vBulletin®
    Copyright ©2000 - 2020, vBulletin Solutions, Inc.
    Theme made by Freecode