How do I make it so your screen blurs when you have low health?
8 replies, posted
How do I make it so when you have low health, your screen blurs?
[lua]if ( LocalPlayer():Health() <= 30 ) then
*blur code*
end
[/lua]
I know that part, but then how do I make it blur (Where can I find out how to actually make it blur)
[QUOTE=PhantomServer;50492197]I know that part, but then how do I make it blur (Where can I find out how to actually make it blur)[/QUOTE]
You could use derma or something. Just an idea.
[URL="http://wiki.garrysmod.com/page/DFrame/SetBackgroundBlur"]SetBackgroundBlur()[/URL]
I find it much more effective to just run ply:ConCommand() to add screen effects. This is how Fearless' CityRP does it and you don't have to use net messages. You can find all screen effects with "pp_" in console. Sure, the player can undo the effects but iirc they can if you use the build-in functions, too. Just watch out for pp_texturize.
[QUOTE=SirFrancisB;50492528]I find it much more effective to just run ply:ConCommand() to add screen effects. This is how Fearless' CityRP does it and you don't have to use net messages. You can find all screen effects with "pp_" in console. Sure, the player can undo the effects but iirc they can if you use the build-in functions, too. Just watch out for pp_texturize.[/QUOTE]
What if he don't want players to disable it as having it turned off might give an advantage over people with it on?
It really doesn't matter as you can disable it with the commands like DrawMotionBlur, etc. You could always make a timer that keeps enforcing the blur every x seconds.
Use the default blur material that Gmod has and create a new draw function out of it. Then use that new function to draw a rectangle on the players screen.
Just [URL="https://wiki.garrysmod.com/page/Global/DrawMotionBlur"]use motion blurring[/URL] to simulate what you're trying to do.
Sorry, you need to Log In to post a reply to this thread.