[TF2] RocketBounce
1 Attachment(s)
It makes rockets reflect off walls, 'nuff said.
Someone requested this months ago. I originally had it written in C++, but with the release of SDKHooks2 this can now be done in pawn. Use the sm_rb_max cvar to set how many times a rocket will bounce before detonating, the default it 2. Hopefully the math stuff helps people out with more useful things :P |
Re: [TF2] RawketBawnce
You check for if the Touch entity is a client, not world. It bounces off clients. Woo. I changed it to world.
Will post my version once I add a teeensy little thing. |
Re: [TF2] RawketBawnce
oh shi-!
brilliant :3 |
Re: [TF2] RawketBawnce
It conflicts with some other plugin that uses SDKHooks, but I'm not sure which. Whatever plugin it is, it messes with the direction they bounce.
To test, I unloaded SDKHooks (and therefore all SDKHooks-using plugins), reloaded SDKHooks, then loaded only rocketbounce, it worked fine. refreshed all plugins, it got all buggy again. It's not homingrocket, because I unloaded that and it still did the off-angle bounces and straight-on-shot exploding. It *might* be holyarrows, but I'm not sure. Will continue testing later. If you want the version that bounces off the walls, go into the source, look for "other < 1 || other > MaxClients", change that to "other != 0". |
Re: [TF2] RawketBawnce
Quote:
Quote:
Uploaded a fixed version. |
Re: [TF2] RawketBawnce
1 Attachment(s)
Here's the one I wrote up that makes it explode if it bounces near a player.
Allows for rocket jumping. |
Re: [TF2] RawketBawnce
This is all incredibly neat, but I have a question
why do you wait for the second touch trigger before you bounce the projectile? You could just as well have done it in StartTouch yet you wait until the first Touch hook after that. Why is that? |
Re: [TF2] RawketBawnce
Quote:
Like I said, I wrote it in C++ way-back-when and I'm sure I had a reason for it then. I just ported my C++ version directly to Pawn. EDIT: Oh, I think I remember. When StartTouch is called, Touch is guaranteed to fire directly afterwards, even if you block the StartTouch call. If you just hook Touch, you get calls as it passes through triggers and the like. This is only based on half-remembered memories though. |
Re: [TF2] RawketBawnce
Nicely done. I might suggest, (although it wouldn't be your fault if someone lagged their server doing this) that you put in an upper limit on that cvar? Just for the fun of it I set it to 100 and fired away in spawn.
http://i.imgur.com/aFKoxl.jpg http://i.imgur.com/j9We0l.jpg Tons of fun though. Changing the cvar on the fly works like a charm. |
Re: [TF2] RawketBawnce
That's clearly the best use of this plugin.
Wait, no, bouncing arrows. Ash: NATIVES?! |
All times are GMT -4. The time now is 11:27. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.