No line for constraint without target

Code notes:

The constraint_has_target can be used to test if a constraint has a target at all.
This commit is contained in:
2003-11-23 20:28:35 +00:00
parent f58d256a9c
commit d3563d23b7
4 changed files with 62 additions and 2 deletions

View File

@@ -3716,7 +3716,7 @@ void draw_object(Base *base)
glColor3ubv(col2);
for (curcon = list->first; curcon; curcon=curcon->next){
if ((curcon->flag & CONSTRAINT_EXPAND)&&(curcon->type!=CONSTRAINT_TYPE_NULL)){
if ((curcon->flag & CONSTRAINT_EXPAND)&&(curcon->type!=CONSTRAINT_TYPE_NULL)&&(constraint_has_target(curcon))){
get_constraint_target(curcon, TARGET_OBJECT, NULL, tmat, size, bsystem_time(ob, 0, (float)(G.scene->r.cfra), ob->sf));
setlinestyle(3);
glBegin(GL_LINES);