Day of Defeat Plugins Community
This site is an archive — everything is readable and downloadable, nothing can be posted. Admin

Me spec / secret spectate

by blobby · 2007-09-09 · 37 replies · 22910 views · 158 downloads

Read the thread (38 posts)

From the first post

This is a simple plugin that you can type /mespec in chat or mespec in console and you will go into spectate but you seem to stay on your team to the rest of the players on your server
rn
rnMake sure you define your admin level where you see this line on the sma file
rn
rn
// Define your admin level it is required below ADMIN_LEVEL_H is a custom level//rn#define INVISIBILE_ADMIN ADMIN_LEVEL_HrnrnDo not change the INVISIBILE_ADMIN part on the ADMIN_LEVEL_H

rn
rnThe commands for this plugin are as follows:-
rn
rn
/mespecrnThis command is used in client chat or team chat to put you in secret specrnmespecrnThis is the console command that is used to put you in secret spec you can also bind this key as follows:-rnbind key mespecrndod_quickspec 1/0rnThis is the cvar to turn the plugin on and off 1 = on 0 = off

rn
rnI must thank feuersturm for all of his help during the making of this plugin and for getting the cvar to work for me and blocking the team message as you join back on to your team
rn
rnIf you have any questions just ask
rn
rnEnjoy my plugin and regards
rn
rnBlobby

Files

mespec.sma Plugin Source 3 KB 158 dl Download Compile

The thread

All 38 posts from 16 people on Me spec / secret spectate, kept as they were written.

blobby
started this thread
Posts: 421
Threads: 47
Joined: Apr 2007
09-09-2007, 08:14 AM #1

This is a simple plugin that you can type /mespec in chat or mespec in console and you will go into spectate but you seem to stay on your team to the rest of the players on your server rnrnMake sure you define your admin level where you see this line on the sma file rnrn

// Define your admin level it is required below ADMIN_LEVEL_H is a custom level//rn#define INVISIBILE_ADMIN ADMIN_LEVEL_HrnrnDo not change the INVISIBILE_ADMIN part on the ADMIN_LEVEL_H
rnrnThe commands for this plugin are as follows:-rnrn
/mespecrnThis command is used in client chat or team chat to put you in secret specrnmespecrnThis is the console command that is used to put you in secret spec you can also bind this key as follows:-rnbind key mespecrndod_quickspec 1/0rnThis is the cvar to turn the plugin on and off 1 = on 0 = off
rnrnI must thank feuersturm for all of his help during the making of this plugin and for getting the cvar to work for me and blocking the team message as you join back on to your teamrnrnIf you have any questions just askrnrnEnjoy my plugin and regardsrnrnBlobby

Garion
posted here
Posts: 93
Threads: 9
Joined: Nov 2005
09-11-2007, 11:49 PM #2

do you still show as on a team when someone joins the server? Reason I ask is if someone that knows you happens to join and asks why your on spec, wouldn't that give it away?

blobby
started this thread
Posts: 421
Threads: 47
Joined: Apr 2007
09-12-2007, 07:09 AM #3

No you still show as on your team even to people who connect to the server while you are using this you just show as dead :pnnalso i just need to add if you use the weaponmod where you type /weaponname you need to put the line mesepc.amxx above the weaponmod.amxx line because for some reason the weaponmod blocks the /mespec commands for this pluginnnIf you ahve any more questions just asknnRegardsnnBlobby

blobby
started this thread
Posts: 421
Threads: 47
Joined: Apr 2007
09-21-2007, 10:54 AM #4

Wooops ive spotted a bug on this if you are just about to respawn and you go to mespec you spawn in the dead center of any map with 1 nade ive been looking over the code just now after it happened to see if i could see any thing but i couldn't nni just did think tho could it be to do with thisn

dod_set_user_team(id, 3, 0)
nnIf any of you amazing coders can see any thing please let me know so i can fix thisnnRegardsnnBlobby

FeuerSturm
posted here
Posts: 166
Threads: 15
Joined: Jun 2007
09-21-2007, 11:50 AM #5

