System Information
Operating system: Windows 10 64
Graphics card: gtx 940 m
Blender Version
2.80, dafaa6f22881, blender2.8, 2018-12-22
Short description of error
Objcet has no mesh data to be used for ray casting
example:
https://github.com/Darcvizer/Destructive-Extrude/blob/master/Destructive-Extrude.py
line 208
When I try to make a ray_cast in object mode, I get an error “Object has no mesh data to be used for ray casting” I tried to fix it by following the steps:
bpy.context.scene.update()
context.active_object.data.update()
context.active_object.data.update(calc_edges=False)
context.active_object.update_tag(refresh={‘OBJECT’, ‘DATA’, ‘TIME’})
And even:
bpy.ops.object.mode_set(mode=‘EDIT’)
bpy.ops.object.mode_set(mode=‘OBJECT’)