| closedLocking spec on original team players |
| Started by Kristiansen on 02-08-2009, 12:21 AM |
Threads: 18
Joined: Jan 2008
I wondered if it was possible to create something that would lock spectator views on the players on the team the player came from?nnErm. To exemplify this I should explain that it would be useful in a "realism game" if anyone of you have tried that. Basically upon death you join spec (as in you only get one life, right.). But unfortunately there is a wide use of "ghosting", i.e. dead players look around the map as spectator and tells the remaining teammates of enemy locations through steam friends, ventrilo etc.nnHowever I'm reluctant to install a total blackout thing, I got the specfade and deathfade mod from this forum and put the alpha values to 235, which gives everyone a vague view of whats going on but more difficult to ghost. Full blackout is really annoying and makes people leave and ruins the intensity of watching the show as spectator. However it could still be exploited and ghosted this way. And through full blackout one could also use minimap icons and spot locations (hard).nnSo, what I was thinking of is a plugin that makes people coming from e.g. axis, only able to spec axis players. Locked person view or whatever. I think this is what you get between respawns, right?nnAs far as my largely insufficient knowledge of this stuff goes, I think that specators coming from both teams technically goes into "team 3", right? So I guess one would have to make something that "remembers" what team you come from to make this.nnIs this possible?
Threads: 75
Joined: Nov 2007
this is certainly not the best solution but try this http://forums.alliedmods.net/showthread.php?p=485299 and set the respawn factor really high and this for restarting the game/round this: https://www.dodplugins.net/forums/showthread.php?t=1474 rnrnhowever i think there are some kinda server cvar that makes u only spec your team mates, if so enable it... well again its not a good solution especialy not if iam wrong about the server cvar lol. But it will work for some testing and see whats going to happen... someone requested a "join spec on death" plugin before, and i made something that worked ok, but was a bit gay anyway cuz when u killed ppl it look like u killed a spectator cuz it switched ppl to spec too fast haha, but i can dig that up again and fix it later today if u want...rnrnrn*EDIT*rnrnwell if u join team 3 (spec) u do no longer belong on a team and here by u would be able to spec all, i think lol thats why i wanted you to set the respawn factor high.. lol confused?, sry i just woke up...rnrncheers
Threads: 18
Joined: Jan 2008
rnrn*EDIT*rnrnwell if u join team 3 (spec) u do no longer belong on a team and here by u would be able to spec all, i think lol thats why i wanted you to set the respawn factor high.. lol confused?, sry i just woke up...rnrncheersrnrnYep that's what I thought too, so I guess the plugin (if this is possible) would had to "remember" what team a player came from.rnYep there is a cvar making you only able to spec your own team. And we do have a pretty neat config that by only changing server variables makes the respawn time really long and keep people "dead". However noone is used to this and it turned out to be really confusing. The other team can't see who's dead and not easily.
Threads: 23
Joined: Aug 2007
No time to sight see with synthetics new plug-in.rnhttps://www.dodplugins.net/forums/showthread.php?t=1521&highlight=respawn
Threads: 18
Joined: Jan 2008
Thanks for grasping the purpose of this plugin request, lol. I'm not looking for something between respawns, I'm talking about when you are in spectator.
Threads: 103
Joined: May 2005
lol @ the responses.. i understood what you were asking fornnnthis is far from perfect but give it a try..n
nn#include <amxmodx>n#include <fakemeta>n#include <dodx>nn#define VERSION "1.0"nn#define SPEC 3nnnew p_pluginnnew g_specteam[33],g_currteam[33]nnpublic plugin_init()n{n register_plugin("DoD Spectate Team",VERSION,"AMXX DoD Team")nn p_plugin = register_cvar("dod_spectateteam","1")n}nnpublic dod_client_changeteam(id,team,oldteam)n{n if(is_user_connected(id))n { n g_specteam[id]=oldteamn g_currteam[id]=teamn n if(team==SPEC && (oldteam==ALLIES || oldteam==AXIS))n set_task(0.1,"funcCheckSpec",id,_,_,"b")n else if(oldteam==SPEC && task_exists(id))n remove_task(id)n }n}nnpublic funcCheckSpec(id)n{n if(get_pcvar_num(p_plugin) && is_user_connected(id) && g_currteam[id]==SPEC && g_specteam[id])n {n new spec_id = pev(id,pev_iuser2)n n if(g_specteam[id] != g_currteam[spec_id])n client_cmd(id,"wait;+attack;wait;-attack")n }n}Threads: 18
Joined: Jan 2008
It works partly, if you try you can still spec opposite team but it will cycle through all the opposite team's players really fast and go back to your own team. I can live with that, but have you tried going free look? Gives you spasm to watch it lol. I guess its the closest you can get?
Threads: 59
Joined: Jan 2007
mp_forcecamera 4rnmp_allowroaming 0rnrnrnWhat if you use above stated cvars in your server.cfg?rnrnAllowroaming set at 0 will people not be able to spec in free roam. The mp_forcecamera is set at 4, meaning you can only spec your own team
Threads: 18
Joined: Jan 2008
If this works I feel dumb lol. Hold on. Oh btw, by "your own team" does these settings remember what team you came from when you go spec? Or are you talking about between spawns.nnEdit: I can't seem to get the mp_allowroaming cvar to return anything, as if it didnt exist.
Threads: 59
Joined: Jan 2007
Im sorry, I should've read the whole story. This would work between spawns I guess. The cvars are taken from the configs from CAL so I figured mp_allowroaming should still work as a cvar.
Threads: 18
Joined: Jan 2008
Looks like it doesnt function anymore :/ Ive too seen it in cal configs and stuff.rnrn@ diamond-optic: Ive become comfortable with the plugins function and its kinda cool that it cycles through enemy team really fast before going back to own team. However, is there a possibility of getting spectator team to only be able to use e.g. locked chase cam?
Threads: 103
Joined: May 2005
well originally i did it in the player prethink, which was much faster (and a lot less cpu effecient lol) then using the 10th of a second repeating task, but it seemed to cause problems becuase it would detect viewing someone you shouldnt like 20 times a second and would freak out a bit cause it couldnt switch the view fast enough after first detecting itnnbut whatever it is that only allows you to view youre own team while on a team and dead could probably be faked while on spec, but as to what that is, i dont know lolnnn*edit*nni also hoped that setting the pev_iuser2 value would better for changing the current spectated player but it doesnt really work that way and things get wierd when doing that :(nnas for that cvar, i really dont think that exists myself.. the cal configs are full of cvars and such that dont exist, at least not in dod
Threads: 103
Joined: May 2005
oh yeah.. to fix that nonsense when using free look mode change:nn
if(g_specteam[id] != g_currteam[spec_id])to this:nnif(spec_id && g_specteam[id] != g_currteam[spec_id])Threads: 18
Joined: Jan 2008
Alrighty, I didnt get a chance to test this out before now. The free look cam thing was fixed but to the worse in regards of the plugins intention lol. (Its possible to use free look cam freely now) Is it possible to just allow 1 type of specator view? I.e. locked chase cam. :)

