Fortress Forever

Go Back   Fortress Forever > Projects > Fortress Forever > Feature

LUA Request: Player's friction Issue Tools
issueid=288 05-09-2010 05:48 PM
1-800-UNAGIPOWA
LUA Request: Player's friction

Requesting a way to change a player's friction on a per player basis

EDIT: Also a way to keep a player from moving, but retain their ability to look around
Issue Details
Issue Type Feature
Project Fortress Forever
Category LUA (Map Scripting)
Status Accepted
Priority Unknown
Suggested Version Undefined
Implemented Version (none)
Votes for this feature 1
Votes against this feature 1
Assigned Users (none)
Tags (none)

05-09-2010 07:12 PM
Banned
 
Players can still look around with Freeze(bool).
Reply
05-09-2010 07:42 PM
 
Why on a per player basis? sv_friction is already in the server.cfg. If it's for a map you could just create an mapname.cfg. Per player commands are best left to sourcemod.
Reply
05-09-2010 07:52 PM
1-800-UNAGIPOWA
 
Quote:
Originally Posted by [AE] 82694
Why on a per player basis? sv_friction is already in the server.cfg. If it's for a map you could just create an mapname.cfg. Per player commands are best left to sourcemod.
Minigolf... bro
Reply
05-09-2010 08:13 PM
WhenNailGrenWillOut?
 
Quote:
Originally Posted by cjeshjoir
Minigolf... bro
Hell yeah.
Reply
05-09-2010 08:37 PM
Who the fuck is this guy?
 
LUA has a speed effect for a single player.. check Waterpolo for uses. (just make it 0)
Reply
05-09-2010 09:03 PM
Banned
 
You could just use Freeze(bool) instead of having to manage effects.
Reply
05-09-2010 09:07 PM
1-800-UNAGIPOWA
 
Ive tested both ways and they will both work, but making civvies bounce around is the only part thats left
Reply
05-09-2010 10:15 PM
Stuff Do-er
 
There is a baseentity:SetFriction( float ) function in lua right now, but it was being mapped to the wrong function in 2.41. It should be fixed in future versions, but I'm not sure if it'll even work for players. Try it in the beta version.
Reply
05-10-2010 01:51 AM
1-800-UNAGIPOWA
 
Doesn't seem to work for players, but I suck a lot... Anyone else test this?
Reply
05-10-2010 03:07 AM
Banned
 
It doesn't work.
Reply
02-23-2012 06:10 PM
Gets tickled by FF
 
This does set the friction to the extent it returns the same value if i use get friction but it doesn't seem to have any effect.

Is it me?
Code:
function player_spawn( player_entity ) 
	local player = CastToPlayer( player_entity ) 
	ChatToPlayer(player, player:GetFriction().." = fric")
	player:SetFriction(999) --or whatever (tried 0.00001)
	ChatToPlayer(player, player:GetFriction().." = fric")
end
Reply
02-23-2012 08:22 PM
Stuff Do-er
 
Player-specific friction was commented out of the movement code, I believe. Would be worth re-implementing it.
Reply
Reply

All times are GMT. The time now is 11:59 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2024, vBulletin Solutions, Inc.