Professional Web Applications Themes

how to reset #burst particle resource? - Macromedia Director 3D

I've made a model resource for a bunch of particles exploding outward from a point. But every time I create a new model, with that explosion as its resource, it's always at the exact same 'frame' of its animation, regardless of when I create it. That is, when I first create a model based on that resource, the explosion begins, but if I create a new one halfway through the explosion, the new one will begin already halfway exploded. Is there some way to clone the emitter resource, or force each model based on it to operate on its own ...

  1. #1

    Default how to reset #burst particle resource?

    I've made a model resource for a bunch of particles exploding outward from a
    point. But every time I create a new model, with that explosion as its
    resource, it's always at the exact same 'frame' of its animation, regardless of
    when I create it. That is, when I first create a model based on that resource,
    the explosion begins, but if I create a new one halfway through the explosion,
    the new one will begin already halfway exploded. Is there some way to clone the
    emitter resource, or force each model based on it to operate on its own time?

    At worst, I only actually need one of these explosions on screen at once...
    except that, even after the original model has been deleted, any new one I
    later create is still operating on that same initial timeline, which means it
    stands a good chance of appearing half-exploded already (or not appearing at
    all, if I set its .loop = false). Is there some way for me to reset the
    emitter's timeline at all?

    RavenWorks Guest

  2. #2

    Default Re: how to reset #burst particle resource?

    i would create for every explosion a new particleresource and pariclemodel and
    delete it after using. but i found a some information that could be interesting
    for you.

    [url]http://www.secretrobot.com/Articles/Shockwave3DPitfalls.html[/url]

    maybe you can just reset one of the discribed propertys to reset your system.

    hondo3000 Guest

  3. #3

    Default Re: how to reset #burst particle resource?

    I clicked 'answer' before I actually tried it... apparently these things only
    work if they're changed in the 3DPI. I guess the 3DPI deletes the old one and
    makes a new one in its place... Thanks anyway though!

    RavenWorks Guest

  4. #4

    Default Re: how to reset #burst particle resource?

    it workes if you change the values, if you dont change them nothing will
    happen. look at this code for a paricle burst.

    property pMember, spritenum, res

    on beginsprite me
    pMember=sprite(spritenum).member
    pMember.resetworld()

    res=pmember.newmodelresource("particle_res", #particle)
    res.lifetime = 1000

    res.emitter.direction=vector(0,1,0)
    res.emitter.numParticles = 2500
    res.tweenmode=#age

    res.emitter.distribution =#linear
    res.emitter.angle=180
    res.emitter.loop=0

    res.drag =10
    res.gravity = vector(0, 0, 0)

    res.sizeRange.start = 10
    res.sizeRange.end = 0

    res.emitter.maxSpeed = 500
    res.emitter.minSpeed = 500

    res.blendRange.start=100
    res.blendRange.end=0

    res.colorRange.start = rgb(255,0,50)--rgb(51,102,204)
    res.colorRange.end = rgb(255,255,255)
    res.emitter.mode = #burst

    em=pMember.newmodel("particle", res)
    em.transform.position=vector(0,0,-500)
    end


    on mouseUp me
    res.lifetime = 1
    res.lifetime=1000
    end

    you can paste it on a empty shockwave3d member on the stage and click into it
    to see how it works.

    hondo3000 Guest

Similar Threads

  1. Burst effect
    By Rhonda Gray in forum Adobe Photoshop 7, CS, CS2 & CS3
    Replies: 5
    Last Post: August 7th, 03:23 PM
  2. 10D: does CF write speed influence burst-shooting rate?
    By Alan F Cross in forum Photography
    Replies: 3
    Last Post: July 14th, 01:22 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139