Home   Help Search Login Register  

Author Topic: RealTracer V.9b  (Read 9335 times)

0 Members and 1 Guest are viewing this topic.

Grendel

  • Guest
RealTracer V.9b
« on: 12 Jun 2005, 18:15:15 »
Howdy All,

The Demo as promised...

This script adds some improved drop created tracer effects (reminds me of the MG34 in Red Orchestra MOD for UT2k4 but with ricochets!).

Enjoy!

-Grendel




Offline penguinman

  • Contributing Member
  • **
  • Money is worthless, just paper, ink, and threads
Re:RealTracer V.9b
« Reply #1 on: 12 Jun 2005, 18:34:24 »
I gotta try this! ;)

Offline Nemesis6

  • Members
  • *
Re:RealTracer V.9b
« Reply #2 on: 12 Jun 2005, 18:41:03 »
Changing the cl_fired particles to "obrysove svetlo" and "koulesvetlo" makes this look even better.

drop ["obrysove svetlo", "", "Billboard", 1,.05, [0,0,0], [0,0,0], 0, 5, 1, 0, [_ts],[[_r,_g,0,1],[_r,_g,0,1]],[0],0,0,"","",_missile]
drop ["koulesvetlo", "", "Billboard", 1,.05, [0,-.01,0], [0,0,0], 0, 5, 1, 0, [_ts/2],[[_r2,_g2,_b,1],[_r2,_g2,_b,1]],[0],0,0,"","",_missile]

Also changed the opacity of the particles to 1. Now this looks absolutely perfect. I guess the next step is bug finding and compatability, meaning that these effects come with you fire anything, so that's gotta be fixed I guess.
I am actually flying into a star... this is incredible!

Offline penguinman

  • Contributing Member
  • **
  • Money is worthless, just paper, ink, and threads
Re:RealTracer V.9b
« Reply #3 on: 12 Jun 2005, 18:56:46 »
ok i tried it, it looks good.

1st off, lmao at the disclaimer in the readme, best one ive ever read ;D

only problems I have with the script are, that the tracers richoche way to far imo, they fly like 150 feet in the air from where they hit. maby shorten the distance they richoche.

also, they look alot better than most and i like the composite thing, but they are still a little bulbus imo. here is a picture of m-16 tracers as they would look from the firers perspective






and how would i get a BAS mh60L to have blue tracers for its minigun with your script?
« Last Edit: 12 Jun 2005, 19:30:54 by penguinman »

Grendel

  • Guest
Re:RealTracer V.9b
« Reply #4 on: 12 Jun 2005, 20:25:18 »
Quote
maby shorten the distance they richochet

Easy to do, but believe it or not those suckers can ricochet pretty high in real life ( I can make it a rarer occurance though).

Quote
also, they look alot better than most and i like the composite thing, but they are still a little bulbus imo. here is a picture of m-16 tracers as they would look from the firers perspective

Yeah, but I had to balance a lot of issues, like visibility at long range, and the '3D' scaling effect...

And in the pic, the camera is slightly offset from the tracer which will make it look linear...In real life they appear as points to the firer, trust me on this.

Quote
and how would i get a BAS mh60L to have blue tracers for its minigun with your script?


I'll see what I can do, although I'm not sure if it will look good due to the way the rounds are usually created at an angle to the firers line of sight.

And here is the new script with one small but signifigant change: It now uses Nemisis6's suggested drop particles instead of the basic 'fired" ones.  This does look much nicer BTW thanks Nemisis6!


Offline penguinman

  • Contributing Member
  • **
  • Money is worthless, just paper, ink, and threads
Re:RealTracer V.9b
« Reply #5 on: 12 Jun 2005, 21:38:40 »
Quote
Yeah, but I had to balance a lot of issues, like visibility at long range, and the '3D' scaling effect...

And in the pic, the camera is slightly offset from the tracer which will make it look linear...In real life they appear as points to the firer, trust me on this.

well, yes to the firer they look like a dot but to everybody else it looks kinda like a shooting star, with a central dot, and a long tail, if you made yours with a smaller central dot but added a streaking tail, you wouldnt lose any visibility of the tracer, and it would look the same to the firer because he is looking at it from behind and wont see the streak.



Grendel

  • Guest
Re:RealTracer V.9b
« Reply #6 on: 12 Jun 2005, 21:46:34 »
Quote
if you made yours with a smaller central dot but added a streaking tail, you wouldnt lose any visibility of the tracer, and it would look the same to the firer because he is looking at it from behind and wont see the streak

Unfortunately, untill OFP or ArAs can update bullet positions faster within a script, anyone looking from the side would only see a dot every 20 meters or so...the script just cant do it fast enough (many have tried to work around this)

But the good news is, I did up a special version for you replete with blue(!) minigun tracers (less richocets and less chance of really high ones BTW) for the BAS MH-60K's minigun...I also added an improved effect for the dust kick up a minigun creates at the 'beaten zone' of round impact...

Enjoy!

-Grendel

EDIT: I might just have a work around for the streak...stay tuned
« Last Edit: 12 Jun 2005, 21:51:25 by Grendel »

DBR_ONIX

  • Guest
Re:RealTracer V.9b
« Reply #7 on: 12 Jun 2005, 22:03:55 »
Theres a lighting thing in dialouge-drop (can't remeber the name, my Checz isn't great :P), if used right could make okay trail
Ah, just found the tracer thingy Y2K3 uses : http://ofp.gamezone.cz/index.php?showthis=7665
Not tried your one, so can't make any compraisons, going to sort that now :P
- Ben

Grendel

  • Guest
Re:RealTracer V.9b
« Reply #8 on: 12 Jun 2005, 23:44:42 »
Wow, this thing consuming more time from my main project than I would like...but its pretty fun to play around with...

Here is a new zip with trails for the tracers fired by other units! It looks alright for a first try in my most humble opinion.

As far as wolfbane's tracers...mine does at least one new thing that I see right away: The composite particles make for much prettier tracers...and if you count the new trail thingies theres another thing I guess.

The new mission uses BAS ranger/delta and the BAS MH-60--EDIT-- and BAS OPFOR apparantly (sorry will post a cleaned up mission when I get a chance to fix a few other things)...if you have those ::), check it out.

-Grendel

EDIT RealTracer Trail Test V.92b.zip deleted due to a bug that has been corrected...new V.93 pending release...Please make due with V.91b untill then, sorry.
« Last Edit: 13 Jun 2005, 20:12:42 by Grendel »

Offline penguinman

  • Contributing Member
  • **
  • Money is worthless, just paper, ink, and threads
Re:RealTracer V.9b
« Reply #9 on: 13 Jun 2005, 00:01:25 »
wow, cool thanks,

i tried it but it says I dont have addon "BAS_deraJ"

i really want to try the script so what is that addon and where can I find it. or if thats to hard, how would I set up my own mission with the scripts. Is the init needed? or can u use a trigger.

also if its hard to do the trail, you could just setpos the tracer on the bullet and give it the same velocity. then it would take the same path as the bullet but could go at its own pace.


edit: o NM, i was talking about the special one u made for me, but i guess that BAS deltas rangers is "BAS_DeraJ"


wow, its so great. how do i set that up with a trigger in a mission? is it possible.

and i would like to try the one with the tail but why does it need opfor. why does it need any BAS addons? :)

great script,

thanks


« Last Edit: 13 Jun 2005, 00:26:28 by penguinman »

Grendel

  • Guest
Re:RealTracer V.9b
« Reply #10 on: 13 Jun 2005, 01:48:59 »
Quote
and i would like to try the one with the tail but why does it need opfor. why does it need any BAS addons

It doesn't...I just forgot to clean up the mission.sqm :-[.

If you want to do it in your own mission, just copy the marked lines from the demo init into your init, and put the realtracer.sqs in your mission's folder.  Define the units to use tracers by giving them all the eventhandler "fired" from the init (you can do this manually, use the foreach cammand, or use a trigger-whichever works best for you).

The Alpha will have all this set up and some more tricks as I can code them/think of them.  This thing is less than 24 hours old and has evolved alot already so sorry if things are a bit cobbled together at this point.

-Grendel

Offline Pilot

  • Contributing Member
  • **
Re:RealTracer V.9b
« Reply #11 on: 13 Jun 2005, 19:19:13 »
I just tried out the script.  I like it.  I do have two questions/comments:

1: I tried the script with a sniper rifle.  I noticed that even if the tracer hits a man, it still ricochets (is that how you spell it? :P) off of him.  Is there a way to check if the tracer hit a man and then delete it so it doesn't ricochet?

2: Do tracers really ricochet that high? :o  

3: In reality, does every tracer ricochet on impact?

-Student Pilot

EDIT:
Ok, I have a few moe observations:

In my attempts to break the script, I have discovered:
Rockets, grenades, mortars, and hand grenades all have tracers attached to them in the pattern the bullets have.  Every third shot fired seems to have a tracer no matter what kind of weapon fired it.

Also, I don't get the tracers flying through the air, they only appear on impact with the ground
« Last Edit: 13 Jun 2005, 19:34:30 by Student Pilot »

Grendel

  • Guest
Re:RealTracer V.9b
« Reply #12 on: 13 Jun 2005, 19:44:29 »
Quote
Is there a way to check if the tracer hit a man and then delete it so it doesn't ricochet?

I'm reasonably certain I can fix this. BTW sniper rifles won't have tracers in the final release unless you want them to ;)

Quote
Do tracers really ricochet that high

Yep!  When you figure the bullet is travelling a couple of tousands of feet per second or so, after they ricochet they still have enough energy to go pretty high.

Quote
In reality, does every tracer ricochet on impact

No, not all of them. I am still trying to work out some more random hit effects:  Some tracers completely disintegrate on impact with a hard surface (and kind of splatter into sparks), others will thump into the dirt and finish burning out (they kind of look like a burning road flare).  I 'm pretty sure I can pull these off.

-Grendel

I am going to release V.93b tonight which fixes a lot of things like:
automaticly adding the EH to units on mission start...
The tracer size calculations have been streamlined...
Tracers will only show for weapons added to the init arrays...
The trails for other unit's tracers have been improved.

Student Pilot: Which version were you testing?  The trail test version has a strange bug that I have since sorted out.


« Last Edit: 13 Jun 2005, 19:52:14 by Grendel »

Offline Pilot

  • Contributing Member
  • **
Re:RealTracer V.9b
« Reply #13 on: 13 Jun 2005, 20:06:14 »
Quote
BTW sniper rifles won't have tracers in the final release unless you want them to
I didn't think sniper rifles had tracers, I guess I was just using it to test the tracers

Quote
Yep!  When you figure the bullet is travelling a couple of tousands of feet per second or so, after they ricochet they still have enough energy to go pretty high.
Good point :P

Quote
Student Pilot: Which version were you testing?  The trail test version has a strange bug that I have since sorted out.
I am using V.91B

Grendel

  • Guest
Re:RealTracer V.9b
« Reply #14 on: 13 Jun 2005, 20:33:39 »
Quote
I didn't think sniper rifles had tracers, I guess I was just using it to test the tracers

Very rarely, we will use them to mark targets for mass fire / CAS when supporting a larger unit...You can't really snipe effectively with them though because they are very erratic.  As the tracer fill burns, the tracer becomes slightly lighter and the center of gravity begins shifting a bit.  This  litterally screws with the bullet (I've seen some of them yaw so badly through a spotting scope that the smoke trail makes a tight corkscrew).

I'm not sure why you arent seeing in-flight tracers with V.91b...If you are seeing the ricochet, then the EH is working.  It might have something to do with the line of code that bypasses the in-flight tracer for non player units, but I'm not sure what exactly.  The version I post tonight should fix this though as it has been overhauled a great deal.

-Grendel

pazuzu

  • Guest
Re:RealTracer V.9b
« Reply #15 on: 13 Jun 2005, 23:13:51 »
Is this script good for MP?

Grendel

  • Guest
Re:RealTracer V.9b
« Reply #16 on: 13 Jun 2005, 23:24:50 »
Quote
Is this script good for MP?

