0
$\begingroup$

So I have made a few custom properties but I get this error:enter image description here

However, my code for unregister is:

classes = [texttool_PR_add, Text_OT_tool, TextTool, WM_OT_textOp]


#Thing that does the process
def register(bl_info):
    
#class register
    for cls in classes:
        bpy.utils.register_class(cls)
        
    bpy.types.Scene.my_tool = PointerProperty(type= texttool_PR_add)
        
    
        
       
        
    wm = bpy.context.window_manager 
    kc = wm.keyconfigs.addon
    
    if kc:
        km = kc.keymaps.new(name='3D View', space_type= 'VIEW_3D')
        kmi = km.keymap_items.new("wm.textop", type= 'F' and 'T', value= 'PRESS', shift= True)
       
        addon_keymaps.append((km, kmi))
    
        
        
    
        
def unregister():
#class unregister
    for cls in classes:
        bpy.utils.unregister_class(cls) 
      
    del bpy.types.Scene.my_tool  
    
        
        
    for km,kmi in addon_keymaps:
        km.keymap_items.remove(kmi)
    addon_keymaps.clear()
    

     
if __name__  == "__main__":
    register() 

Does anyone know why this is happening? My full code is: https://pastebin.com/RncMTKJQ

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.