WorldViz User Forum

WorldViz User Forum (
-   Vizard (
-   -   Interpolated scaling or force? (

willpower2727 10-14-2016 12:15 PM

Interpolated scaling or force?
I'm trying to visually enhance an explosion (mesh bomb from 3ds converted to osgb) with the fire.osg. I want to make the fire osg expand rapidly but not instantaneously. I can re-scale it but the change is too abrupt. I have tried applying a force but it only moves the whole object in one specified direction. I'd like it to sort of blow up in all directions. Any ideas? Here's what I've tried so far:

import viz
import vizact

fire = viz.addChild('fire.OSG',scale=[2,2,2])

firep = fire.collideSphere()

def rescale():

def explode():
print('apply force')
fire.applyForce( dir=[100,0,0],duration=5)
# fire.setScale([4,4,4])


vizact.onkeydown(' ',rescale)

Jeff 10-17-2016 05:22 PM

Open the file in Vizard so you can edit the text and search for 'initialSpeedRange'. The two values shown set the min and max range of the particles initial speed. Try increasing those values and see if it helps.

willpower2727 10-18-2016 10:07 AM

Brilliant! Thanks Jeff, I was able to play around with some of the other parameters as well and it looks awesome.

All times are GMT -7. The time now is 05:14 AM.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2021, vBulletin Solutions, Inc.
Copyright 2002-2018 WorldViz LLC