Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Help Can you disable the jump button for a period of time?
#1
As i have made a player be able to jump really high(as high as the world can allow).
There is an exploit where you can keep pressing space and he will just keep on jumping and stop on top of the world so to speak.
I as wondering if you could make it be able to press jump once then disable it or make you not able to use it again until you hit the ground.

Thanks in Advance!


PS: Im using a modified jetpack mod
Reply

#2
copy the code here that you are using
Reply

#3
(07-02-2011, 01:35)koil Wrote: copy the code here that you are using
What code?
Reply

#4
the jet pack code




Reply

#5


Jetpack()
{
self endon("death");

self setPerk("specialty_fallheight");
self.jetpack = 10;
FUEL = createPrimaryProgressBar( -275 );
FUELTXT = createPrimaryProgressBarText( -275 );
FUELTXT setText("^1FUEL");
FUELTXT.y = 210;
FUEL.bar.y = 220;
FUEL.y = 220;
self thread HUDestroy(FUEL.bar);
self thread HUDestroy(FUEL);
self thread HUDestroy(FUELTXT);
for(i=0;;i++)
{
if(self jumpbuttonpressed() && self.jetpack > 0)
{
if(self isOnGround())
{
self setOrigin((self.origin[0], self.origin[1], self.origin[2] + 30));

}
else
{
self.jetpack--;
Earthquake(.15 , .2, self gettagorigin("j_spine4"), 50);
PlayFX(level.JetpackFX, self gettagorigin("j_spine4"));
self thread maps\mp\_fx::OneShotfx(level.JetPackFX, self gettagorigin("j_spine4"), 2);

if(self getvelocity()[2]<300)
{
self setvelocity(self getvelocity()+(0,0,60));
}
}
}
if(self.jetpack<10 &&!self jumpbuttonpressed())
{
self.jetpack++;
}
FUEL updateBar(self.jetpack/6000);
FUEL.bar.color=(1,self.jetpack/150,self.jetpack/150);
wait .05;
}
}


HUDestroy(hudElem)
{
self endon("spawned_player");

hudElem destroy();
hudElem delete();
}
Reply

#6
one sec ill test it
ok i checked your code, just disable your gravity DVAR and it will work the way you want.. lol
Reply



Possibly Related Threads…
Thread Author Replies Views Last Post
  Disable Planting on Bomb clemi555 4 3,426 11-04-2013, 07:59
Last Post: clemi555
  Help How to disable auto balance? .sepultura. 3 4,316 10-07-2013, 19:44
Last Post: Nekochan
  jump higher kerm007 9 5,032 07-29-2013, 10:16
Last Post: Arteq
Information [Request] Need Time Plugin and Server Msg Plugin sylvester123 14 9,375 07-26-2013, 08:07
Last Post: sylvester123
  4D1 Extend Feeding Time Tacticalicious 1 2,592 07-02-2013, 20:59
Last Post: surtek
Tongue What are you doing in free time? Nekochan 16 8,870 05-05-2013, 08:25
Last Post: Pozzuh
Question [Request] Permanent UAV Plugin for Private Hight Jump Infected Server Paxton 7 4,609 04-02-2013, 15:32
Last Post: 99IRock
Lightbulb [Release] Different jump Height/speed for each map. hillbilly 17 10,875 03-04-2013, 07:09
Last Post: avj
  Help Creating Wait Binds for a consecutive button presses? clxyeah 3 3,136 02-10-2013, 14:01
Last Post: koil
  [Release] Sprint Disable Plugin for version 1.9.446 blueberry9 5 4,386 01-21-2013, 22:00
Last Post: thanatos

Forum Jump:


Users browsing this thread:
1 Guest(s)

Forum Powered By MyBB, Theme by © 2002-2024 Melroy van den Berg.