Notifications
Clear all

[Closed] Pflow update problem

here is updated version of my ‘archived’:

struct ParticleData(index, time, pos)
fn getParticlesData pf range: ids:#all = 
(
	if range == unsupplied do range = animationrange
	for t = range.start to range.end collect
	(
		pf.updateParticles pf t
		count = pf.numParticles()
		if ids == #all do ids = #{1..count}
		for k in ids where k <= count collect
		(
			ParticleData index:k time:t pos:(pf.getParticlePosition k)
		)
	)
)
-- the using
getParticlesData $'PF Source 001' range:(interval 0 10) ids:#{1}

Thanks Dennis, the update worked great.

Now I just need to get velocity working in .CSV so a .PRT loader recognizes it.

Cg.

Turns out that the velocity data that you can get from a Pflow with getParticleSpeed is in ticks. And PRTloaders are in seconds. So I had to multiply by ticksperframe * framerate to get it to work. (effectively a multiply by 4800). I saw other people having similar issues on forums so I thought I’d post this here for future reference.

Woohoo.

Cg.

Page 2 / 2