hey there so im on darkrp 2.5 I have a job that when you become them your gravity changes I also have it so if u spawn you get it this is my hook
[lua]
hook.Add("OnPlayerChangedTeam", "changegravity", function( ply, oldteam, newteam) if newteam == TEAM_ASTRONAUT then ply:SetGravity(.12) end end)
[/lua]
heres the function
[lua]
PlayerSpawn = function(ply) ply:SetGravity(.12) end
[/lua]
so the problem is when i change to a different team I still have low gravity I have tried to do
[lua]
hook.Add("OnPlayerChangedTeam", "changegravity", function( ply, oldteam, newteam) if oldteam == TEAM_ASTRONAUT then ply:SetGravity(.12) end end)
[/lua]
but that didnt work can someone help me make a hook or something so when you change teams to a different job you dont have low gravity?
Try
[code] hook.Add("OnPlayerChangedTeam", "changegravity", function( ply, oldteam, newteam) if newteam == TEAM_ASTRONAUT then ply:SetGravity(.12) else ply:SetGravity(1) end end)[/code]
awesome your the best it works
Sorry, you need to Log In to post a reply to this thread.