0% found this document useful (0 votes)
3 views1 page

Ai Studio Code

Uploaded by

opchad33
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
3 views1 page

Ai Studio Code

Uploaded by

opchad33
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd

public void setAnimation(Animation animation) {

[Link] = animation;
[Link](name + " is now performing: " + animation);
}

public String getName() {


return name;
}

public int getHealth() {


return health;
}

public boolean isInLight() {


return isInLight;
}

public Animation getCurrentAnimation() {


return currentAnimation;
}

public enum Animation {


IDLE, ATTACK, HIT, DEFEATED
}

public static void main(String[] args) {


Fighter fighter1 = new Fighter("Light Warrior");
Fighter fighter2 = new Fighter("Shadow Slayer");

[Link]("--- Battle Start ---");

[Link](fighter2);
[Link]();
[Link](fighter1);
[Link](5); // Direct damage to test
[Link]();
[Link](fighter2);

[Link]("\n--- Battle Status ---");


[Link]([Link]() + " - Health: " + [Link]() +
", Mode: " + ([Link]() ? "Light" : "Shadow") + ", Animation: " +
[Link]());
[Link]([Link]() + " - Health: " + [Link]() +
", Mode: " + ([Link]() ? "Light" : "Shadow") + ", Animation: " +
[Link]());
}

You might also like