I have a script I can’t seem to fix.
it just wont execute.
import bpy
from bpy.types import Panel
class activemasspanel(bpy.types.Panel):
bl_category = "Physics"
bl_space_type = "VIEW_3D"
bl_region_type = "TOOLS"
#bl_context = "editmode"
bl_label = "Active Mass"
class PHYSICS_PT_rigid_body(PHYSICS_PT_rigidbody_panel, Panel):
bl_label = "Active Mass"
@classmethod
def poll(cls, context):
obj = context.object
return (obj and obj.rigid_body and
(not context.scene.render.use_game_engine))
def draw(self, context):
layout = self.layout
ob = context.object
rbo = ob.rigid_body
if rbo is not None:
row = layout.row()
if rbo.type == 'ACTIVE':
layout.prop(rbo, "mass)
def register():
bpy.utils.register_module(__name__)
def unregister():
bpy.utils.unregister_module(__name__)
if __name__ == "__main__":
register()