script doesn't seem to work--why?

hey…noob here, so don’t mind the NOOBpid questions …

ok, so i loaded my script into the text editor window, pressed alt-P…and nothing happens. can anyone tell me why?? or is it doing something but i don’t know that it is??


maybe you should post the source :wink:

or just which script it was if it can be found posted here

Because Blender has multiple windows on-screen at the same time the ‘active window’ is the designated by where the mouse pointer is over. Make sure the mouse is over the text editor window when you press alt-p. Or you can always go through the File menu.

here’s what i had (an example from )

import Blender
 from Blender import Material
 mat = Material.New('newMat')          # create a new Material called 'newMat'
 print mat.rgbCol                      # print its rgb color triplet
 mat.rgbCol = [0.8, 0.2, 0.2]          # change its color
 mat.setAlpha(0.2)                     # mat.alpha = 0.2 -- almost transparent
 mat.emit = 0.7                        # equivalent to mat.setEmit(0.8)
 mat.mode |= Material.Modes.ZTRANSP    # turn on Z-Buffer transparency
 mat.setName('RedBansheeSkin')         # change its name
 mat.setAdd(0.8)                       # make it glow
 mat.setMode('Halo')                   # turn 'Halo' "on" and all others "off"

what would you expect to be visually different after doing this?

it simply creates a material, it doesn’t assign it to the active mesh or anything [it will probably show up in the selection list for a material however]

oooooh!!! haha…silly me :expressionless: thanks!!