Advertisement
VTsilaLETImogila

Untitled

Nov 11th, 2019
132
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.54 KB | None | 0 0
  1. package laba2;
  2.  
  3. public class Spectors extends Mumi {
  4.     public Spectors(String name) {
  5.         super(name);
  6.     }
  7.     @Override
  8.     public void addSkill(Skill skill) {
  9.         if (skills.add(skill)){
  10.             System.out.println(this.getName() +  " начали " + skill.getName());
  11.         }
  12.     }
  13.     @Override
  14.     public void addCond(Cond conditional) {
  15.         if (Conditional.add(conditional)){
  16.             System.out.println(this.getName() +  " были " + conditional.getName());
  17.         }
  18.     }
  19. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement