CengBall: API (documented for version: v0.5)

MovingObject Class

(!)ObjectType does not belong library v0.5.
Method name Parameters Return Description
MovingObject vector2D, vector2D, double, ObjectType constructor The core class for moving objects in the game. Constructor takes position, speed, radius and type parameters.
getDirectionVector none vector2D Gets the direction vector.
getPosition none vector2D Gets the position of the moving object.
getRadius none double Gets the radius.
getSpeed none vector2D Gets the speed of the moving object.
getSpeedAngle none double Gets the speed angle.
getType none ObjectType description
getUpperLeftCornerPosition none vector2D Gets the position of the upper left corner of this moving object.
move double, double void Moves the object with the given friction acceleration in specified time difference. Parameters are: a constant number to create friction notion and the time to move the object. ( in seconds )
setDirectionVector vector2D void Sets the direction vector of the moving object.
setPosition vector2D void Sets the position of the moving object.
setRadius double void Sets the radius.
setSpeed vector2D void Sets the speed of the moving object.
setType (!)ObjectType void Sets the type of the moving object.
toString none String Properties of class object is returned for human reading. (Logging purposes)

Attribute type Attribute name Description
none none Can not be reached any attribute of this.

TODO

News from CengBall

Quick Tutorial

How to set jdk path
How to import code

Twitter

    Follow @cengball

    © Copyright - Project 11