This site requires JavaScript, please enable it in your browser!
Greenfoot back
The_Shados
The_Shados wrote ...

2016/2/10

Increasing speed

The_Shados The_Shados

2016/2/10

#
Hello, I am having trouble increasing the movement speed of a class after a certain action is performed.
danpost danpost

2016/2/10

#
The_Shados wrote...
Hello, I am having trouble increasing the movement speed of a class after a certain action is performed.
More appropriate would be:
I am having trouble with the code related to increasing the movement speed of an object of a class after a certain action is performed.
The code you are trying to use needs to be shown for it to be adjusted appropriately. Without it, one cannot tell what part you are actually having problems with at this point. There may be multiple issues and the most basic must be dealt with first.
Super_Hippo Super_Hippo

2016/2/10

#
In case you really want to increase the movement speed of all objects of a class:
//in ClassA
public static int MOVEMENT_SPEED = 5;
//from anywhere
ClassA.MOVEMENT_SPEED = 10;
For example
You need to login to post a reply.