Net Generator Script

Scripting in Blender with Python, and working on the API

Moderators: jesterKing, stiv

celeriac
Posts: 72
Joined: Fri Feb 21, 2003 11:31 pm
Contact:

Net Generator Script

Postby celeriac » Tue May 27, 2003 11:16 pm

I've written a script for unfolding meshes to nets. Anyway, I want to eat some artichokes now so if you're interested in things unfolding then have a look.

http://www.thesethings.clara.net/polyhedra/

I would be really grateful if someone who knows python (I don't) and Blender would advise me as to how to make my program work for animating sequences in Blender. So far I have created my unfolding animations frame-by-frame or by adding YaBle method invokations to my program. Specifically I am keen to know how to tell Blender to invoke a method of my program at each frame change, but have my program conserve object state in doing so (because my objects know about the folds in the meshes).

theeth
Posts: 1184
Joined: Wed Oct 16, 2002 5:47 am
Location: Montreal
Contact:

Postby theeth » Wed May 28, 2003 5:24 pm

To call a script each frame, you have to create a ScriptLink.

Go the the Script Buttons (the icon next to the Display Buttons)
Press New
By default, the type of Event is FrameChange. That means the script is called each time the current frame changes.
In the empty box next to FrameChange, type the full name of the script (as it is displayed in the Text Window footer).

nice script btw

Martin
Life is what happens to you when you're busy making other plans.
- John Lennon


Return to “Python”

Who is online

Users browsing this forum: Yahoo [Bot] and 0 guests