position.rb

Path: lib/ode/position.rb  (CVS)
Last Update: Wed Jul 27 19:46:00 EDT 2005

This file contains the ODE::Position class, instances of which represent a position point in an ODE::World simulation.

Synopsis

  require 'ode'

  pos = ODE::Position::new( 12.1, 19, 13 )
  body.position = pos

  body.position = 12.1, 19, 13
  body.position
  # => <ODE::Position: 12.10000, 19.00000, 13.00000>

  puts "Body is at: %0.2f x %0.2f x %0.2f" % [ pos.x, pos.y, pos.z ]
  # -> Body is at: 12.10 x 19.00 x 13.00

Authors

  • Michael Granger <ged@FaerieMUD.org>

Copyright © 2002, 2003 The FaerieMUD Consortium.

This work is licensed under the Creative Commons Attribution License. To view a copy of this license, visit creativecommons.org/licenses/by/1.0 or send a letter to Creative Commons, 559 Nathan Abbott Way, Stanford, California 94305, USA.

Version

 $Id: position.rb 91 2005-07-27 23:45:01Z ged $

Required files

ode/Vector  

[Validate]