Raised This Month: $51 Target: $400
 12% 

[Pay][REQ] TF2 Freeze Tag


Post New Thread Reply   
 
Thread Tools Display Modes
friagram
Veteran Member
Join Date: Sep 2012
Location: Silicon Valley
Old 12-22-2012 , 15:09   Re: [Pay][REQ] TF2 Freeze Tag
Reply With Quote #61

Quote:
Originally Posted by psychonic View Post
You can globally stop prediction with a server cvar, but it's not worth doing.

What you can do is making the client think they can't attack by manipulating things like m_flNextPrimaryAttack (the var that controls the wait time between attacks), continually setting it to current time + a few seconds, for the duration of the no-attack time.
That could work.
Right now I give them tf_weapon_fists, because it's a weapon that works on all classes, has no viewmodel, and makes it look like they have no weapon, when they actually do (otherwise they'd enter ref). However, they can also altfire, so I'd have to set secondary attack too.

Would this reset itself on tf2_regenerate player? if so I could just fire both to the client when they get frozen with a realllllllllllllllllllllllly long time so they could never attack until they get regenrated or something. Else I could just reset it to engine time when they get unfrozen. Otherwise I'd have to fire it in the primary loop which refreshes every 1 second.

Also, I have to detect flamethrowers for my physics push, because they only do 5 damage per particle or so, which is below threshold damage to do enough force for players.
I tried detecting fire damage, but it also picks up flares. Is there a better way to do it with damagetype so I have less overhead? I really hate having to do something like this:

if(IsValidEdict(inflictor) && GetEdictClassname(inflictor, sWeapon, 24) && StrEqual(sWeapon, "tf_weapon_flamethrower"))
(I think this will work)

Last edited by friagram; 12-22-2012 at 15:14.
friagram is offline
loranger
Senior Member
Join Date: Jun 2011
Old 12-27-2012 , 04:27   Re: [Pay][REQ] TF2 Freeze Tag
Reply With Quote #62

Idk about you guys, but soon as I get a copy of this, ill make it like Quake 3 freeze tag with bfg gun insta gib, using the rocket launcher.
loranger is offline
CuriousG
Senior Member
Join Date: Feb 2012
Old 12-27-2012 , 05:06   Re: [Pay][REQ] TF2 Freeze Tag
Reply With Quote #63

Quote:
Originally Posted by loranger View Post
Idk about you guys, but soon as I get a copy of this, ill make it like Quake 3 freeze tag with bfg gun insta gib, using the rocket launcher.
There already is a gun like that from Randomizer called Army of One
CuriousG is offline
friagram
Veteran Member
Join Date: Sep 2012
Location: Silicon Valley
Old 12-28-2012 , 03:54   Re: [Pay][REQ] TF2 Freeze Tag
Reply With Quote #64

Quote:
Originally Posted by loranger View Post
Idk about you guys, but soon as I get a copy of this, ill make it like Quake 3 freeze tag with bfg gun insta gib, using the rocket launcher.
Heh i was thinking about making this where everyone gets a sniper rifle that fires from the hip.
You can make it fire machina round tracers (by filling the meter), and just make them always crit (add the crit flag), and add weapon mod - crits gib =S
could probably add te rings to make the railgun spirals too, may have to get rid of the machina round tracer to do this since client side prediction would interfere, and just use temp ents for all the railgun spirals/beams and just tie it from fire vec to death vec, would still look cool mayhap.

Last edited by friagram; 12-28-2012 at 03:56.
friagram is offline
moxie2020
Veteran Member
Join Date: Aug 2011
Old 12-28-2012 , 23:32   Re: [Pay][REQ] TF2 Freeze Tag
Reply With Quote #65

Quote:
Originally Posted by Dr. McKay View Post
I've been planning on writing a freeze tag plugin, but it doesn't work the same way you are asking:

All weapons enabled
Standard class health
When your health drops to 1, you are frozen in a manner identical to sm_freeze
Your health will never drop below 1, so you won't die
When a friend stands near you, they will begin to unfreeze you, and a progress indicator will appear on their screen
As you're unfrozen, your health will regain to 150% (max overheal)
Medics can speed along the unfreezing process by using their medigun

So... yeah. I'll work on it when I get a chance.
Dr. McKay is this still on your to do list?
moxie2020 is offline
Dr. McKay
Sir Dr. SourceMod Plugin Approver Esq. Ltd. M.D. PhD
Join Date: Aug 2011
Location: Atlantis
Old 12-28-2012 , 23:42   Re: [Pay][REQ] TF2 Freeze Tag
Reply With Quote #66

