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

DoD Force Tracers (v1.0)

by diamond-optic · 2006-07-22 · 27 replies · 12849 views · 65 downloads

Read the thread (28 posts)

From the first post

DoD Force Tracers
n- Version 1.0
n- 04.06.2008
n- diamond-optic
n
nCredits:
n
- Wilson [29th ID] for the new method of locking the cmdsn- Zor, teame06, and the others from #amxmodx that helped me
Information:
n
- Force all clients to use your tracer settings
CVARs & Commands:
n
dod_forcetracers //Turn on(1)/off(0) forcing of tracer settingsndod_reloadtracers //Manually force tracer settings to clients (use after making changes ingame, OLD_METHOD define must be 1)n// n//These control what values are set to the client:n dod_traceralpha "0.35"n dod_tracerblue "2.50"n dod_tracergreen "0.5"n dod_tracerlength "1.5"n dod_traceroffset "10"n dod_tracerred "0.5"n dod_tracerspeed "1000"
Extra:
n
Change OLD_METHOD define:n 0 = new method (more effecient)n 1 = old method (allow on the fly changing)
Version Info:
n
- 12.19.2005 Version 0.0an    actually got it to work lol...n    fixed testing bugsnn- 12.21.2005 Version 0.0bn    added cvar "dod_forcetracers"n    removed extra testing codenn- 12.25.2005 Version 0.1n    added cvar's for each tracer settingn    removed client_print linesnn- 01.11.2006 Version 0.2n    catches respawn to reforce settingsnn- 03.05.2006 Version 0.3n    updated to 1.70 CVAR pointersnn- 03.15.2006 Version 0.4n    added dod_reloadtracers to manually force tracer settingsnn- 04.18.2006 Version 0.5n    dont bother if they're not connected or botsnn- 06.07.2006 Version 0.6n    fixed some mistakes with the return valuesnn- 07.24.2006 Version 0.6bn    cleaned up code a bitnn- 08.28.2006 Version 0.7n    much better way of locking cmds (thanks Wilson [29th ID])n    added OLD_METHOD define for selecting method of setting tracersn    changed some returnsnn- 04.06.2008 Version 1.0n    Code Improvements
DOWNLOAD MIRROR: http://www.avamods.com/download.php?view.42

Files

dod_forcetracers.sma Plugin Source 6 KB 65 dl Download Compile

Archived builds from the server loose

These compiled builds sat loose in the server's script folder rather than attached to a post. They are matched to this release by comparing their decompiled Pawn against the source published above, so treat the attribution as strong but not certain. Versions come from the register_plugin() call recovered from the bytecode.

dod_forcetracers_597.sma v0.6 4 KB Download Compile
dod_forcetracers_930.sma v0.4 4 KB Download Compile

The thread

All 28 posts from 7 people on DoD Force Tracers (v1.0), kept as they were written.

diamond-optic
started this thread
Posts: 2,068
Threads: 103
Joined: May 2005
07-22-2006, 12:54 AM #1

DoD Force Tracersn- Version 1.0n- 04.06.2008n- diamond-opticnnCredits:n

n- Wilson [29th ID] for the new method of locking the cmdsn- Zor, teame06, and the others from #amxmodx that helped men
Information:n
n- Force all clients to use your tracer settingsn
CVARs & Commands:n
ndod_forcetracers //Turn on(1)/off(0) forcing of tracer settingsndod_reloadtracers //Manually force tracer settings to clients (use after making changes ingame, OLD_METHOD define must be 1)n// n//These control what values are set to the client:n dod_traceralpha "0.35"n dod_tracerblue "2.50"n dod_tracergreen "0.5"n dod_tracerlength "1.5"n dod_traceroffset "10"n dod_tracerred "0.5"n dod_tracerspeed "1000"n
Extra:n
nChange OLD_METHOD define:n 0 = new method (more effecient)n 1 = old method (allow on the fly changing)n
Version Info:n
n- 12.19.2005 Version 0.0an    actually got it to work lol...n    fixed testing bugsnn- 12.21.2005 Version 0.0bn    added cvar "dod_forcetracers"n    removed extra testing codenn- 12.25.2005 Version 0.1n    added cvar's for each tracer settingn    removed client_print linesnn- 01.11.2006 Version 0.2n    catches respawn to reforce settingsnn- 03.05.2006 Version 0.3n    updated to 1.70 CVAR pointersnn- 03.15.2006 Version 0.4n    added dod_reloadtracers to manually force tracer settingsnn- 04.18.2006 Version 0.5n    dont bother if they're not connected or botsnn- 06.07.2006 Version 0.6n    fixed some mistakes with the return valuesnn- 07.24.2006 Version 0.6bn    cleaned up code a bitnn- 08.28.2006 Version 0.7n    much better way of locking cmds (thanks Wilson [29th ID])n    added OLD_METHOD define for selecting method of setting tracersn    changed some returnsnn- 04.06.2008 Version 1.0n    Code Improvementsn
DOWNLOAD MIRROR: http://www.avamods.com/download.php?view.42

diamond-optic
started this thread
Posts: 2,068
Threads: 103
Joined: May 2005
07-24-2006, 10:32 PM #2

meaningless update, but i want mark it as up to date on my hd...nn

n- 07.24.2006 Version 0.6bn cleaned up code a bitn
M Morimoto
posted here
Posts: 11
Threads: 1
Joined: Nov 2005
08-15-2006, 04:17 PM #3

forgive me, but why would u want to force players to use your tracer settings?

diamond-optic
started this thread
Posts: 2,068
Threads: 103
Joined: May 2005
08-15-2006, 09:27 PM #4

becuase then you can make everyone see the same tracers.. like for example you can set it so that tracers are whatever color you want, move at whatever speed you want.. and are as long as you want..nnjust a little something to give you that extra bit of control on your server

=|[76AD]|= TatsuSaisei
posted here
Posts: 794
Threads: 54
Joined: May 2005
08-15-2006, 09:36 PM #5

another reason is this... players can turn tracers to whatever they want (without a plugin like this in effect) and could make them so colorful and long that it becomes very easy to pinpoint the mgs location.... if everyone was forced to have the same tracer setting then that specific advantage is gone... making for a much more balanced game.. while also giving your server that custom feel....

Wilson [29th ID]
posted here
Posts: 623
Threads: 57
Joined: Oct 2005
08-16-2006, 03:18 AM #6

Oh jeeze I just now looked at your code; there's a much easier way of doing this. Right now, you have a loop that sets the clients tracers to whatever you desire every 5.0 "seconds" Theoretically, this way, a client could press a button to set them back to normal every time this happens. I know this isn't something someone would actually do but regardless the loop itself, in theory, takes processing power.rnrnCheck this out.rn