I don't think it would work in mp the way it is set up at the moment...and to be quite honest I have never delved into MP scripting as of yet...

I'm sure it would lag the hell out of a server though if it was required to track all the rounds fired, and create all those particles, but then what do I know about MP scripting...(answer: not a whole heck of a lot).

Maybe some scripting genius can figure out how to convert my script if it is possible...the alternative is waiting untill I finish working on my SP MOD so that I can learn MP. Sorry I'm not much help on this :(

-Grendel

Offline penguinman

  • Contributing Member
  • **
  • Money is worthless, just paper, ink, and threads
Re:RealTracer V.9b
« Reply #17 on: 13 Jun 2005, 23:40:08 »
when are you going to delete all external addons so I can test the tail streak version. ;)  

Grendel

  • Guest
Re:RealTracer V.9b
« Reply #18 on: 13 Jun 2005, 23:57:34 »
Quote
when are you going to delete all external addons so I can test the tail streak version

Tonight by about 1900 hrs Pacific.

Again, sorry about that...I think you will be happy with the results.  Non player fired tracers now have a yellow(west) or white (east) "head" and a 5m long trail (of the appropriate tracer color) that looks pretty close to the pic you posted.  They are pretty disconcerting when they are coming your way too BTW! They will make you want to duck.

I am still trying to find a perfect balance of size and scale (I have to make them bigger as they get farther away to stay visible, yet still appear as though they are shrinking due to distance...very tricky to find the right algorythm).  So right now they look a little larger than I would like.

-Grendel

Offline penguinman

  • Contributing Member
  • **
  • Money is worthless, just paper, ink, and threads
Re:RealTracer V.9b
« Reply #19 on: 14 Jun 2005, 00:59:37 »
cool :)
how about you just make the tails get longer as they get further away
« Last Edit: 14 Jun 2005, 01:00:06 by penguinman »

Offline Pilot

  • Contributing Member
  • **
Re:RealTracer V.9b
« Reply #20 on: 14 Jun 2005, 02:07:41 »
I just tried the script again.  Now the tracers are flying through the air.  Don't ask me why it's working now ???

-Student Pilot

Grendel

  • Guest
Re:RealTracer V.9b
« Reply #21 on: 14 Jun 2005, 02:50:04 »
Quote
Now the tracers are flying through the air.  Don't ask me why it's working now

Two words: Flashpoint Gremlins. I swear they are real!

Quote
how about you just make the tails get longer as they get further away

I'll see if that works.

And (drumroll) with 15 minutes to spare....here is the new version which should be cleaned up and working.

-Grendel



Offline Pilot

  • Contributing Member
  • **
Re:RealTracer V.9b
« Reply #22 on: 14 Jun 2005, 03:43:39 »
Quote
Two words: Flashpoint Gremlins. I swear they are real!
Lol, I think you're right!

I tried the new version.  Wow, it looks really good!

-Student Pilot

Offline penguinman

  • Contributing Member
  • **
  • Money is worthless, just paper, ink, and threads
Re:RealTracer V.9b
« Reply #23 on: 14 Jun 2005, 05:39:42 »
well, i tried the new version, i saw a few little ball tracers(like 7 for the whole firefight) but no trails, i barly saw anything except the default BIS tracers and then a little colored ball flash here or there, but i dint see any moving balls and only a very few instantanious ball flashes. let alone any trails,

so i put setacctime .3, and tried,

wow! theres all the tracers with trails, only i cant play missions in .3 acctime

maby slow the tracers down a bit so there easier to see.

Grendel

  • Guest
Re:RealTracer V.9b
« Reply #24 on: 14 Jun 2005, 18:14:40 »
Quote
i dint see any moving balls and only a very few instantanious ball flashes. let alone any trails

Is anyone else having similar problems during normal game acceleration?

Maybe It is a processing power issue?  I'm running a 1.5 ghz with 1gig RAM and a pretty fast GeForce, but I should represent the lower end of the CPU power spectrum and I can see the trails during normal game accel.  It could also be your view distance...mine is set pretty far (with low resolution terrain and textures-not as pretty but pretty don't count when you cant snipe at 1000m :))


