Jump to content
Sign in to follow this  

[L4D & L4D2] Christmas Tree (1.0) [07-Nov-2019]

Recommended Posts


  • Dragokas for the idea and request, L4D1 saved spawn data and lots of help testing.

  • Spawn single gifts or trees either temporary or saved to the map.
  • Gifts can break and spawn an item or weapon.
  • L4D is missing the L4D2 gift model and uses a crate.
  • Aim at the Gnome to delete, edit position and angles. The tree is non-solid.
  • Maximum of 2 trees per map. Gifts are limited to 32. Recompile to change limits.
  • Trees (with default settings) use approx 45 entities (2 models + 6 gifts + 1 spark + 4 lights + 32 sprites). On explosion about 8 temporary entities.
  • It's not a CPU intensive plugin for the server. Rainbow option will increase bandwidth slightly.
  • Optionally adds dissolve effects to gifts when detecting l4d_dissolve_infected.txt gamedata. Can be disabled with l4d_tree_effects cvar.
  • This plugin is large because of the effects stocks, spawning capability and all the options with that.
  • Fully handles late loading, unloading, turning on/off and deletes unused items.
  • Recommended additional plugins: Neon Beams for decorations. Weather Control or xMas for snow.
  • Optional data config provided with trees saved to every Valve map. Thanks to "Dragokas" for the L4D1 data.

Gifts Drop Chances:
  • Weighted chance for item and weapon selection on gift breaking.
  • L4D1 auto ignores chances for L4D2 items and weapons.
  • Each value in the l4d_tree_items cvar represents the chance of each specific item or weapon dropping from 0 to 100%.
  • The order is as follows, includes example cvars for no weapons:

Admin Commands: (requires "z" flag)

PHP Code:

sm_tree_spawn    // Spawns a temporary Gift/Tree at your crosshair. Usage: sm_tree_spawn [type: 0=Gift. 1=Tree.]
sm_tree_save     // Spawns a Gift/Tree at your crosshair and saves to config. Usage: sm_tree_save [type: 0=Gift. 1=Tree.]
sm_tree_del      // Removes the Gift/Tree you are pointing at and deletes from the config if saved.
sm_tree_clear    // Removes all Gifts/Trees spawned by this plugin from the current map.
sm_tree_wipe     // Removes all Gifts/Trees from the current map and deletes them from the config.
sm_tree_reload   // Resets the plugin and reloads the data config and saved spawns.
sm_tree_glow     // Toggle to enable glow on all Gifts/Trees to see where they are placed.
sm_tree_list     // Display a list Gift/Tree positions and the total number of.
sm_tree_tele     // Teleport to a Gift/Tree (Usage: sm_tree_tele <index: 1 to MAX_SPAWNS (32)>).
sm_tree_ang      // Displays a menu to adjust the Gift/Tree angles your crosshair is over.
sm_tree_pos      // Displays a menu to adjust the Gift/Tree origin your crosshair is over. 


Saved to l4d_christmas_tree.cfg in your servers \cfg\sourcemod\ folder.

PHP Code:

l4d_tree_allow           "1"          // 0=Plugin off, 1=Plugin on.
l4d_tree_modes           ""           // Turn on the plugin in these game modes, separate by commas (no spaces). (Empty = all).
l4d_tree_modes_off       ""           // Turn off the plugin in these game modes, separate by commas (no spaces). (Empty = none).
l4d_tree_modes_tog       "0"          // Turn on the plugin in these game modes. 0=All, 1=Coop, 2=Survival, 4=Versus, 8=Scavenge. Add numbers together.
l4d_tree_ball_count      "8"          // How many balls to display per column.
l4d_tree_ball_columns    "4"          // How many columns of balls to display.
l4d_tree_ball_radius     "45.0"       // Distance from the tree base to display balls
l4d_tree_col_gift        "255 0 0"    // Gift color. 0=Off (default Gift color). Three values between 0-255 separated by spaces. RGB: Red Green Blue.
l4d_tree_col_tree        "0 255 0"    // Tree color. 0=Off (default Tree color). Three values between 0-255 separated by spaces. RGB: Red Green Blue.
l4d_tree_effects         "15"         // 0=Off. 1=Lights, 2=Balls, 4=Sparks, 8=Dissolver, 15=All. Add numbers together.
l4d_tree_gifts           "6"          // How many packages to spawn under the tree.
l4d_tree_items           "80,100,25,25,25,40,15,15,15,2,2,2,5,5,5,2,5,1,1,2,0,2,5,0,0,2,0,5,1" // Item chance. See above for details.
l4d_tree_glow            "255 0 0"    // 0=Off. L4D2 only: glow outline on gifts. Three values between 0-255 separated by spaces. RGB: Red Green Blue.
l4d_tree_health          "1"          // 0=Does not break or drop items. Health of gifts before they can break and drop items.
l4d_tree_rainbow         "2"          // 0=Off. 1=Gifts change color over time. 2=Trees change color over time. 3=Both
l4d_tree_rate            "10"         // How fast the color changes when using rainbow option.
l4d_tree_speed           "0.2"        // How often to update the colors per second.
l4d_tree_version                      // Christmas Tree plugin version. 


