/// <summary> /// adds the given attack effect to AttackEffects /// </summary> /// <param name="weaponEffect"> This weapon effect is added</param> public void AddEffect(AttackEffect weaponEffect) { theAttackEffects.Add(weaponEffect); // adds the element to the list // call setcurrentgame on new element // finds the last element of list ( the newly added attackeffect and calls function theAttackEffects[(theAttackEffects.Count - 1)].SetCurrentGame(this); }
public void AddEffect(AttackEffect weaponEffect) { /// <summary> /// /// This method adds the given AttackEffect to its list/array of AttackEffects. /// /// </summary> _effect.Add(weaponEffect); }
public void RemoveWeaponEffect(AttackEffect weaponEffect) { /// <summary> /// /// This method removes the AttackEffect referenced by weaponEffect from the array or list used by /// Game to store active AttackEffects. /// /// </summary> _effect.Remove(weaponEffect); }
public void EndEffect(AttackEffect weaponEffect) { lAttackEffect.Remove(weaponEffect); }
public void AddWeaponEffect(AttackEffect weaponEffect) { weaponEffect.RecordCurrentGame(this); lAttackEffect.Add(weaponEffect); }
/// <summary> /// removes referenced weapon effect from attackeffects /// </summary> /// <param name="weaponEffect">remove this effect</param> public void RemoveWeaponEffect(AttackEffect weaponEffect) { theAttackEffects.Remove(weaponEffect); // removes the element }
public void CancelEffect(AttackEffect weaponEffect) { attackEffectList.Remove(weaponEffect); }