Quote
Wow, it looks really good

Thanks! Wait till you see the next version:

Busy as ever, I have further improved the script to implement the alternate strike effects!  The tracers now have three possible effects (all randomized): They can, of course, richochet (20% chance ), 'burn in' which means it will sit there flickering/smoking untill tracer burn out (10% chance,  or it will disintigrate into smaller sparks of the tracer's 'core color' (yellow sparks for red tracers, white for green...70% chance).

The script has undergone some other refinements.  Most notably, you can now set the script up to pump out tracers for user definable multiples or individual rounds much easier, without having to use the huge tracer array.

The user can also set the script up to add an improved dust kick up for heavy weapons, and I will include a bonus Mini Demo mission where this effect is added to a BAS MH60's M134 minigun with a 1 for 1 tracer load (I highly recomend playing from both the ground and as the MH60 gunner  ;))...The only downside:  It will need BAS Ranger/Delta 1.55, JAM2, BAS MH-60 pack, and the Tonali OPFOR.  I would link to them, but if you don't already have these, I doubt my little script will be enough incentive for you to DL 300MB worth of addons :-\ (although you really should do yourself a favor and pick these up sometime!)

Once again, the new (and hopefully final) version will be uploaded tonight at around the same time...

I don't really get off on tooting my own horn, but honestly with the new effects, this is as close to real tracer fire that I have seen modeled in any game (but then I have spent about 12 years so far watching them spit out of various weapon systems)

*gratuitous horn tooting complete, horn stowed and corked*

-Grendel

Offline penguinman

  • Contributing Member
  • **
  • Money is worthless, just paper, ink, and threads
Re:RealTracer V.9b
« Reply #25 on: 14 Jun 2005, 22:48:17 »
oh, now it works, its just because my ofp had been runing all day and was laggy

now im not going to tell you how to do this and its completely up to you,but if I were you and its not to much work id have

1 seperate script for rifle tracers,
users should be able to decide in the syntax for each individual unit: the color of the tracers, weather they want the bounce/ break up/ stick n' burn effects(using 0 for no and 1 for yes), weather they want tracers with tails(once again 0 no, 1 yes) and the number of rounds between each tracer, and also the size of each tracer.

a seperate script that alows any vehicle mounted weapons to have tracers
same changeable stuff as for rifle tracers.    

a seperate script for dust kickup(because maby the user wants dust but not tracers)

maby say,, how big the dust puff is, the color(so they can change it for snow, desert, red clay), maby how long it lasts too., I dont know if that wouldnt be too hard to do.


ya but basicly stuff like that,
stuff that would provide the user with more options so he dosent have to email you and ask you to make a script with white tracers or tracers that fire every round insted of your defaullt 3. IMHO that would make the script
easier to use and more dynamic and stuff,

might be alot of work I dont know but if it isint to much i think you should definatly go for it.

thanks and great script.

« Last Edit: 14 Jun 2005, 22:53:35 by penguinman »

Grendel

  • Guest
Re:RealTracer V.9b
« Reply #26 on: 15 Jun 2005, 03:35:11 »
Those are all good ideas Penguinman, and I should be able to implement them all in the final.

Until then here is the updated script with the new stuff:
It would have been sooner but since it was the Army's B-day today I had to work a bit longer...go figure.

-Grendel

Grendel

  • Guest
Re:RealTracer V.9b
« Reply #27 on: 15 Jun 2005, 03:36:23 »
And the BAS special metioned above here:

-Grendel

Offline Pilot

  • Contributing Member
  • **
Re:RealTracer V.9b
« Reply #28 on: 15 Jun 2005, 04:19:12 »
I just tried V.94B, and I have to say, these tracers get better with each version.  It looks very nice!

One bug though,
G36A should be G36a.  Don't ask me why the lowecase matters, but it does.

One observation:
I noticed you had an Ak74GrenadeLauncher, but not an M16GrenadeLauncher or an Ak47GrenadeLauncher.  Any reason for this?

Anyway, keep up the good work!

-Student Pilot
« Last Edit: 15 Jun 2005, 04:19:38 by Student Pilot »

Grendel

  • Guest
Re:RealTracer V.9b
« Reply #29 on: 15 Jun 2005, 17:10:55 »
Quote
G36A should be G36a

Arghh darned case sensitive stuff!

Quote
I noticed you had an Ak74GrenadeLauncher, but not an M16GrenadeLauncher or an Ak47GrenadeLauncher.  Any reason for this

Not really, I just didn't add them to the easttw array in the init yet because I am still implementing a check in the script to keep tracers from being attatched to the grenades...

Thanks for the compliments too!  Once I get the GL issue fixed and add some of the functionality Penguinman suggested this baby should be Alpha.

-Grendel



Offline penguinman

  • Contributing Member
  • **
  • Money is worthless, just paper, ink, and threads
Re:RealTracer V.9b
« Reply #30 on: 17 Jun 2005, 21:17:17 »
aww >:(

when i put v. 94 in my user missions folder and started ofp, i get an error in the user info that says "error, < incountered insted of =" and ofp wont work, i took the mission out rebooted, still the same problem.

lucky me now i get to reinstal ofp and lose everything,

its my comps fault it just happend to be on your mission,

any sugjestions or somthing i can do so i dont have to restart? and lose everything


Offline Pilot

  • Contributing Member
  • **
Re:RealTracer V.9b
« Reply #31 on: 17 Jun 2005, 21:49:53 »
@penguinman

Have you installed any addons recently?  If so, remove them.  If not, I can only suggest two things:
1: Make a copy of everything you don't wan't to lose
2: Start a post on the Official Forums, that is the place for technical help.

I hope you can get your problem fixed!

-Student Pilot

Offline penguinman

  • Contributing Member
  • **
  • Money is worthless, just paper, ink, and threads
Re:RealTracer V.9b
« Reply #32 on: 17 Jun 2005, 22:40:28 »
nope, no recent addons, only the newest version of realtracer.

ok, i dont have an account on the oficial forums and it dosent look like the problem can be fixed, so il just save everything i dont want to lose and reinstal. good idea,

thanks SP/ :)

EDITok, i think its working now, ive had to reinstal, but what I want to know is will it happen again if i try to dl it?
« Last Edit: 18 Jun 2005, 01:12:58 by penguinman »

Offline penguinman

  • Contributing Member
  • **
  • Money is worthless, just paper, ink, and threads
Re:RealTracer V.9b
« Reply #33 on: 19 Jun 2005, 07:02:27 »
is the final almost done?

i like it alot so im waiting for this to be done so i can put it in my mission and be able to release it

Offline General Barron

  • Former Staff
  • ****
  • Semper Fi!
Re:RealTracer V.9b
« Reply #34 on: 02 Jul 2005, 23:45:37 »
Wow, these look great! Way better than the other tracer script that was linked to, and it doesn't require addons either!

I only get about 12-18 FPS, and sometimes I can't see the tracers very well/at all. I have this problem with other quick drop effects as well sometimes, but yours doesn't seem to be too bad. I wouldn't worry about trying to slow it down any for lower end computers.

You know, I was playing with these and I thought to myself: "damn, now I wish there was a way I could disable OFP's default tracers." Then I remembered you could do it in the options panel  :P. Now it looks even better! Too bad I can't disable MG tracers as well, because these are just better than the BIS stuff.

One thing I noticed, which I'm sure you are aware of, is that EVERYTHING gets a tracer, not just the primary weapon. Grenades, pistols, etc... they all have tracers. An easy fix might be to check if the fired weapon is the unit's "primaryWeapon" (see com ref for that command). I don't think this would solve m203's firing trace though. Another solution might be to just check the speed of the fired round, and if it is below a certain speed, then exit.

----------

Looking in the scripts, I see that you adjust the tracer depending on where the player is. Very nice :), just make sure to check distance to VEHICLE PLAYER, in case the player is in a car/helo/etc. One suggestion would be to put a Level Of Detail variable in there that says the maximum distance from the player that tracers will be shown. That's used in the ECP to cut down on needless effects that the player can't see.

I must admit, I'm confused about why you use the function and invisible H for the ricochets at the end. Are you aware that you can use the "drop" command without passing an object to it? Since you already know the last position of the bullet, I don't see why you need the H/function. ???

Now some performance issues. With a script like this, every little bit of lag counts bigtime, since it is run every time every unit shoots every round:

I notice that there are only 2 tracer colors supported. If that is the case, then you really only need 1 weapon array. Meaning, you only need to know if the fired weapon is in the "green" tracers array, otherwise you can just default to red tracers (or vice-versa). That way OFP only has to search thru one array, which hopefully would be the smaller of the two.

The "custom tracer mix" array also seems a little unneeded. You could just divide the unit's remaining rounds by 3, and if the result is an even number, then you use a tracer. The "mod" command would come in handy here. I'd have to think about the exact formula that would be required, but it would only involve a check like this:

? (_a % 3) == 0 : goto "loop"

That would be quicker for OFP to check than searching thru a huge array. I realize that this wouldn't support, say, having the last 5 rounds be all trace, but perhaps a combination of array and the above would work:

? (_a in [1,2,3,4,5]) || (_a % 3) == 0 : goto "loop"


In MP, I think this script should work just fine. I believe that EHs fire on all clients, which would mean that the drop effects would be created locally on each player's machine (which you need because drop effects can only be seen on the machine where they are created). The tracer size would adjust itself to each player properly. Ricochets would be different on each machine, since the random number is "rolled" up on each separate client, but since it is only visual, it isn't a problem.

