Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
tutorials:advanced:cram-rigid-body [2022/07/11 13:06] – vanessa | tutorials:advanced:cram-rigid-body [2022/07/11 13:08] – vanessa | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== Adding a new rigid body to the world====== | ====== Adding a new rigid body to the world====== | ||
- | In cram/ | + | **In cram/ |
- | + | ||
- | | + | |
<code lisp> | <code lisp> | ||
(defmethod add-object ((world bt-world) (type (eql : | (defmethod add-object ((world bt-world) (type (eql : | ||
- | & | + | & |
- | ;; (let ((compound-shape (make-instance ' | + | |
- | ;; | + | |
- | ;; | + | |
- | ;; compound-shape | + | |
- | ;; | + | |
- | ;; | + | |
- | ;; | + | |
- | ;; (make-instance ' | + | |
- | ;; :radius radius :color '(1 0 0 0.5)))) | + | |
- | + | ||
- | ;; ;; Adds the basket to the specified world | + | |
- | ;; | + | |
- | ;; (list | + | |
- | ;; | + | |
- | ;; :name name :mass mass :pose (ensure-pose pose) | + | |
- | ;; : | + | |
- | | + | |
(make-item world name (list type) | (make-item world name (list type) | ||
(list | (list |