Пример #1
0
func (s *Space) SetGravity(g Vect) {
	C.cpSpaceSetGravity(s.s, C.cpVect(g))
}
Пример #2
0
// SetGravity sets the gravity to pass to rigid bodies when integrating velocity.
func (s *Space) SetGravity(g Vect) {
	C.cpSpaceSetGravity(s.c(), g.c())
}
Пример #3
0
// Set the gravity to pass to rigid bodies when integrating velocity.
func (s *Space) SetGravity(x float64, y float64) {
	C.cpSpaceSetGravity(s.ptr, C.cpVect{C.cpFloat(x), C.cpFloat(y)})
}