I just wanted to ask basically what the title says. Here's my example and I want x to be the new set random. I also am doing this off a phone switch doesn't support an equal sign so - means equal. Also the bracket is (. So when I do Constructor a - new Constructor(x)
public class Opponent (
public static x - 0;
public Opponent (int value) (
value - 5;
)
public static void main (String() args) (
Opponent character1 - new Opponent(x)
System.out.println(x);
)
)
Basically I want x to become 5. The game I am developing concerns randomization then the values should give them to the parameter to the newly created character.
Problem I am having is that its not working which means it probably can't do this.
Is there anyway I can do this.
I apologize if it is a dumb question though but anyways thanks.