rnpublic plugin_init() {rn   register_concmd("blockcmd", "block_cmd")rn   register_cvar("blocktracers", "1")rn   // Register cvars for tracer colours herern}rnrnpublic client_connect(id) {rn   if(get_cvar_num("blocktracers")) {rn      FuncBlockTracers(id)rn   }rn}rnrnstock FuncBlockTracers(id) {rn   // Sets desired "traceralpha"rn   client_cmd(id,"traceralpha %f",get_pcvar_float(p_dod_traceralpha))rnrn   // Blocks client from adjusting "traceralpha" until they restart dodrn   client_cmd(id,"alias traceralpha blockcmd")rnrn   // Do the same for the rest of themrn}rnrnpublic block_cmd(id) {rn   client_print(id, print_console, "Command Blocked")rn   return PLUGIN_HANDLEDrn}
rnrnBasically, it's setting the desired client commands, then rerouting the command itself to "blockcmd," which does nothing but print "Command Blocked" in the client's console.rnrnOnce the client restarts dod, the command will be rerouted back to its normal function (unless of course he enters your server again in which case it will be re-re-rerouted back to "blockcmd" :-P

diamond-optic
started this thread
Posts: 2,068
Threads: 103
Joined: May 2005
08-16-2006, 10:09 AM #7

hmm i thought i tried that when i 1st made it and it didnt work.. maybe i messed it up..nnill give it a try when i get home from work if i get a chance.. tho not sure if im gonna be around.. i leave for a 4 day music festival and wont be back to sunday/monday

=|[76AD]|= TatsuSaisei
posted here
Posts: 794
Threads: 54
Joined: May 2005
08-16-2006, 10:20 AM #8
i leave for a 4 day music festival and wont be back to sunday/monday
nwhich festival would that be ??

diamond-optic
started this thread
Posts: 2,068
Threads: 103
Joined: May 2005
08-16-2006, 10:28 AM #9

http://www.gatheringofthevibes.com/nnand im gonna try and catch a ride from there out to PA, somewhere a little north of pittsburgh for stevie guitar miller :-P

=|[76AD]|= TatsuSaisei
posted here
Posts: 794
Threads: 54
Joined: May 2005
08-16-2006, 10:36 AM #10
http://www.gatheringofthevibes.com/n nand im gonna try and catch a ride from there out to PA, somewhere a little north of pittsburgh for stevie guitar miller :-P
nawesome, I havnt been able to go out since my kids were born... I used to do the Phish thing with friends... (was not much of a Phish fan, but I LOVED the people, and I love to party)

diamond-optic
started this thread
Posts: 2,068
Threads: 103
Joined: May 2005
08-16-2006, 09:35 PM #11

heh since this is my thread, going off-topic with this subject matter is fine with me.. nni miss phish lol.. nothing like those shows.. well maybe if i had seen the grateful dead i would say something different.. lol.. i saw GRAB (Mike Gordon, Joe Russo, Trey Anastasio, and Marco Benevento) which was great.. they opened for phil lesh & friends.. which i was an alright show.. got better when trey played with them..

diamond-optic
started this thread
Posts: 2,068
Threads: 103
Joined: May 2005
08-22-2006, 02:54 PM #12

hey wilson that doesnt seem to work..nni can still change the values and i dont get the command blocked print out either :-(nnbut i manually put the alias in my console.. it blocks it then.. so it seems like amxx isnt setting the alias on the clientnn*edit*nnits giving me this for each one:n

Server tried to send invalid command:"alias tracerblue blockcmd"
nnthen on amxmodx's irc channel:n
<@Basic-Master> you can't register aliases using client_cmd
Wilson [29th ID]
posted here
Posts: 623
Threads: 57
Joined: Oct 2005
08-22-2006, 05:30 PM #13

No - you definitely can do it it has worked for me before. I learned it from FURAX44's code - check this out and you can see what's going on. This works.rnrn

#include <amxmodx> rnrnnew g_BlockCheck[33]    rnnew g_BlockIcon rnrnpublic plugin_init() { rn  register_plugin("RealismGuard","0.0.2","FURAX44 & Cpt.Wilson") rn  register_cvar("realism_guard","0") rn  register_clcmd("block_identiconmode","Used_identiconmode",0,"- Icon Identification & HUD is blocked by server") rn} rnrnpublic plugin_cfg() rn{ rn  g_BlockIcon = get_cvar_num("realism_guard") rn} rnrnpublic client_connect(id){ rn  if (g_BlockIcon==1) BlockIconOnClient(id) rn}    rnrnstock BlockIconOnClient(id) rn{ rn   g_BlockCheck[id] = 1 rn   client_cmd(id,"cl_identiconmode  0;alias cl_identiconmode block_identiconmode;cl_hud_health 0;alias cl_hud_health block_identiconmode;cl_hud_ammo 0;alias cl_hud_ammo block_identiconmode;cl_hud_objtimer 0;alias cl_hud_objtimer block_identiconmode;cl_hud_reinforcements 0;alias cl_hud_reinforcements block_identiconmode;cl_dmshowplayers 0;alias cl_dmshowplayers block_identiconmode;cl_dmsmallmap 0;alias cl_dmsmallmap block_identiconmode") rn   g_BlockCheck[id] = 0 rn} rnrnrnpublic Used_identiconmode(id){ rn   if (g_BlockCheck[id] == 1) return PLUGIN_CONTINUE rn   new Name[32] rn   get_user_name(id,Name,31) rn   server_print("Client %d %s try to change identiconmode",id,Name) rn   return PLUGIN_HANDLED rn} 
diamond-optic
started this thread
Posts: 2,068
Threads: 103
Joined: May 2005
08-22-2006, 10:34 PM #14

wierd lol.. played around with it a bit and got it to work lol..nnthanks a ton!

diamond-optic
started this thread
Posts: 2,068
Threads: 103
Joined: May 2005
08-22-2006, 10:57 PM #15

ok only problem im having now is the dod_reloadtracers command..nnwhich is supposed reforce the settings to clients incase you decide to change them while mid-game...nnit comes up with them all being blocked..nnany ideas?

tegu
posted here
Posts: 191
Threads: 11
Joined: Aug 2006
08-27-2006, 04:50 PM #16

How would I set it to show the tracers all the time? I was at a server today that showed some very nice yellow tracers on all weapons. It was great. I would like to turn that on here. I so far have noticed nothing with this plugin......

diamond-optic
started this thread
Posts: 2,068
Threads: 103
Joined: May 2005
08-27-2006, 07:43 PM #17

i could change my pistol tracers plugin to use cvars to select which weapons get tracers

Wilson [29th ID]
posted here
Posts: 623
Threads: 57
Joined: Oct 2005
08-27-2006, 09:42 PM #18

diamond, you cannot change them midgame...well you can but every client would have to exit day of defeat and rejoin.rnrnit re-aliases the client commands so they dont' get reset until they rejoin.rnrntegu, what server was it? I'd love to see that in action.

diamond-optic
started this thread
Posts: 2,068
Threads: 103
Joined: May 2005
08-27-2006, 09:50 PM #19

well ya i realize that..nnbut i kinda like how i have it now, cause alot of time i like changing them around in mid-game..nn:-(

tegu
posted here
Posts: 191
Threads: 11
Joined: Aug 2006
08-28-2006, 12:44 AM #20
i could change my pistol tracers plugin to use cvars to select which weapons get tracers
rnWould you mind doing that for me as I am coding illiterate and am just now beginning to operate a server. rnOR.... Tell me more detailed in what I have to do and I will attempt it?? :eek: rnrnYou can contact me direct if you prefer @ tegulizard@gmail.comrnrnGreat work btw diamond

diamond-optic
started this thread
Posts: 2,068
Threads: 103
Joined: May 2005
08-28-2006, 02:36 PM #21

it wont be hard to do at all.. and ill try to get around to it a little later today...

tegu
posted here
Posts: 191
Threads: 11
Joined: Aug 2006
08-28-2006, 06:41 PM #22

Thanks Diamond!

diamond-optic
started this thread
Posts: 2,068
Threads: 103
Joined: May 2005
08-28-2006, 09:00 PM #23

version 0.7nn

- 08.28.2006 Version 0.7n much better way of locking cmds (thanks Wilson [29th ID])n added OLD_METHOD define for selecting method of setting tracersn changed some returns
K knife108
posted here
Posts: 108
Threads: 10
Joined: Apr 2006
09-14-2007, 12:30 AM #24

nice plugin!rnrnGo on D.O :p

P politvs
posted here
Posts: 7
Threads: 0
Joined: Apr 2007
02-06-2008, 01:23 PM #25

Hi!nnThe plugin is very nice and working well here, but what I'd really like to see is separte color per team... Could it be possible?nnThanks!nn<PoLiTvS>

diamond-optic
started this thread
Posts: 2,068
Threads: 103
Joined: May 2005
07-27-2008, 07:50 PM #26

updated to v1.0nn

n- 04.06.2008 Version 1.0n    Code Improvementsn
K knife108
posted here
Posts: 108
Threads: 10
Joined: Apr 2006
09-16-2008, 12:16 AM #27

Does this one should work with DoD Tracers ?

diamond-optic
started this thread
Posts: 2,068
Threads: 103
Joined: May 2005
09-16-2008, 02:12 AM #28

hmm its been a while since ive used that one but i believe it does.. give it a try :)

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