Quote:
Originally Posted by moxie2020 View Post
Dr. McKay is this still on your to do list?
Yup.
__________________
Dr. McKay is offline
friagram
Veteran Member
Join Date: Sep 2012
Location: Silicon Valley
Old 12-30-2012 , 00:36   Re: [Pay][REQ] TF2 Freeze Tag
Reply With Quote #67

"Your health will never drop below 1, so you won't die"
So you disabled damage spread, and round down damage to ensure this or something?

There are some beta hooks addons out there that will allow you to use other calls, but they are real unstable, and extra dependencies.
friagram is offline
friagram
Veteran Member
Join Date: Sep 2012
Location: Silicon Valley
Old 12-30-2012 , 06:56   Re: [Pay][REQ] TF2 Freeze Tag
Reply With Quote #68

made some updates, hope they work out for you guys:
https://forums.alliedmods.net/showthread.php?t=204415
friagram is offline
Dr. McKay
Sir Dr. SourceMod Plugin Approver Esq. Ltd. M.D. PhD
Join Date: Aug 2011
Location: Atlantis
Old 12-30-2012 , 11:22   Re: [Pay][REQ] TF2 Freeze Tag
Reply With Quote #69

friagram's version looks a lot better than mine. I kinda lost interest in this tbh, and it looks like friagram has this covered.

One thing that I might suggest, however, is that if you stun frozen players, they are put into thirdperson and look "scared" while they are frozen.

PHP Code:
TF2_StunPlayer(client99999999.90.0TF_STUNFLAG_THIRDPERSON); 
Just do that again with 0.0 as the time to get them out of the stunned state.

Here's the code that I got done. I have no idea if this compiles, but you might find something you like: https://www.dropbox.com/sh/92i2zhhazzoc27x/TlDY4-y8l_
__________________
Dr. McKay is offline
friagram
Veteran Member
Join Date: Sep 2012
Location: Silicon Valley
Old 12-30-2012 , 21:57   Re: [Pay][REQ] TF2 Freeze Tag
Reply With Quote #70

Quote:
Originally Posted by Dr. McKay View Post
friagram's version looks a lot better than mine. I kinda lost interest in this tbh, and it looks like friagram has this covered.

One thing that I might suggest, however, is that if you stun frozen players, they are put into thirdperson and look "scared" while they are frozen.

PHP Code:
TF2_StunPlayer(client99999999.90.0TF_STUNFLAG_THIRDPERSON); 
Just do that again with 0.0 as the time to get them out of the stunned state.

Here's the code that I got done. I have no idea if this compiles, but you might find something you like: https://www.dropbox.com/sh/92i2zhhazzoc27x/TlDY4-y8l_
I can't really use the stun effect..
- It looks strange (players have hands in air)
- It changes the players movement speed (velocity)
- Velocity must be at 1 to prevent them from moving
- Players must have velocity at 1 to be movable by enemy players rather than MOVETYPE_NONE
- I use a model that presents a specific effect when in first person
- Forcing first/third person interferes with third person mods (many players like to use this)

I didn't think about this:
Code:
	new medigun = GetPlayerWeaponSlot(client, 1);
	if(medigun == -1) {
		return Plugin_Continue;
	}
	new target = GetClientAimTarget(client);
	if(target == -1 || GetEntityMoveType(target) != MOVETYPE_NONE) {
		return Plugin_Continue;
I just rednecked it with equalizer attribs on frozen people. Works, and they can see "equalizer blocks healing." Also shuts up annoying soldiers from calling medic (but not other classes) =S
I already stripped them down and gave them weapons that did no damage, and had some other attributes to control them, so this seamed logical enough.
Psychonic mentioned a way to stop players from swinging since I blocked the runcmd, which I'll have to look into. The other option was to just let them attack, but make the weapon attribs have super slow swing time, so they could only attack once.

I kind of did stuff by trial/error and experimentation.
I don't have too much experience with sourcemod, this is the first plugin I've released.
I've got some experience with C/C++ 10 years or so ago, which kind of pulled me through, though I'm sure my code could use some work.
If anyone's got some ideas for improvements I'll look into them. I've already got a lot of requests for features/changes, but none really regarding the code itself =/

Last edited by friagram; 12-31-2012 at 04:22.
friagram is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 02:17.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode