I found this tutorial and watched the attempt to create my own toolbar in Toolshelf, but mine will not work, because there is no obvious reason.
I am using Blender 2.63, and I also tried the exact same script in Blender 2.58 and 2.56, both have the same result. NOTHING.
I went through the script more times than I can count, and I did not see any typos or incorrect words, but it still does not do anything. To make matters worse, I am not getting any error messages.
When I click on the Run Script button in a text editor, the only message I get is that I ran the script. On the shelf of the tool, it displays it at the bottom just as if you were adding a cube, only with the cube you were given some parameters, such as location / scale, etc. Cuba. It also appears in the info window as:
bpy.ops.text.run_script()
This is what my code looks like:
import bpy class customToolshelfPanel(bpy.types.Panel): bl_space_type = "VIEW_3D" bl_region_type = "TOOLS" bl_context = "objectmode" bl_label = "Custom Toolshelf Panel" def draw(self, context): layout = self.layout col = layout.column(align=True) col.label(text="Add:") col.operator("mesh.primitive_plane_add", icon="MESH_PLANE") col.operator("mesh.primitive_cube_add", icon="MESH_CUBE")
Any help at all would be appreciated since Blender does not give me any ideas at all if something is wrong.
source share