On first pass i changed it to this...
Code:
 
on *:TEXT:!friendsnick:*:msg $chan $nick Too add your nick and realname too my friends list just say this !addnick <realname>
;
on *:TEXT:!addnick & *:#:{
  if ($read(friends_nicks.txt,ntw,$2 *)) { 
    notice $nick You have already entered your realname on my nickname list as $gettok($v1,2-,32) $+ .
  } 
  else { 
    write friends_nicks.txt $2 $3-
    msg $chan $nick Your realname has been recorded under the $nick $+ . 
  } 
}  
;
on *:JOIN:#:{
  if ($nick == Hazza) {
    msg $nick you have been selected to add your nickname to my friends list
    msg $nick add your nick by typing !friendsnick hopefully it all works :P
  }
}

* code is untested

But without knowing what exactly its ment to do, i dont even know if its going to do what you expected.