Inside Sabertooth
Learn how Sabertooth uses 3ds Max to create 3D interactive projects, including HBO Go’s Game of Thrones interactive experience
  • 1/3
You are here: Forum Home / Autodesk 3ds® Max® / Particles - Dynamics / Particle Fracture not rendering
  RSS 2.0 ATOM  

Particle Fracture not rendering
Rate this thread
 
42644
 
Permlink of this thread  
avatar
  • Tim
  • Posted: 29 April 2010 06:06 AM
  • Location: Philadelphia
  • Total Posts: 178
  • Joined: 22 August 2006 02:18 PM

I can get it to show up in viewport about 30% of time and then it never renders.  Any idea what is going on?  I am using Birth script.

I have attached a zip file. 

thanks
Tim



Tim

Replies: 0
avatar
  • Tim
  • Posted: 29 April 2010 06:12 AM

For some reason, it won’t let me attach a 144kb zip file.  so… here is the birth script:

[ code ]on ChannelsUsed pCont do
(
pCont.useAge = true
pCont.useTM = true
pCont.useShape = true
)

on Init pCont do
(
global ChunksArray = $Box* as array
)

on Proceed pCont do
(
t = pCont.getTimeStart() as float

if t < 0 do
(
NumChunks = ChunksArray.count

for i = 1 to NumChunks do
(
pCont.AddParticle()
pCont.particleIndex = pCont.NumParticles()
pCont.particleAge = 0
pCont.particleTM = ChunksArray.transform
pCont.particleShape = ChunksArray
.mesh
)
)
)

on Release pCont do
(

)[ /code ]

I have a Birth Script, Speed and Display.



Tim

Replies: 1
/img/forum/dark/default_avatar.png

2 Things.

See this post for help with attachments.

Better to place code within [ code ]...[ /code ] tags (rather than colouring it) - the forum really screws with code if you’re not very careful.

Author: Steve_Curley

Replied: 29 April 2010 06:42 AM  
avatar
  • Tim
  • Posted: 29 April 2010 07:53 AM

I may have figured it out.

I had fragmented objects called Fragsphere[0-12]

then another object called fragsphere_13

would that make the problem happen?



Tim

Replies: 0
avatar
  • Krueger
  • Posted: 29 April 2010 02:41 PM

Well if your pieces are called Fragsphere(0-whatever), your code should be this:

on ChannelsUsed pCont do
(
    pCont
.useAge true
    pCont
.useTM true
    pCont
.useShape true
)

on Init pCont 
do 
(
    
global ChunksArray $Fragsphere* as array
)

on Proceed pCont 
do 
(
    t 
pCont.getTimeStart() as float

    
if do 
    
(
        NumChunks 
ChunksArray.count

        
for 1 to NumChunks do
        
(
            pCont
.AddParticle()
            pCont
.particleIndex pCont.NumParticles() 
            pCont
.particleAge 0
            pCont
.particleTM ChunksArray[i].transform
            pCont
.particleShape ChunksArray[i].mesh
        )
    )
)

on Release pCont 
do 
(

)

I just copied Bobo’s script from scriptspot and changed the Box value to your Fragsphere object name. But the things I noticed that could give you the error (besides the name possibly being wrong) was:

--The below shouldn't be there

if t < 0 do > (
NumChunks = ChunksArray.count

And

--The [i] value needs to be in the two lines below

pCont
.particleTM ChunksArray[i].transform
pCont
.particleShape ChunksArray[i].mesh


3ds Max 2009 SP1, 2010 SP1
Maya 2012
Windows 7 Professional 64-bit
Dual Intel Xeon E5520, 6 GB Ram
NVIDIA GeForce GTX 460 OC

Replies: 0
avatar
  • Tim
  • Posted: 29 April 2010 11:37 PM

I actually posted the wrong script… ha!  I had changed the name to Fragsphere

but I may have that “i” missing and the extra symbol.  will check.  Thanks.



Tim

Replies: 0