This site requires JavaScript, please enable it in your browser!
Greenfoot
Username
Password
Remember Me?
Sign Up, Lost Password
Activity
About
Documentation
Download
Discuss
Scenarios
Pointifix
wrote ...
2014/3/17
GetX(),GetY()
Pointifix
2014/3/17
#
Hi, me again. I wanted to know why i cant use GetX() or GetY() in my public Actor() class, cause the int value of GetX() and GetY() has not enough resolution to get an exact rolling ball.
Zamoht
2014/3/17
#
You should import the SmoothMover class - I think thats the name.
Pointifix
2014/3/17
#
ah very good idea never thought on that sry, thanks ;)
Pointifix
2014/3/17
#
how can i access the move(double distance) method of smooth mover?
Zamoht
2014/3/17
#
Just use the move method and insert a double value instead of the normal int value. Only works in subclasses of the smoothmover.
danpost
2014/3/17
#
If the class of the actor in question extends SmoothMover, then you should have no problem with just calling it directly:
move(doubleValue);
Pointifix
2014/3/17
#
ok must be a subclass of smoothmover thats the problem thanks ;)
You need to login to post a reply.
X