body.go 317 B

1234567891011121314151617
  1. package physics
  2. import "gitlab.com/beoran/ebsgo/engine/geometry"
  3. // Body simulates a physical body in 2D
  4. type Body struct {
  5. P geometry.Vector // Position
  6. S geometry.Vector // Size of bounding box.
  7. V geometry.Vector // Velocity
  8. A geometry.Vector // Acceleration
  9. M float32 // Mass
  10. }