Hello Mexicouger,
You should not (need not) write a QC time loop, if you want to add partiles to a (moving) entity.
Knowing from other threads, you are using the Darkplaces engine:
Darkplaces helps you with it and takes over the work.
This is what need:
//DP_ENT_TRAILEFFECTNUM
//idea: LordHavoc
//darkplaces implementation: LordHavoc
//field definitions:
.float traileffectnum;
//description:
//use a custom effectinfo.txt effect on this entity, assign it like this:
//self.traileffectnum = particleeffectnum("mycustomeffect");
//this will do both the dlight and particle trail as described in the effect, basically equivalent to trailparticles() in CSQC but performed on a server entity.
It was implemented into DP in june 2011, so even the "stable" build from 2011 has it.
Put it into your spawning bullet function like this:
...
bullet = spawn();
bullet.traileffectnum = particleeffectnum("bullet_trace");
....
Next thing is your particle effect declaration.
You must not use the "
count" or "
countabsolute" keyword for moving entities.
(by the way, you must not use both in the same block)
That is only for entities with movement = 0
You must use the keyword "
trailspacing" for your bullet.
(bigger value means bigger gap/pause between particles, so try with "trailspacing 1" first and then go slowly upwards until you are staisfied)
This is very good explained in the dpwiki as well.
As you know it is offline, so please use the backup instead:
http://www.quakewiki.net/darkplaces-wik ... reference/
Also think about your usage of "time" and the very high "alpha" fade-rate in the same block.
There are many examples of effectinfo.txt usage for moving and static effects in the downloadable "small mod compilation". If you want you can look inside and read/see some samples there.
Best wishes,
Seven