The only thing I would add for MP is a check to see if this is a dedicated server. Since no one is playing on a ded server, there is no one to see the effects, so the server doesn't need to bother creating them. You also might get errors, since you use the distance to the player, which doesn't exist on the ded. server.

On ded. servers, the "player" variable is null. So a check at the very beginning of the script would work:

? player == player : goto "start"
exit
#start

HANDSIGNALS COMMAND SYSTEM-- A realistic squad-control modification for OFP
kexp.org-- The best radio station in the world, right here at home! Listen to John Richards!

Grendel

  • Guest
Re:RealTracer V.9b
« Reply #35 on: 06 Jul 2005, 17:41:32 »
Hey General Baron!

Thanks for the input! Thats good stuff, all of it!

The Invis "H" was needed as the bullet's 'last position' was usually 20m or so in front of the actual impact point (and thus in the air) so there would be this disconcerting 'jumping' of the tracers that just looked crappy.  I'm still working on it though...

The newest version I posted should solve some of the issues with tracing only defined weapons (although I haven't finished the M203 muzzle mode check yet), I think you were using an older version maybe?

I greatly appreciate your performance suggestions and of course the complimentary remarks  :)

-Grendel

BlinkDog

  • Guest
Re:RealTracer V.9b
« Reply #36 on: 07 Jul 2005, 00:34:38 »
Great little script. I decided to try it out today and came across a bug maybe. I kept getting a message "not a tracer weapon" I found it annoying because it spammed my sidechat. Was this intensional? If so can it be disengaged? I'm really new to scripting (like today) and would like to use this one in all my missions.

DBR_ONIX

  • Guest
Re:RealTracer V.9b
« Reply #37 on: 07 Jul 2005, 16:22:42 »
There will be a line similar to
someone sidechat/globalchat/groupchat (Not sure whichone) "Not a tracer weapon"

Either put a ; before it (Comments it, this way is better incase you want to eneable it to check if tracers should be enabled on a weapon), or delete the line (Works, but just as eay commenting it :P)
- Ben

BlinkDog

  • Guest
Re:RealTracer V.9b
« Reply #38 on: 07 Jul 2005, 20:52:37 »
Yes I did see a line like that but wasn't sure if it would screw up the rest of the script or not. I'll give that a try.

And yes tracers do fly over long distances after ricocheting. This script brings back memories of my gunners course.

Offline KeyCat

  • Members
  • *
