23 lines
458 B
C#
Raw Normal View History

2021-09-14 12:31:36 +12:00
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace DuckModel
{
2021-09-16 17:55:28 +12:00
public class DecoyDuck : DuckBehaviour
2021-09-14 12:31:36 +12:00
{
public override void Display()
{
2021-09-16 17:55:28 +12:00
Console.WriteLine("I am a decoy duck");
2021-09-14 12:31:36 +12:00
}
2021-09-16 17:55:28 +12:00
public DecoyDuck()
2021-09-14 12:31:36 +12:00
{
base.SetFlyBehaviour(new NoFly());
base.SetQuackBehaviour(new MuteQuack());
}
}
}