package gameplay.frames; import java.util.ArrayList; import gameplay.hitboxes.*; /** * Main class for frames * @author Victor Azra * */ public class Frame { private Double move_y; private Double move_x; private ArrayList passHitBox; private ArrayList actHitBox; private ArrayList passThrowHitBox; private ArrayList actThrowHitBox; private Push_HitBox pushHitBox; private boolean normalCancellable; private boolean specialCancellable; private boolean jumpCancellable; private boolean moveCancellable; private boolean isDashCancellable; public Frame() { this.setMove_y(0.0); this.setMove_x(0.0); this.setPassHitBox(new ArrayList()); this.setActHitBox(new ArrayList()); this.setPassThrowHitBox(new ArrayList()); this.setActThrowHitBox(new ArrayList()); this.setPushHitBox(new Push_HitBox()); this.normalCancellable = true; this.specialCancellable = true; this.jumpCancellable = true; this.moveCancellable = true; this.isDashCancellable = true; } public Frame(Double move_y, Double move_x, ArrayList passHitBox, ArrayList actHitBox, ArrayList passThrowHitBox, ArrayList actThrowHitBox, Push_HitBox pushHitBox, boolean normalCancellable, boolean specialCancellable, boolean jumpCancellable, boolean moveCancellable, boolean isDashCancellable) { this.setMove_y(move_y); this.setMove_x(move_x); this.setPassHitBox(passHitBox); this.setActHitBox(actHitBox); this.setPassThrowHitBox(passThrowHitBox); this.setActThrowHitBox(actThrowHitBox); this.setPushHitBox(pushHitBox); this.normalCancellable = normalCancellable; this.specialCancellable = specialCancellable; this.jumpCancellable = jumpCancellable; this.moveCancellable = moveCancellable; this.isDashCancellable = isDashCancellable; } /* * Mainly use for projectiles */ public Frame(Double move_y, Double move_x, ArrayList passHitBox, ArrayList actHitBox) { this.setMove_y(move_y); this.setMove_x(move_x); this.setPassHitBox(passHitBox); this.setActHitBox(actHitBox); this.setPassThrowHitBox(new ArrayList()); this.setActThrowHitBox(new ArrayList()); this.setPushHitBox(new Push_HitBox()); } public boolean isNormalCancellable() { return normalCancellable; } public boolean isSpecialCancellable() { return specialCancellable; } public boolean isJumpCancellable() { return jumpCancellable; } public boolean isMoveCancellable() { return moveCancellable; } public boolean isDashCancellable() { return isDashCancellable; } public Double getMove_y() { return move_y; } public void setMove_y(Double move_y) { this.move_y = move_y; } public Double getMove_x() { return move_x; } public void setMove_x(Double move_x) { this.move_x = move_x; } public ArrayList getPassHitBox() { return passHitBox; } public void setPassHitBox(ArrayList passHitBox) { this.passHitBox = passHitBox; } public ArrayList getActHitBox() { return actHitBox; } public void setActHitBox(ArrayList actHitBox) { this.actHitBox = actHitBox; } public ArrayList getPassThrowHitBox() { return passThrowHitBox; } public void setPassThrowHitBox(ArrayList passThrowHitBox) { this.passThrowHitBox = passThrowHitBox; } public ArrayList getActThrowHitBox() { return actThrowHitBox; } public void setActThrowHitBox(ArrayList actThrowHitBox) { this.actThrowHitBox = actThrowHitBox; } public Push_HitBox getPushHitBox() { return pushHitBox; } public void setPushHitBox(Push_HitBox pushHitBox) { this.pushHitBox = pushHitBox; } }