Class: ModelCircle

ModelCircle


new ModelCircle( [p_config])

Parameters:
Name Type Argument Description
p_config Object <optional>
Properties
Name Type Argument Default Description
r number <optional>
0
x number <optional>
0
y number <optional>
0
vx number <optional>
0
vy number <optional>
0
Properties:
Name Type Description
r number the radius of the circle
x number the x position of the circle
y number the y position of the circle
vx number the x velocity of the circle
vy number the y velocity of the circle
left number the x position of the left border (AABB)
right number the x position of the right border (AABB)
top number the y position of the top border (AABB)
bottom number the y position of the bottom border (AABB)
Source:

Methods


moveTo( [p_config])

Moves the circle to a specific point. By default it's moved to the point stated in the config object that has been passed to the constructor.
Parameters:
Name Type Argument Description
p_config Object <optional>
Properties
Name Type Description
x number
y number
Source:

start()

Starts the circle moving around.
Source:

stop()

Stops the circle moving around.
Source:

update(p_delta_s)

Parameters:
Name Type Description
p_delta_s number time in seconds since last call (max 1/60)
Source: