SetLife at n-collision for tp

THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

On 21/05/2012 at 09:53, xxxxxxxx wrote:

Hello to all
I have problem with understanding of how to catch/detect and kill at n-collision tp(id).
scene(from my colleague) - link
and code(at tag) :

    
    
    import c4d
    from c4d.modules import thinkingparticles as tp
    
    def main() :
        curframe = doc.GetTime().GetFrame(doc.GetFps())
    
        N = tp.NumParticles()
        ids = range(N)    
        if curframe == 0 :
            ids = range(N)
            life = [c4d.BaseTime(0.0)]*N
            map(tp.SetLife,ids,life)
        else :
            ids = range(N)
            for i in ids :
                if tp.Alive(i) :
                    col = tp.SetCollision(i, 10) 
                    print col
                    if col :
                        ids = range(N)
                        life = [c4d.BaseTime(0.0)]*N
                        map(tp.SetLife,ids,life)

THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

On 22/05/2012 at 07:38, xxxxxxxx wrote:

it does not documented in help, but seems works:

tp.CheckCollision(0, i, curframe, tp.Position(i), tp.Velocity(i), tp.Spin(i)["axis"], tp.Spin(i)["speed"], dt, ct)

how to catch dt and ct?

up.
dt = curframe - 1

ct?

THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

On 22/05/2012 at 23:48, xxxxxxxx wrote:

i guess dt stands for deltatime und ct for currenttime.

THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

On 23/05/2012 at 12:04, xxxxxxxx wrote:

Thanks Ferdinand.
So, that boolean function works for sequences with GetVirtualObjects(...) and gv-interface.

THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

On 24/05/2012 at 11:10, xxxxxxxx wrote:

I downloaded new documentation of pyDocs, expecting explanation that function will be 😉
Sebastian, please, will be it?

THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

On 25/05/2012 at 01:21, xxxxxxxx wrote:

It's intended that TP_MasterSystem.CheckCollision() isn't documented. This function is private.

THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

On 25/05/2012 at 07:40, xxxxxxxx wrote:

Muchas gracies. Thank you.
Hope it will be more public. 😉

Also thanks for docs to Maxon's devs