salem9
|
  |
| Joined: 25 Oct 2008 |
| Total Posts: 23312 |
|
|
| 04 Aug 2012 10:49 PM |
| I'm making a tool, and I need to be able to reduce jump height for it to work well. However, I don't want to increase the amount of down-force on the player, because then they will fall faster than they normally would. Instead, I would like to reduce the amount of force behind the jump. Is that possible? |
|
|
| Report Abuse |
|
|
salem9
|
  |
| Joined: 25 Oct 2008 |
| Total Posts: 23312 |
|
| |
|
T3XT
|
  |
| Joined: 25 Jul 2011 |
| Total Posts: 9233 |
|
|
| 04 Aug 2012 11:44 PM |
Hmmm....
hang in there, I'm coming up with something for you
|
|
|
| Report Abuse |
|
|
adark
|
  |
| Joined: 13 Jan 2008 |
| Total Posts: 6412 |
|
|
| 04 Aug 2012 11:45 PM |
It's not possible at this time to modify jump power. That would be a nice feature, though.
I'll have to ask John in the Uber-Chatroom. |
|
|
| Report Abuse |
|
|
T3XT
|
  |
| Joined: 25 Jul 2011 |
| Total Posts: 9233 |
|
|
| 04 Aug 2012 11:47 PM |
Oh man
alright, I'll kind of have to bend things here since the property itself can't be edited
hang in a little longer OP
|
|
|
| Report Abuse |
|
|
Xnite515
|
  |
| Joined: 18 Feb 2011 |
| Total Posts: 22763 |
|
|
| 04 Aug 2012 11:48 PM |
| Can't you do something about gravity? |
|
|
| Report Abuse |
|
|
|
| 04 Aug 2012 11:49 PM |
| You can use bodyvelocity or something like that to do this. It's just like when people use it to simulate low gravity except you're going in the other direction to increase the gravity. |
|
|
| Report Abuse |
|
|
salem9
|
  |
| Joined: 25 Oct 2008 |
| Total Posts: 23312 |
|
|
| 04 Aug 2012 11:50 PM |
@xnite
I could "alter" gravity by putting a BodyForce into each player's torso and putting downforce onto them, but I just want to decrease the jump height, not decrease it AND make them fall faster. Thanks to you guys for trying to help, looks like I'll have to somehow look for the spacebar and when it is pressed. |
|
|
| Report Abuse |
|
|
adark
|
  |
| Joined: 13 Jan 2008 |
| Total Posts: 6412 |
|
|
| 04 Aug 2012 11:51 PM |
@baxter; That's the problem. OP doesn't want a change in gravity, he wants a change in how high the player can jump. They're not exactly the same. |
|
|
| Report Abuse |
|
|
|
| 04 Aug 2012 11:52 PM |
| Salem, Workspace.Player.Humanoid.Jump:connect(function() print("SOme one has jumped :D") end) |
|
|
| Report Abuse |
|
|
salem9
|
  |
| Joined: 25 Oct 2008 |
| Total Posts: 23312 |
|
|
| 04 Aug 2012 11:53 PM |
@ninja
Thanks, was thinking of a KeyDown function, but that will work jut as well. |
|
|
| Report Abuse |
|
|
T3XT
|
  |
| Joined: 25 Jul 2011 |
| Total Posts: 9233 |
|
|
| 04 Aug 2012 11:58 PM |
oh someone else answered
sorry, i almost got you something else too
|
|
|
| Report Abuse |
|
|
salem9
|
  |
| Joined: 25 Oct 2008 |
| Total Posts: 23312 |
|
|
| 05 Aug 2012 12:00 AM |
@T3XT
Please, add it anyway. This didn't solve the problem, more than likely I won't be able to get the 'workaround' to work. |
|
|
| Report Abuse |
|
|
|
| 05 Aug 2012 12:09 AM |
| Here is an idea, add a body force while jumping, the remove it when they aren't. Or if they start free-falling remove it. |
|
|
| Report Abuse |
|
|
Shobobo99
|
  |
| Joined: 30 Dec 2008 |
| Total Posts: 5754 |
|
|
| 05 Aug 2012 01:08 AM |
You can just set the velocity of their parts to 0 when they jump
char.Humanoid.Jump:connect(function() for _, part in pairs(char:GetChildren()) do if part:IsA("BasePart") then -- just parts you want! part.Velocity = Vector3.new() end end end) |
|
|
| Report Abuse |
|
|
|
| 05 Aug 2012 01:50 AM |
game.Players["LuisPambid"].Character.Humanoid.Jump:connect(function() Torso=game.Players["LuisPambid"].Character["Torso"] Torso.Velocity=Vector3.new(0,Torso:GetMass()*196.2*.5,0) end) |
|
|
| Report Abuse |
|
|
|
| 05 Aug 2012 04:15 AM |
| Couldnt you edit the roblox animate local script in a player so when they join its replaced? Just a guess but it handles with your players animations so set it so it gets the Y value for your character then when you jump say 3 studs higher it turns your characters velocity to 0 on Y which stops the constant movement of your character allowing you to fall normal after:o |
|
|
| Report Abuse |
|
|
chris1989
|
  |
| Joined: 30 Nov 2007 |
| Total Posts: 2520 |
|
|
| 05 Aug 2012 05:35 AM |
game.Players.PlayerAdded:connect(function(player) player.CharacterAdded:connect(function(char) local Hum = char:findFirstChild("Humanoid") repeat wait() until Hum ~= nil Hum.Jumped:connect(function() local Torso = Hum.Parent:findFirstChild("Torso") repeat wait() until Torso ~= nil local hight = Torso.Position.Y local max = Torso.Position.Y + 3 repeat wait() until Torso.Position.Y >= max for i,v in pairs(Hum.Parent:children()) do if v:IsA("Part") then v.Velocity = vector3.new(0,0,0) end end end) end) end) |
|
|
| Report Abuse |
|
|
chris1989
|
  |
| Joined: 30 Nov 2007 |
| Total Posts: 2520 |
|
|
| 05 Aug 2012 05:42 AM |
Fixed a couple errors
game.Players.PlayerAdded:connect(function(player) player.CharacterAdded:connect(function(char) local Hum = char:findFirstChild("Humanoid") repeat wait() until Hum ~= nil Hum.Changed:connect(function(p) if p == "Jump" then local Torso = Hum.Parent:findFirstChild("Torso") repeat wait() until Torso ~= nil local max = Torso.Position.Y + 3-- Change 3 to adjust max height repeat wait() until Torso.Position.Y >= max for i,v in pairs(Hum.Parent:children()) do if v:IsA("Part") then v.Velocity = Vector3.new(0,0,0) end end end end) end) end) |
|
|
| Report Abuse |
|
|
|
| 05 Aug 2012 02:32 PM |
| Mhmmz thought it should work:3 posted it at 3am so i was kinda tired credit to chris1989 for scripting it:p |
|
|
| Report Abuse |
|
|
mamaguy
|
  |
| Joined: 07 Oct 2010 |
| Total Posts: 7073 |
|
|
| 05 Aug 2012 02:40 PM |
| You could measure the jump height, then whenever they jump, put a brick there, and so for like 1-2 seconds there's a brick above them and they don't jump as high <3 |
|
|
| Report Abuse |
|
|