Help accessing BluePrint parameters via script - Printable Version +- Obi Official Forum (https://obi.virtualmethodstudio.com/forum) +-- Forum: Obi Users Category (https://obi.virtualmethodstudio.com/forum/forum-1.html) +--- Forum: Obi Fluid (https://obi.virtualmethodstudio.com/forum/forum-3.html) +--- Thread: Help accessing BluePrint parameters via script (/thread-4049.html) |
accessing BluePrint parameters via script - CosmosST - 10-11-2023 Hello, On ObiFluid, I would like to access and change the Blueprint parameters via script, and also even change the Blueprint assigned to an emitter as well. Can you please give a simple example ? thnk you. RE: accessing BluePrint parameters via script - josemendez - 10-11-2023 (10-11-2023, 12:47 PM)CosmosST Wrote: Hello, Hi, To change blueprint parameters you just do: Code: blueprint.surfaceTension = newSurfaceTension; Same with all other parameters. Note that changing blueprint parameters will only affect particles emitted after the change. Existing particles will not have their parameters affected. To change the emitter's blueprint you just do: Code: emitter.blueprint = yourBlueprint; Note this will reset the emitter because blueprints might have a different capacity: all existing particles will be destroyed, a new particle pool will be created (its size determined by the new blueprint capacity), and emission will start over again. To change the properties of existing particles at runtime, you do that directly on a per particle basis using the Particles API. kind regards, RE: accessing BluePrint parameters via script - CosmosST - 11-11-2023 Thank you ! |