228
229
230
231
232
233
234
235
236
237
238
239
240
241
|
# File 'ext/chipmunk/rb_cpShape.c', line 228
static VALUE
rb_cpCircleInitialize(int argc, VALUE * argv, VALUE self) {
VALUE body, radius, offset;
cpCircleShape *circle = NULL;
rb_scan_args(argc, argv, "21", &body, &radius, &offset);
circle = (cpCircleShape *)SHAPE(self);
cpCircleShapeInit(circle, BODY(body), NUM2DBL(radius), VGET_ZERO(offset));
circle->shape.data = (void *)self;
circle->shape.collision_type = Qnil;
rb_ivar_set(self, id_body, body);
return self;
}
|