Fortress Forever

Fortress Forever (https://forums.fortress-forever.com/index.php)
-   Lua (https://forums.fortress-forever.com/forumdisplay.php?f=44)
-   -   Stopping/Freezing a player (https://forums.fortress-forever.com/showthread.php?t=14360)

squeek. 02-07-2008 02:28 AM

Stopping/Freezing a player
 
Been tooling around with this, but I thought I'd see if I could get some input. Anyone know a way to stop or freeze a player? I just need them to not be able to move; the rest (shooting, nades, etc) isn't important.

Ihmhi 02-07-2008 04:03 AM

Well I know the TFC server had "pause" built into it, haha...

ADMIN: -pauses the game-
"Are you guys gonna play nice?"

Everyone was crying moar that day, so he basically just froze the game haha...

Jiggles 02-07-2008 05:57 AM

Yeah, there's a FROZEN flag you can set on players, and I imagine Lua can do it...but Mulch or Jon are probably the ones to ask in that regard. I still think Lua's the devil ;)

Or maybe setting a 0% speed effect? Dunno...

DrEvil 02-07-2008 08:17 PM

we used the freeze flag in some of our previous bot training to freeze the player while the bot explained shit

Tsukasa 02-07-2008 08:28 PM

Quote:

Originally Posted by DrEvil
we used the freeze flag in some of our previous bot training to freeze the player while the bot explained shit

I AM ROBOT. MY EYES HAVE FREEZE RAY.

squeek. 02-07-2008 11:22 PM

Quote:

Originally Posted by DrEvil
we used the freeze flag in some of our previous bot training to freeze the player while the bot explained shit

And how do you use the freeze flag? I don't see it in the big lua list of commands.

-=Roland=- 02-08-2008 12:28 AM

Semi related. I need to see if there is a way to prevent a player from shooting or throwing nades in an area but still move.

squeek. 02-08-2008 12:52 AM

Quote:

Originally Posted by -=Roland=-
Semi related. I need to see if there is a way to prevent a player from shooting or throwing nades in an area but still move.

Nade explosions can be removed with a noannoyances trigger_ff_script if I'm not mistaken. Look in one of the includes (under the noannoyances definitions) for the code that removes grenade explosions.

Player shooting I'm not sure about (I think you can block/remove projectiles but I'm not sure how), but you can strip all weapons or all ammo using:
Code:

player:RemoveAllAmmo(true)
and/or
player:RemoveAllWeapons()


-=Roland=- 02-08-2008 03:23 AM

Thanks I'll give those a try.

DrEvil 02-08-2008 06:09 PM

I exposed the functionality to the bot scripting. I don't think its currently available to the FF scripting. It's easy to add though if its not already.

squeek. 02-08-2008 07:03 PM

Quote:

Originally Posted by DrEvil
I exposed the functionality to the bot scripting. I don't think its currently available to the FF scripting. It's easy to add though if its not already.

Alright, hope to see it get added soon.


All times are GMT. The time now is 05:46 PM.

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