you could add a check if the player is alive when he uses the commandrnand deny it if he isn't, that should solve the problem.

blobby
started this thread
Posts: 421
Threads: 47
Joined: Apr 2007
09-21-2007, 12:28 PM #6

Riteo cheers Feuersturm im away from home atm but when i get back 2moz i will do that and post the update :p

blobby
started this thread
Posts: 421
Threads: 47
Joined: Apr 2007
10-13-2007, 01:54 PM #7

Woot 13 views

H Hood [10th MD]
posted here
Posts: 84
Threads: 7
Joined: Nov 2006
10-18-2007, 07:50 PM #8

looks good, i'll definitely give it a shot if i start running a server again.

D deathbringer1972
posted here
Posts: 9
Threads: 1
Joined: Oct 2007
11-07-2007, 08:41 PM #9

Props to you sir...:)

J jondoe
posted here
Posts: 129
Threads: 6
Joined: Aug 2005
11-08-2007, 05:52 PM #10

Your the man Blobby, Very nice work ;)

blobby
started this thread
Posts: 421
Threads: 47
Joined: Apr 2007
11-09-2007, 09:10 AM #11

Cheers jondoe

A Akula
posted here
Posts: 8
Threads: 0
Joined: Nov 2007
11-23-2007, 04:21 PM #12

Started using this plugin recently , and i must say its absolutely fantastic.rnrnA definate MUST HAVE for server admins.

blobby
started this thread
Posts: 421
Threads: 47
Joined: Apr 2007
11-24-2007, 09:16 AM #13

Im glad your happy with it mate if you can think of any improvements that could be made post them here for mennRegardsnnBlobby

blobby
started this thread
Posts: 421
Threads: 47
Joined: Apr 2007
12-02-2007, 11:41 PM #14

Little update so i can find out how many people are using this plugin so please if you sue this update to is rnrnRegardsrnrnblobby

WARDOG
posted here
Posts: 141
Threads: 14
Joined: Jan 2006
12-04-2007, 06:21 PM #15

Evidently there is a bug with this where if you go mespec after you died while playing, you can end up in the opposite teams spawn. One of my members has the details, check your code, he said it was an easy fix.rnrn I was just told about it so I will try to give you more info as soon as I know. Again this is a bug, not an error. Other than this, it is a very usefull plugin, thanks Blobby.

blobby
started this thread
Posts: 421
Threads: 47
Joined: Apr 2007
12-05-2007, 06:00 AM #16

Hey wardog yeah please do let me know about this also have you updayed to my new trackable version ??nnRegardsnnBlobby

E Equinox
posted here
Posts: 3
Threads: 0
Joined: Jun 2007
12-26-2007, 02:36 AM #17

Im having some trouble "defining my admin level". When it says admin level H does this mean I can add the custom level "h" to the users i wish to use this in users.ini? Any help would be appreciated, thanks alot in advance guysrnrnEquinox<^|SiNz|^>

Ba5ic
posted here
Posts: 181
Threads: 26
Joined: Nov 2005
12-26-2007, 06:31 AM #18

Just installed, works a treat. Nice job Blobby! :Prnrn+Karma :P

blobby
started this thread
Posts: 421
Threads: 47
Joined: Apr 2007
12-26-2007, 10:57 AM #19
Im having some trouble "defining my admin level". When it says admin level H does this mean I can add the custom level "h" to the users i wish to use this in users.ini? Any help would be appreciated, thanks alot in advance guysrnrnEquinox<^|SiNz|^>
rnrnrnYeah that means if you give the flag t to any of your members they will get the use of this plugin

diamond-optic
posted here
Posts: 2,068
Threads: 103
Joined: May 2005
12-27-2007, 04:50 AM #20
When it says admin level H does this mean I can add the custom level "h" to the users i wish to use this in users.ini?
nnADMIN_LEVEL_H is not equal to the "h" admin flag...nnheres what the constants are and what they equal:n
#define ADMIN_ALL        0    /* everyone */n#define ADMIN_IMMUNITY        (1<<0)    /* flag "a" */n#define ADMIN_RESERVATION    (1<<1)    /* flag "b" */n#define ADMIN_KICK        (1<<2)    /* flag "c" */n#define ADMIN_BAN        (1<<3)    /* flag "d" */n#define ADMIN_SLAY        (1<<4)    /* flag "e" */n#define ADMIN_MAP        (1<<5)    /* flag "f" */n#define ADMIN_CVAR        (1<<6)    /* flag "g" */n#define ADMIN_CFG        (1<<7)    /* flag "h" */n#define ADMIN_CHAT        (1<<8)    /* flag "i" */n#define ADMIN_VOTE        (1<<9)    /* flag "j" */n#define ADMIN_PASSWORD        (1<<10)    /* flag "k" */n#define ADMIN_RCON        (1<<11)    /* flag "l" */n#define ADMIN_LEVEL_A        (1<<12)    /* flag "m" */n#define ADMIN_LEVEL_B        (1<<13)    /* flag "n" */n#define ADMIN_LEVEL_C        (1<<14)    /* flag "o" */n#define ADMIN_LEVEL_D        (1<<15)    /* flag "p" */n#define ADMIN_LEVEL_E        (1<<16)    /* flag "q" */n#define ADMIN_LEVEL_F        (1<<17)    /* flag "r" */n#define ADMIN_LEVEL_G        (1<<18)    /* flag "s" */n#define ADMIN_LEVEL_H        (1<<19)    /* flag "t" */n#define ADMIN_MENU        (1<<20)    /* flag "u" */n#define ADMIN_ADMIN        (1<<24)    /* flag "y" */n#define ADMIN_USER        (1<<25)    /* flag "z" */
E Equinox
posted here
Posts: 3
Threads: 0
Joined: Jun 2007
12-29-2007, 03:15 PM #21

So, I gave one member full admin to the server (same level as mine) and had him test the mespec plugin. He was unable to use it. He had access flags a-u and after typing "mespec" into his console, was told that he did not have access to that command. I checked to make sure I set his access flags correctly, and I did. Is there any help or advice for this? rnrnThanks guys,rnrnOxrnrnp.s. new version of vBulletin looks nice!

blobby
started this thread
Posts: 421
Threads: 47
Joined: Apr 2007
12-30-2007, 02:12 PM #22

Yeah he needs the admin flag t to make mespec work or you can change the flag needed to use this in the plugins source codennRegardsnnBlobby

{DwP} 325th ABN
posted here
Posts: 231
Threads: 12
Joined: Aug 2006
12-30-2007, 11:54 PM #23

nice job blooby i like it works good for me

blobby
started this thread
Posts: 421
Threads: 47
Joined: Apr 2007
12-31-2007, 01:01 AM #24

Thanks m8 glad u like it

WARDOG
posted here
Posts: 141
Threads: 14
Joined: Jan 2006
02-09-2008, 05:35 AM #25

Ok Blobby, sorry I have not replied here sooner. the bug with your plugin is, if you type mespec in consol after you die while playing, and submit the command right before you spawn, you can spawn in the opposite teams spawn as one of them, and get killed by them counting as a team kill.

H Hood [10th MD]
posted here
Posts: 84
Threads: 7
Joined: Nov 2006
03-11-2008, 07:06 PM #26

If you're still having problems with death, check if the user is alive before specing them - either put this in with the cvar check, or be sneaky and put it before the team switch, and just have an event that catches spawn, and if you're supposed to be specing, it'll switch you automatically.nThat's a little more complicated than the 2 minutes I'm taking to post this - but the fix would simply be to find the linen

if(get_pcvar_num(p_me_spec)==1)
nand replace it withn
if(get_pcvar_num(p_me_spec)==1&&is_user_alive(id)==1)
nand if you'd like to inform people why they don't get switched when they're dead, add
||is_user_alive(id)==0
to the end of the else if statement following the above block.nnto catch spawn, you'd need to register the event, and then create a function to put them in spec if inSecretSpec[id]==1nnHope that helps. I'm putting the plugin on tonight, if I have any problems, I'll let you know.

