(bind-func psystem-add-particle
(lambda (psys:psystem* x y s xx yy r g b a dur)
(let ((size (psystem_size psys))
(free-particle (psystem-particle-check psys 0)))
(if (= free-particle -1)
void ;; don't do anything if no free particles
(begin (psystem-set-particle psys free-particle x y s xx yy r g b a dur)
void)))))