1.0 (07-Nov-2019)
    - Initial release.

  1. Click "Get Plugin" and put the .smx file into your servers \addons\sourcemod\plugins\ folder.
  2. Optionally download "l4d_christmas_tree.cfg" and save to your servers \addons\sourcemod\data\ folder. This has trees saved to every Valve map.

Attached Files
File Type: cfg l4d_christmas_tree.cfg (13.0 KB)
File Type: sp Get Plugin or Get Source (l4d_christmas_tree.sp - 61.0 KB)

Wyświetl pełny artykuł

Share this post

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Similar Content

    • By MYGO.pl
      Related Plugins:[ANY] Dev Cmds [ANY] Input Hooks [ANY] TempEnt Hooks [ANY] UserMsg Hooks

      About:Prints Temp Entities data to chat (client) or console (server). Can specify which TempEnts to listen for or filter out. Example command: sm_te_watch "Dynamic Light,Sprite" For more info on TempEnts: https://wiki.alliedmods.net/TempEnts...eMod_SDKTools)

      TempEnts Listhttps://wiki.alliedmods.net/Mod_TempEnt_List_(Source) Or command: sm_print_telist.

      Admin Commands: (requires "z" flag)

      PHP Code: sm_te_listen    // Starts listening to all TempEnts. Filters or listens for TempEnts using the filter and listen cvars.
      sm_te_stop      // Stop printing TempEnts.
      sm_te_watch     // Start printing TempEnts. Usage: sm_tempent_watch <TempEnt names to watch, separate by commas> 


      Saved to tempent_hooks.cfg in your servers \cfg\sourcemod\ folder.

      PHP Code: // Do not hook and these TempEnts, separate by commas (no spaces). Only works for sm_te_listen command.
      sm_tempent_filter "Footprint Decal,Blood Stream"

      // Only hook and display these TempEnts, separate by commas (no spaces). Only works for sm_te_listen command.
      sm_tempent_listen ""

      // 0=Off. 1=Log TempEnts data when listening.
      sm_tempent_logging "0"

      // TempEnt Hooks plugin version.

      Code: 1.0 (15-Oct-2019)
          - Initial release.

      Installation:Click "Get Plugin" and put the .smx file into your servers \addons\sourcemod\plugins\ folder.
      Attached Files Get Plugin or Get Source (tempent_hooks.sp - 11.2 KB) Wyświetl pełny artykuł
    • By MYGO.pl
      Related Plugins:[ANY] Dev Cmds [ANY] Input Hooks [ANY] TempEnt Hooks [ANY] UserMsg Hooks

      About:Prints UserMessage data to chat (client) or console (server). Logs UserMessages structure and output data. Can specify which UserMessages to listen for or filter out. Example command: sm_um_watch "MusicCmd,TextMsg" For more info on UserMessages: https://wiki.alliedmods.net/User_Messages Auto generates up to 19 gamedata signatures! They should never break and support most games. Logs messages to: "logs/user_messages_dump.log" Logs structures to:"logs/user_messages_types.log"

      Example Output:
      Example Data:
      PHP Code: UM: Fade/7:10:81920: [256] [0] [1] [255] [0] [0] [30]
      USERMSG: Adding new format entry for MeleeSlashSplatter/1:1:16384
      UM: MeleeSlashSplatter/1:1:16384: [2]
      UM: Damage/2:8:2048: [0] [0]
      UM: KillCam/3:3:16384: [0] [0] [0]
      USERMSG: Adding new format entry for PZDmgMsg/5:9:81920
      UM: PZDmgMsg/5:9:81920: [15] [3] [2] [0] [0]
      UM: ResetHUD/1:1:16384: [0]
      UM: Spawn/1:1:16384: [3]
      UM: Splatter/1:1:16384: [10]
      UM: Splatter/1:1:16384: [9]
      UM: SplatterClear/0:0:0:
      UM: Train/1:1:16384: [0]
      UM: VGUIMenu/3:3:17408: [overview] [0] [0]
      UM: VGUIMenu/3:3:17408: [specgui] [0] [0]
      UM: VGUIMenu/3:3:17408: [specgui] [1] [0]
      UM: VGUIMenu/3:3:17408: [specmenu] [0] [0]
      UM: VGUIMenu/3:3:17408: [takeover_survivor_bar] [0] [0] 
      Example Structures:
      PHP Code: "usermessages"
                  "1"        "WRITE_BYTE"
                  "2"        "String"
                  "3"        "String"
                  "4"        "String"
                  "5"        "String"
                  "6"        "String"
                  "1"        "String"
                  "2"        "WRITE_BYTE"
                  "3"        "WRITE_BYTE"
                  "1"        "WRITE_BYTE"
                  "2"        "WRITE_BYTE"
                  "3"        "WRITE_BYTE"
                  "1"        "WRITE_SHORT"
                  "2"        "WRITE_SHORT"
                  "3"        "WRITE_SHORT"
                  "4"        "WRITE_BYTE"
                  "5"        "WRITE_BYTE"
                  "6"        "WRITE_BYTE"
                  "7"        "WRITE_BYTE"

      Known Working Games:L4D1 L4D2 Please report success in other games. Request support if required.

      Unsupported Games:CSGO (method is different, requires manual hooks and/or changes)

      Admin Commands: (requires "z" flag)

      PHP Code: sm_um_listen    // Starts listening to all UserMessages. Filters or listens for messages from the filter and listen cvars.
      sm_um_stop      // Stop printing UserMessages.
      sm_um_watch     // Start printing UserMessages. Usage: sm_um_watch <messages to watch, separate by commas> 


      Saved to usermsg_hooks.cfg in your servers \cfg\sourcemod\ folder.

      PHP Code: // Do not hook and these UserMessages, separate by commas (no spaces). Only works for sm_usermsg_listen command.
      sm_usermsg_filter ""

      // Only hook and display these UserMessages, separate by commas (no spaces). Only works for sm_usermsg_listen command.
      sm_usermsg_listen ""

      // 0=Off. 1=Logs all UserMessage structures. 2=Log listen UserMessage data. 4=Log listen UserMessage data with timestamps. Add numbers together.
      sm_usermsg_logging "1"

      // UserMsg Hooks plugin version.

      Code: 1.0 (15-Oct-2019)
          - Initial release.

      Requirements:Extension: DHooks (Experimental dynamic detour support)

      Installation:Download the .smx file and put into your servers \addons\sourcemod\plugins folder. Download the .txt gamedata file and put into your servers \addons\sourcemod\gamedata\ folder.
      Attached Files Get Plugin or Get Source (usermsg_hooks.sp - 23.9 KB) usermsg_hooks.games.txt (4.5 KB) usermsg_hooks.smx (15.0 KB) Wyświetl pełny artykuł
    • By MYGO.pl
      About:For years I thought it was strange a Tank or infected could catch fire and indefinitely burn to death. This plugin changes that by extinguishing players after a specified amount of time.


      Saved to l4d_witch_damage.cfg in your servers \cfg\sourcemod\ folder.

      PHP Code: // Which Special Infected to affect: 1=Smoker, 2=Boomer, 4=Hunter, 8=Spitter, 16=Jockey, 32=Charger, 63=All. Add numbers together
      l4d_burn_duration_infected "63"

      // 0.0=Game default. How long Special Infected stay ignited.
      l4d_burn_duration_special "1.0"

      // 0.0=Game default. How long the Tank stays ignited.
      l4d_burn_duration_tank "3.0"

      // 0.0=Game default. How long the Witch stays ignited.
      l4d_burn_duration_witch "4.0"

      // 0=Plugin off, 1=Plugin on.
      l4d_burn_duration_allow "1"

      // Turn on the plugin in these game modes, separate by commas (no spaces). (Empty = all).
      l4d_burn_duration_modes ""

      // Turn off the plugin in these game modes, separate by commas (no spaces). (Empty = none).
      l4d_burn_duration_modes_off ""

      // Turn on the plugin in these game modes. 0=All, 1=Coop, 2=Survival, 4=Versus, 8=Scavenge. Add numbers together.
      l4d_burn_duration_modes_tog "0"

      // Burn Duration plugin version.

      Code: 1.0 (11-Nov-2019)
          - Initial release.

      Installation:Click "Get Plugin" and put the .smx file into your servers \addons\sourcemod\plugins\ folder.
      Attached Files Get Plugin or Get Source (l4d_burning_duration.sp - 9.4 KB) Wyświetl pełny artykuł
    • By MYGO.pl
      Unlocks the Spitter Acid to damage common and special infected. The games default behaviour alternates between 0.2 and 0.3 seconds to damage entities. The game scales damage over the duration of effect: 0 at the start, 6 in the middle and 4 when it ends. This plugin can scale that damage where 1.0 is default, or set a full value to damage each time (this plugins default for common and special infected). Also included in the source for developers a demonstration on "inferno" entities and getting their flame positions.

      Thanks:Iizuka07 - For the idea and request. Lux - For scripting advice.


      Saved to l4d2_spitter_acid_damage.cfg in your servers \cfg\sourcemod\ folder.

      PHP Code: l4d2_spitter_acid_allow "1"             // 0=Plugin off, 1=Plugin on.
      l4d2_spitter_acid_damage "2"            // Apply full damage value from dmg_* cvars. Or: use a ratio of the games scaled damage on: 1=Common. 2=Survivors (default). 4=Special. 7=All.
      l4d2_spitter_acid_dmg_common "5"        // Damage dealt to common infected. Can use a ratio instead by changing l4d2_spitter_acid_damage.
      l4d2_spitter_acid_dmg_special "8"       // Damage dealt to special infected. Can use a ratio instead by changing l4d2_spitter_acid_damage.
      l4d2_spitter_acid_dmg_survivor "1.0"    // Damage dealt to survivors (games default is 1.0 with l4d2_spitter_acid_damage 2).
      l4d2_spitter_acid_effects "5"           // Displays a particle when hurting. 0=Off, 1=Common Infected, 2=Survivors, 4=Special Infected. 7=All.
      l4d2_spitter_acid_modes ""              // Turn on the plugin in these game modes, separate by commas (no spaces). (Empty = all).
      l4d2_spitter_acid_modes_off ""          // Turn off the plugin in these game modes, separate by commas (no spaces). (Empty = none).
      l4d2_spitter_acid_modes_tog "0"         // Turn on the plugin in these game modes. 0=All, 1=Coop, 2=Survival, 4=Versus, 8=Scavenge. Add numbers together.
      l4d2_spitter_acid_version               // Spitter Acid Damage plugin version 

      Code: 1.0 (05-Nov-2019)
          - Initial release.

      Requirements:DHooks (Experimental Dynamic Detour support)

      Installation:Download the .smx file and put into your servers \addons\sourcemod\plugins folder. Download the .txt gamedata file and put into your servers \addons\sourcemod\gamedata\ folder.
      Attached Files Get Plugin or Get Source (l4d2_spitter_acid_damage.sp - 17.7 KB) l4d2_spitter_acid_damage.smx (9.5 KB) l4d2_spitter_acid_damage.txt (859 Bytes) Wyświetl pełny artykuł
  • Create New...