Re:RealTracer V.9b
« Reply #39 on: 08 Jul 2005, 15:27:30 »
Damn, I nearly missed these cool tracers and that just shows I don't check in to this great forum often enough! Great work Grendel!

We are currently using Wolfbane's tracer script that uses a very similar approach like yours but yours up's the ante a few notches. Since our major concern is MP we will try it out ASAP but as GB said it probably works fine.

Only looked at it briefly and you don't use many global variables but on the few you have I suggest you to add an unique OFPEC tag just to avoid potential conflicts with other scripts/addons.

More info here http://www.ofpec.com/tags_about.php

Also maybe you could take a look at Wolbane's script to get ideas on how to solve the GL issue and maybe other things?? Let me know if you want it and I will e-mail it to you.

Will let you know how the MP tests go!

/Christer (a.k.a KeyCat)


« Last Edit: 08 Jul 2005, 16:07:04 by KeyCat »
- The journey is the reward!

Offline penguinman

  • Contributing Member
  • **
  • Money is worthless, just paper, ink, and threads
Re:RealTracer V.9b
« Reply #40 on: 29 Jul 2005, 17:06:02 »
so hows the next version comming?
 im just asking because i want to put the script in a mission im making.

Offline 456820

  • Contributing Member
  • **
Re:RealTracer V.9b
« Reply #41 on: 04 Sep 2005, 19:07:35 »
i cant get this to work in my mission i copy the trigger from the example missions and all the lines wich are needed from the nit to my init.sqs file
the script works great in the example mission but doesnt work in my mission ?

by the way nice tracers

Offline The-Architect

  • Former Staff
  • ****
  • Bite my shiny metal...
    • Bob's Un-official Flashpoint Page
Re:RealTracer V.9b
« Reply #42 on: 06 Sep 2005, 22:19:35 »
How do I make custom weapons have the tracers? Is it a simple case of adding the weapon type to the scripts and if so, where?
James Andrew Wilkinson 1977 - 2005 R.I.P.
"If it ain't the friggin' incoming it's the friggin' outgoing. Only difference is who gets the friggin' grease, and that ain't no friggin' difference at all."

Offline 456820

  • Contributing Member
  • **
Re:RealTracer V.9b
« Reply #43 on: 06 Sep 2005, 23:02:00 »
i thought you could add the name of thw weapons to the lines in the init.sqs or is that the weapons that wont wofire tracers

Offline The-Architect

  • Former Staff
  • ****
  • Bite my shiny metal...
    • Bob's Un-official Flashpoint Page
Re:RealTracer V.9b
« Reply #44 on: 07 Sep 2005, 19:14:36 »
lol, yeah, I took a look and it worked. It's now a part of my new mission.
James Andrew Wilkinson 1977 - 2005 R.I.P.
"If it ain't the friggin' incoming it's the friggin' outgoing. Only difference is who gets the friggin' grease, and that ain't no friggin' difference at all."

Offline 456820

  • Contributing Member
  • **
Re:RealTracer V.9b
« Reply #45 on: 07 Sep 2005, 19:30:11 »
can i just check that i didnt do anything wrong i copied the trigger from the demo mission into my mission then i copied this

Quote
DirToObj = PreProcessFile "DirToObj.sqf"
roundn= preProcessFile "roundn.sqf"

tracershot=0
tracers=[1,2,5,8,11,14,17,20,23,26,29,32,35,38,41,44,47,50,53,58,61,64,67,70,73,76,79,82,85,88,91,94,97,100,101,102,103,105,108,111,114,117,120,123,126,129,132,135,138,141,144,147,150,153,158,161,164,167,170,173,176,179,182,185,188,191,194,197,198,199]
westtw=["FAL","G36A","HKG3","M16","M4","M60","Steyr","XMS"]
easttw=["PK","AK47","AK47CZ","AK74","AK74GrenadeLauncher","AK74SU"]

into my init.sqs
and copied the scripts and functions into my folder
i tried it in game and i got no tracers ? i did infact get about 4 when i was lying on the ground aproaching a base the enmy spotted us and shot at us i saw about 3 tracers then no more for the rest of the mission ?
does anyone know why this may be ?