public virtual FullNote RetrieveNote(ChannelMessage message) { this.IndexInRange((int)message.Instrument()); int realId = message.Data1 - this.LowNoteID; if (realId < 0) { throw new ArgumentException(); } int note = 0; for (int i = 0; i <= realId; i++) { if (note == MAXINDEXFORNOTE) { note = 0; } else { note++; } } return(new FullNote(this.Transcribe(note), realId / MAXINDEXFORNOTE)); }