Raised This Month: $ Target: $400
 0% 

Accelerating when Jump Upward


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Mlk27
Veteran Member
Join Date: May 2008
Old 01-05-2009 , 09:07   Accelerating when Jump Upward
Reply With Quote #1

how do you give high jump to players?

Last edited by Mlk27; 01-12-2009 at 21:04.
Mlk27 is offline
SnoW
Veteran Member
Join Date: Oct 2008
Location: Finland WisdomNuggets: 8
Old 01-05-2009 , 10:00   Re: Accelerating when Jump Upward
Reply With Quote #2

I'm not sure what are you talking about, but what I understood, I would do like this: (FM version ofc)
Code:
new Float:velocity[3];
 pev(index, pev_velocity, velocity);
 velocity[2] = 300.0;  //How high you want that player gets...
 set_pev(index, pev_velocity, velocity);
If you want to make it usable when player is already in air with speed, you should use:
Code:
velocity[2] += 300.0;
SnoW is offline
Send a message via MSN to SnoW
Mlk27
Veteran Member
Join Date: May 2008
Old 01-12-2009 , 19:38   Re: Accelerating when Jump Upward
Reply With Quote #3

err i mean when a player jumps vertically. so i hook FM_CmdStart and prethink?
Mlk27 is offline
Exolent[jNr]
Veteran Member
Join Date: Feb 2007
Location: Tennessee
Old 01-12-2009 , 20:46   Re: Accelerating when Jump Upward
Reply With Quote #4

Do you just want a higher jump?
__________________
No private work or selling mods.
Quote:
Originally Posted by xPaw View Post
I love you exolent!
Exolent[jNr] is offline
Mlk27
Veteran Member
Join Date: May 2008
Old 01-12-2009 , 20:56   Re: Accelerating when Jump Upward
Reply With Quote #5

yep
Mlk27 is offline
Exolent[jNr]
Veteran Member
Join Date: Feb 2007
Location: Tennessee
Old 01-12-2009 , 21:17   Re: Accelerating when Jump Upward
Reply With Quote #6

Code:
#include <amxmodx> #include <amxmisc> #include <fakemeta> #include <hamsandwich> new bool:g_do_jump[33]; public plugin_init() {     RegisterHam(Ham_Player_Jump, "player", "FwdPlayerJumpPre", 0);     RegisterHam(Ham_Player_Jump, "player", "FwdPlayerJumpPost", 1); } public FwdPlayerPre(client) {     if( !is_user_alive(client) ) return HAM_IGNORED;         g_do_jump[client] = bool:(pev(client, pev_flags) & FL_ONGROUND);         return HAM_HANDLED; } public FwdPlayerJumpPost(client) {     if( !g_do_jump[client] ) return HAM_IGNORED;         static Float:velocity[3];     pev(client, pev_velocity, velocity);         velocity[2] = 500.0;         set_pev(client, pev_velocity, velocity);         g_do_jump[client] = false;         return HAM_HANDLED; }
__________________
No private work or selling mods.
Quote:
Originally Posted by xPaw View Post
I love you exolent!

Last edited by Exolent[jNr]; 01-12-2009 at 22:33.
Exolent[jNr] is offline
Mlk27
Veteran Member
Join Date: May 2008
Old 01-12-2009 , 21:44   Re: Accelerating when Jump Upward
Reply With Quote #7

nice it works but if players press and hold jump button or keep pressing jump while in air, they never fall on ground. lol

can you please make this works exactly like normal jump in cs, except that they can jump higher..?
Mlk27 is offline
Exolent[jNr]
Veteran Member
Join Date: Feb 2007
Location: Tennessee
Old 01-12-2009 , 22:33   Re: Accelerating when Jump Upward
Reply With Quote #8

Try that.
__________________
No private work or selling mods.
Quote:
Originally Posted by xPaw View Post
I love you exolent!
Exolent[jNr] 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 09:12.


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