Post: [CODE] Dolphin Dive in MW2
02-27-2011, 08:32 PM #1
xQuZe-
You talkin to me?
(adsbygoogle = window.adsbygoogle || []).push({});
Dolphin Dive


Video:
[ame="https://www.youtube.com/watch?v=tGTgHMhjfkg"]Dolphin Dive[/ame]



Originally posted by another user
Yup, this is for MW2. Made this code because i wanted the abillity to dolphin dive in mw2.
I know it doesn't look that sexy but it's a start.
A good coder like derek or mossy could pick this up and make it better.
You can remove the HUDmessage if you want.
If you put this on onplayerspawned() it's just like a normal button.
It's just as in BO, Sprint and Circle.





Code:
    
Dive()
{
self endon("disconnect");
self maps\mp\gametypes\_hud_message::hintMessage("Press [{+breath_sprint}] and [{+stance}] to dive.");
self notifyOnPlayerCommand( "Run", "+breath_sprint" );
self notifyOnPlayerCommand( "Dive", "+stance" );
for(;Winky Winky
{
self waittill( "Run" );
self waittill( "Dive" );
self setPlayerAngles(self.angles + (22, 0, 0));
self setOrigin(self.origin+(0,0,25));
wait .01;
forward = self getTagOrigin("j_head");
end = self thread vector_Scal(anglestoforward(self getPlayerAngles()),1000000);
MaCrosshair = BulletTrace( forward, end, 0, self )[ "position" ];
setDvar("timescale", 0.4 );
wait .01;
self setOrigin(MaCrosshair+(0,0,0));
self SetStance( "prone" );
self freezeControls(true);
wait .2;
setDvar("timescale", 1.0 );
wait .5;
self freezeControls(false);
}
}
vector_scal(vec, scale)
{
vec = (vec[0] * scale, vec[1] * scale, vec[2] * scale);
return vec;
}


In 1 line:
    Dive(){self endon("disconnect");self maps\mp\gametypes\_hud_message::hintMessage("Press [{+breath_sprint}] and [{+stance}] to dive."); self notifyOnPlayerCommand( "Run", "+breath_sprint" );self notifyOnPlayerCommand( "Dive", "+stance" ); for(;Winky Winky {self waittill( "Run" );self waittill( "Dive" );self setPlayerAngles(self.angles + (22, 0, 0));self setOrigin(self.origin+(0,0,25));wait .01;forward = self getTagOrigin("j_head");        end = self thread vector_Scal(anglestoforward(self getPlayerAngles()),1000000);        MaCrosshair = BulletTrace( forward, end, 0, self )[ "position" ];setDvar("timescale", 0.4 );wait .01;self setOrigin(MaCrosshair+(0,0,0));self SetStance( "prone" );self freezeControls(true);wait .2;                setDvar("timescale", 1.0 );wait .5;self freezeControls(false);}}vector_scal(vec, scale){        vec = (vec[0] * scale, vec[1] * scale, vec[2] * scale);        return vec;}

(adsbygoogle = window.adsbygoogle || []).push({});

The following 17 users say thank you to xQuZe- for this useful post:

Beta-, Brian235026, CleanMODSHD, Correy, emersons35, Fifa97, I am Mara, Man Dime, matt944057, maxrox, Mr. Aimbot, Ninja, Officer Laggy, oGHOSTLYMODZ, PussayPatrol, ViiZiiKz, xT4sSin
02-28-2011, 07:51 PM #38
xQuZe-
You talkin to me?
Originally posted by anddrew View Post
you do realise that if someone holds there breath with a sniper and stands up/ crouches that the script will happen?
(serves em right for hardscoping :broSmile


Haha yea lol.. Is there a way to only make it happen while sprinting?
(you're right:broSmile
02-28-2011, 07:55 PM #39
anddrew
League Champion
Originally posted by xQuZe
Haha yea lol.. Is there a way to only make it happen while sprinting?
(you're right:broSmile


I don't think so, but it would be cool if there was something like
    
if (self GetAim()!="inScope"){
self thread dolphindive();
}
//if NOT in aim do dolphin dive

Winky Winky that would been nice for IW to put in
02-28-2011, 07:59 PM #40
xQuZe-
You talkin to me?
Originally posted by anddrew View Post
I don't think so, but it would be cool if there was something like
    
if (self GetAim()!="inScope"){
self thread dolphindive();
}
//if NOT in aim do dolphin dive

Winky Winky that would been nice for IW to put in


Hehe yea :evil:
02-28-2011, 08:34 PM #41
nothing amazing but closest ive seen to it
02-28-2011, 09:27 PM #42
xQuZe-
You talkin to me?
Originally posted by xhiitm4n View Post
nothing amazing but closest ive seen to it


Lol give me link's of what you've seen then?
02-28-2011, 09:42 PM #43
anddrew
League Champion
Originally posted by xQuZe
Lol give me link's of what you've seen then?


Thats what i thought, noob.
Where's his stuff that makes yours nothing amazing? (I may be wrong and he IS a good
coder.)
XQuZe is a lush coder <3
02-28-2011, 09:47 PM #44
xQuZe-
You talkin to me?
Originally posted by anddrew View Post
Thats what i thought, noob.
Where's his stuff that makes yours nothing amazing? (I may be wrong and he IS a good
coder.)
XQuZe is a lush coder <3


Thanks made a new code Smile
Posting in a few mins. Just some last tests.
02-28-2011, 09:51 PM #45
anddrew
League Champion
Originally posted by xQuZe
Thanks made a new code Smile
Posting in a few mins. Just some last tests.


Ooh whats it for?
Its embarrasing i've been trying to get one code working (and still haven't) and you've done a few Winky Winky
02-28-2011, 10:48 PM #46
xQuZe-
You talkin to me?
Originally posted by anddrew View Post
Ooh whats it for?
Its embarrasing i've been trying to get one code working (and still haven't) and you've done a few Winky Winky


Released it. Check it out :black: And that means your code is better in quality. Or you're just slower:pedo::pedo:.
:bro:?

Copyright © 2026, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo