blog.jj5.net (2003 to 2005)

How to handle WankerBase instances that implement IFuckwit

Fri Apr 23 22:18:00 UTC+1000 2004

Categories:

So, I got an e-mail today from G. G asks:

>hey mini
>
>I met a dude the other night
>
>I swear he derived from WankerBase and implemented IFuckwit

My answer:

Hi G,

Great observation! Although WankerBase instances are quite common, you might not properly handle the IFuckwit interface correctly if you don't plan for it. The best way to deal with wankers is the first time you meet them. That's the most important. You have other opportunities to deal with concrete Wankers but dealing with them up front is the most efficient. The way I do it, is to make sure I always test for the IFuckwit interface.

The best feature of the IFuckwit interface is the BreakNose(..) member.

Something like this from the top of my head (haven't got time to lookup the docs):

public interface IFuckwit {

  void BreakNose(ILegend weaponOwner, Int32 fragments);

  // ...

}

it relies on the ILegend interface, I think for an IWeapon instance, like this:

public interface ILegend {

  IWeapon GetPreferredWeapon();

  // ...

}

typical implementation:

public sealed class Burninator : ILegend {

  public IWeapon GetPreferredWeapon() {
    return this.Fist;
  }

  // ...

}


typical usage:

void OnMeetWanker(WankerBase wanker) {

  wanker.Insult(
    this.GetNextInsult(InsultTarget.Wanker)
    );

  if (wanker is IFuckwit) {

    wanker.Insult(
      this.GetNextInsult(InsultTarget.Wanker | InsultTarget.Fuckwit)
      );

    ((IFuckwit)wanker).BreakNose(this, 3);

  }
}

HTH,
John.


Copyright © 2003-2005 John Elliot