blobby
started this thread
Posts: 421
Threads: 47
Joined: Apr 2007
03-30-2008, 04:26 PM #27

ill get round to fixing this in the next few days and will repost it up thanks for spotting that :P

H Hood [10th MD]
posted here
Posts: 84
Threads: 7
Joined: Nov 2006
03-31-2008, 05:19 PM #28

Ah, forgot feedback - works well, I don't particularly need it and I modified it a bit beyond what I actually should've, but it worked great! Excellent plugin for admins!

G gunsofnavarone
posted here
Posts: 159
Threads: 28
Joined: Sep 2008
11-29-2008, 11:24 AM #29

OK, I must be a nitwit or something. What exactly does "Make sure you define your admin level where you see this line on the sma file" mean? rnrn1) Define how? or To what? Am I modifying the sma file to reflect something else? rnrn2) Or is my "definition" supposed to be elsewhere?rnrnMy user.ini file reads this:rnrn; Users configuration filern; File location: $moddir/addons/amxmodx/configs/users.inirnrn; Line starting with ; is a commentrnrn; Access flags:rn; a - immunity (can't be kicked/baned/slayed/slapped and affected by other commmands)rn; b - reservation (can join on reserved slots)rn; c - amx_kick commandrn; d - amx_ban and amx_unban commandsrn; e - amx_slay and amx_slap commandsrn; f - amx_map commandrn; g - amx_cvar command (not all cvars will be available)rn; h - amx_cfg commandrn; i - amx_chat and other chat commandsrn; j - amx_vote and other vote commandsrn; k - access to sv_password cvar (by amx_cvar command)rn; l - access to amx_rcon command and rcon_password cvar (by amx_cvar command)rn; m - custom level A (for additional plugins)rn; n - custom level Brn; o - custom level Crn; p - custom level Drn; q - custom level Ern; r - custom level Frn; s - custom level Grn; t - custom level Hrn; u - menu accessrn; z - user (no admin)rnrn; Account flags:rn; a - disconnect player on invalid passwordrn; b - clan tagrn; c - this is steamid/wonidrn; d - this is iprn; e - password is not checked (only name/ip/steamid needed)rnrn; Password:rn; Add to your autoexec.cfg: setinfo _pw "<password>"rn; Change _pw to the value of amx_password_fieldrnrn; Format of admin account:rn; <name|ip|steamid> <password> <access flags> <account flags>rnrn; Examples of admin accounts:rn; "STEAM_0:0:123456" "" "abcdefghijklmnopqrstu" "ce"rn; "123.45.67.89" "" "abcdefghijklmnopqrstu" "de"rn; "My Name" "my_password" "abcdefghijklmnopqrstu" "a"rnrnrnrn"STEAM_0:1:17790757" "" "abcdefghijklmnopqrstu" "ce"rnrnrn; "loopback" "" "abcdefghijklmnopqrstu" "de"rnrnrnWhen I use the command via bind (bind "F4" "say /mespec"), it shows:rnrn"You have no access to that command"rnrnWhen I type in console amx_who it shows:rnrnGunsOfNavarone STEAM_0:1:17790757 10 Yes Yes abcdefghijklmnopqrsurnrnIs this plugin blocking my "t" access, because it doesn't show as indicated above (...pqrsu)?!?

Dr.G
posted here
Posts: 776
Threads: 75
Joined: Nov 2007
11-29-2008, 09:09 PM #30

Look inside the sma (source) file. Read line 22 and 23 might help ya..

Tank
posted here
Posts: 581
Threads: 59
Joined: Jan 2007
11-30-2008, 09:07 AM #31

At the moment it is set for flag t.rnrnWhat you do is download the sma file. Open it with any text editor (wordpad or notepad is ok). Now you look for this line:rnrn

// Define your admin level it is required below ADMIN_LEVEL_H is a custom level//rn#define INVISIBILE_ADMIN ADMIN_LEVEL_H
rnrnRemember admin_level_h is not flag H. This website contains a list with admin flags and admin levels. admin_level_h IS flag T. That is why it doesn't work for you. You could for example change it tornrn
// Define your admin level it is required below ADMIN_LEVEL_H is a custom level//rn#define INVISIBILE_ADMIN ADMIN_LEVEL_G
rnrnAbove stated will change it to flag S and will make it work for you. Good luck and if you need anything, just holla at us :D

G gunsofnavarone
posted here
Posts: 159
Threads: 28
Joined: Sep 2008
11-30-2008, 09:39 AM #32

Thank you so very much for the direct response. I guess my "real" problem is elsewhere.rnrnAs I indicated "t" is clearly defined within the user.ini file. So, somewhere along the line, the server is blocking it or simply not recognizing it as was indicated by the response from the amx_who command.rnrnIf I read your response correctly, since "t" was defined in my user.ini file, then I shouldn't have to modify the existing code at all.rnrnThank you again for your reply. Now I've got to figure out what's causing the "t" flag to not be recognized.

Tank
posted here
Posts: 581
Threads: 59
Joined: Jan 2007
11-30-2008, 09:56 AM #33

I'm sorry, I clearly didn't read your post properly. I'll load this plugin on my test server and see if I have the same issue.

G gunsofnavarone
posted here
Posts: 159
Threads: 28
Joined: Sep 2008
11-30-2008, 12:07 PM #34

I have found my problem (sort of) and a work around.rnrnFirst, it's not the plugin. With the plugin remarked out, and the server restarted, when I enter amx_who it STILL does not show the "t" flag. This tells me it's something serverside that's interfering/ignoring the settings defined in the user.ini file.rnrnMy work around was to modify the cmdaccess.ini file. The last entry in it was for mespec which indicated the "t" flag. I simply (and arbitrarily) changed the flag to "g". It now works for me.rnrnSo, I have some serverside issues I need to contend to as I am finding out. So I've put in a support ticket.rnrnThank you for your help nonetheless.

{ {HK}recon'de'sprayer
posted here
Posts: 23
Threads: 1
Joined: Sep 2006
04-02-2020, 04:22 PM #35

How do you get the menu which allows you to turn items on/off. For example if I did not want to see how far away I can turn it off but I need the menu to do so. How do I get the menu up. I have looked through the files for a text doc to tell me this but can not find one. Would someone point me in the right direction?

diamond-optic
posted here
Posts: 2,068
Threads: 103
Joined: May 2005
04-12-2020, 05:01 PM #36
How do you get the menu which allows you to turn items on/off. For example if I did not want to see how far away I can turn it off but I need the menu to do so. How do I get the menu up. I have looked through the files for a text doc to tell me this but can not find one. Would someone point me in the right direction?
rnrnrnNot quite sure what you are trying to ask here.. it doesn't seem to have anything to do with this plugin...

{ {HK}recon'de'sprayer
posted here
Posts: 23
Threads: 1
Joined: Sep 2006
04-13-2020, 03:21 PM #37

I don't know if this happens for everyone with this plugin, but when I execute it from the console I can also get a menu which only comes up when I am in first person snd select a key to activate the menu. (I checked my config file and do not find a mespec menu assigned to the key I use) Once the menu comes up I can turn off/on such things as distance, name, weapon, etc. That is what I am asking. How do you assign a key to get the menu. I have checked all the files that came with mespec to see if it is explained, but no luck.

diamond-optic
posted here
Posts: 2,068
Threads: 103
Joined: May 2005
04-14-2020, 02:55 PM #38

That must be another plugin.rnrnI looked at the code for this one and all it seems to do is force your team to spectator and block the chat message that is printed for changing teams

DoD Plugins Archive · Repository · Old Forum Threads · Maps · Admin · built 14 Sep 2026 00:34 UTC