2

I'm new to Sketchup scripting. When I extrude face2 below, a circle appears at the base of the face. It only appears after the pushpull and it doesn't appear if I extrude face1. Face1 and face2 are supposed to be the first two walls of a box. Could someone explain this?

ents = Sketchup.active_model.entities
face1 = ents.add_face [1.m, 0, 0], [1.1.m, -0.1.m, 0], [-1.1.m, -0.1.m, 0], [-1.m, 0, 0]
face2 = ents.add_face [-1.m, 0, 0], [-1.1.m, -0.1.m, 0], [-1.1.m, 1.1.m, 0], [-1.m, 1.m, 0]
face1.pushpull(1.m, true)
Jan Huus
  • 63
  • 8

2 Answers2

0

Your code works for me (I also extruded face2). Could you edit your question and upload a picture of the problem you are describing?

enter image description here

Chris Hamilton
  • 555
  • 5
  • 22
  • Thanks for taking a look. It must have been a Sketchup bug. I restarted Sketchup and the problem went away. A circle was mysteriously appearing at the base of face2 when I extruded it, but not anymore. – Jan Huus Feb 08 '17 at 18:35
  • @JanHuus Glad it's sorted. – Chris Hamilton Feb 08 '17 at 18:37
0

This was a bug in Sketchup, as indicated in comments above.

Jan Huus
  • 63
  • 8
  • Could have been a graphic card/driver issue - if it looked like an unexpected visual artefact. – thomthom Feb 08 '17 at 19:13
  • I don't think so, since the circle was selectable as a face in Sketchup. If it happens again I'll post the image. It was actually slightly more complex than a simple circle. Something like an inner circle with a semi-circle around it on the same plane. – Jan Huus Feb 09 '17 at 14:33