I’m using a library it has a public static float variable I want to know how to override it
I guess that’s not going to happen?
//Settings.java
package org.jbox2d.common;
public class Settings {
public static float velocityThreashold = 1.0f;
}
//MyClass.class
package org.jbox2d.common;
import com.otherlibrary
public class MyClass {
}
Thanks
The velocityThreashold variable in your example is not final, nor is it an instance variable and therefore cannot technically be overridden.
What you can do is set the value of velocityThreashold to any value you want since it’s public.
I think what you’re going to want to do is something like the following: