Raised This Month: $51 Target: $400
 12% 

Easily remove brush entities from map (like func_precipitation)?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
bLacK-bLooD
AlliedModders Donor
Join Date: Jun 2008
Old 10-09-2021 , 04:34   Easily remove brush entities from map (like func_precipitation)?
Reply With Quote #1

Hi all,

I have a custom snow plugin and I would like to be able to disable/remove all other precipitation brush entities from maps that add it (such as winter maps). Is there an easy way to programatically remove it from all maps?

In the documentation (https://developer.valvesoftware.com/..._precipitation), I see there is a property called r_RainParticleDensity, which if set to 0, disables the brush?

I am unsure, though, how to proceed to add it to code and make it global so that it stops rain/snow from all maps that have it.

Thank you!
__________________
We all live under the same sky but we have different horizons.
bLacK-bLooD is offline
Bacardi
Veteran Member
Join Date: Jan 2010
Location: mom's basement
Old 10-09-2021 , 10:57   Re: Easily remove brush entities from map (like func_precipitation)?
Reply With Quote #2

sample
command sm_test
Spoiler


I think MetaMod:Source plugin Stripper would be better. You can edit or remove "original" entities when map spawn.
It won't touch entities made by SM plugin
https://forums.alliedmods.net/showthread.php?t=39439

stripper-1.2.2-git129-windows.zip

stripper-1.2.2-git135-linux.tar.gz


global_filters.cfg

Code:
;;EXAMPLE - remove all physics props
;remove:
;{
;"classname" "/prop_physics.*/"
;}

;;EXAMPLE - replace all garbage cans with a hostage
;modify:
;{
;    match:
;    {    
;    "model" "models/props_junk/garbage_metalcan002a.mdl"
;    "classname" "prop_physics_multiplayer"
;    }
;    replace:
;    {
;    "classname" "hostage_entity"
;    }
;    delete:
;    {
;    "model" "models/props_junk/garbage_metalcan002a.mdl"
;    }
;    insert:
;    {
;    "scale" "0.99"
;    }
;}

remove:
{
"classname" "func_precipitation"
}
__________________
Do not Private Message @me

Last edited by Bacardi; 10-09-2021 at 11:05.
Bacardi is offline
bLacK-bLooD
AlliedModders Donor
Join Date: Jun 2008
Old 10-10-2021 , 16:48   Re: Easily remove brush entities from map (like func_precipitation)?
Reply With Quote #3

Installing stripper did the job, thanks a lot!
__________________
We all live under the same sky but we have different horizons.
bLacK-bLooD is offline
Reply



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 12:36.


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