Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- (defmethod move-to ((atom cqm-atom) &rest r)
- (cond ((eql (list-length r) 1) ; r is a list of one vector-3d object
- (setf (location atom) (nth 0 r)))
- ((eql (list-length r) 3) ; r is a list of three cortesian coordnates x, y and z
- (let ((x (nth 0 r)) (y (nth 1 r)) (z (nth 2 r)))
- (setf (location atom) (make-instance 'vector-3d :x x :y y :z z))))))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement