yes, that's because when you use no scheduler, you have to do some extra tasks ! The delegates are automatically collected by the garbage collector, that's why the scheduler stores them ! If use no scheduler, you have to store the used delegates yourself ! the following code snippet should work (i guess) :
Code:
// create a delegate for the particle method and store it, if you use instance
// methods etc... you have to store them in another way, but using only static
// methods, this should work too !
private static readonly WrapperDelegateParticle StoredDelegateForParticles = ParticleLineEvent;
private static void ParticleLineEvent(IntPtr AP)
{
PARTICLE P = PARTICLE.createFromPointer(AP);
P.lifespan = 0;
}
private static void ParticleLine(IntPtr AP)
{
PARTICLE P = PARTICLE.createFromPointer(AP);
P.lifespan = 1;
P.event_ = ParticleLineEvent;
}
public static void DrawLine3DEx(Vector AFrom, Vector ATo, Color AColor, int AAlpha, int ASize)
{
// call the effect method, already with the stored delegate
PARTICLE.effect(StoredDelegateForParticles, 1, AFrom, (Vector) ATo.vec_sub(AFrom));
}