Class WeaponAuraComponent
java.lang.Object
com.deco2800.game.components.Component
com.deco2800.game.components.combatitemscomponents.WeaponAuraComponent
Component used to store information and methods related to weapon buffs, debuffs and curses.
-
Field Summary
-
Constructor Summary
ConstructorsConstructorDescriptionWeaponAuraComponent
(int auraDuration, double dmgMultiplier, double areaMultiplier, double durationMultiplier, double cdMultiplier) WeaponAuraComponent
(int auraDuration, double dmgMultiplier, double cdMultiplier, String description) -
Method Summary
Modifier and TypeMethodDescriptiondouble
Return the multiplier on the radius that the weapon can deal damage toint
Return how long the aura is activated for the weapondouble
Return the cooldown multiplier on the weaponReturns the aura descriptiondouble
Return the damage multiplier on the weapondouble
Return the multiplier on the duration before the next attack instance can be calledvoid
setAreaMultiplier
(double areaMultiplier) Set the multiplier on the radius that the weapon can deal damage tovoid
setAuraDuration
(int auraDuration) Set how long the aura is activated for the weaponvoid
setCdMultiplier
(double cdMultiplier) Set the cooldown multiplier on the weaponvoid
setDescription
(String description) Sets the description of the auravoid
setDmgMultiplier
(double dmgMultiplier) Set the damage multiplier on the weaponvoid
setDurationMultiplier
(double durationMultiplier) Set the multiplier on the duration before the next attack instance can be calledMethods inherited from class com.deco2800.game.components.Component
create, dispose, earlyUpdate, getEntity, setEnabled, setEntity, toString, triggerEarlyUpdate, triggerUpdate, update
-
Constructor Details
-
WeaponAuraComponent
public WeaponAuraComponent(int auraDuration, double dmgMultiplier, double cdMultiplier, String description) - Parameters:
auraDuration
- how long the aura is activated for the weapondmgMultiplier
- damage multiplier effect on the weaponcdMultiplier
- cooldown multiplier effect on the weapondescription
- description of the weapon
-
WeaponAuraComponent
public WeaponAuraComponent(int auraDuration, double dmgMultiplier, double areaMultiplier, double durationMultiplier, double cdMultiplier) - Parameters:
auraDuration
- how long the aura is activated for the weapondmgMultiplier
- damage multiplier effect on the weaponareaMultiplier
- multiplier on the radius that the weapon can deal damage todurationMultiplier
- multiplier on the duration before the next attack instance can be calledcdMultiplier
- cooldown multiplier effect on the weapon
-
-
Method Details
-
setDescription
Sets the description of the aura- Parameters:
description
- description of the aura
-
setAuraDuration
public void setAuraDuration(int auraDuration) Set how long the aura is activated for the weapon- Parameters:
auraDuration
- how long the aura is activated for the weapon
-
setDmgMultiplier
public void setDmgMultiplier(double dmgMultiplier) Set the damage multiplier on the weapon- Parameters:
dmgMultiplier
- damage multiplier effect on the weapon
-
setCdMultiplier
public void setCdMultiplier(double cdMultiplier) Set the cooldown multiplier on the weapon- Parameters:
cdMultiplier
- cooldown multiplier on the weapon
-
setDurationMultiplier
public void setDurationMultiplier(double durationMultiplier) Set the multiplier on the duration before the next attack instance can be called- Parameters:
durationMultiplier
- multiplier on the duration before the next attack instance can be called
-
setAreaMultiplier
public void setAreaMultiplier(double areaMultiplier) Set the multiplier on the radius that the weapon can deal damage to- Parameters:
areaMultiplier
- multiplier on the radius that the weapon can deal damage to
-
getDmgMultiplier
public double getDmgMultiplier()Return the damage multiplier on the weapon- Returns:
- damage multiplier on the weapon
-
getCdMultiplier
public double getCdMultiplier()Return the cooldown multiplier on the weapon- Returns:
- cooldown multiplier on the weapon
-
getAreaMultiplier
public double getAreaMultiplier()Return the multiplier on the radius that the weapon can deal damage to- Returns:
- multiplier on the radius that the weapon can deal damage to
-
getDurationMultiplier
public double getDurationMultiplier()Return the multiplier on the duration before the next attack instance can be called- Returns:
- multiplier on the duration before the next attack instance can be called
-
getAuraDuration
public int getAuraDuration()Return how long the aura is activated for the weapon- Returns:
- duration the aura is activated for the weapon
-
getDescription
Returns the aura description- Returns:
- description of the aura
-