Hi im currently working on a script for a turn based game that ppl can insert a number of turns they currently have and other ppl can to and it will total the amount of turns of everyone in the channel. Well i got the whole script to work except i need it to change when ever someone changes their name. So say someones name is Bob and has 20 turns then he changes his name to Bob|away i want it so the has table deletes the first entry of Bob 20 to Bob|away 20... this is the code i have so far but all it seems to do is delete the old name and insert the new one but with out the turn value. Please help if you can Thank you.

(and yes i new to IRC scripting)

on *:NICK: {
var %i = $hget(table,$nick)
if ($nick !ison #chan) {
hadd table $newnick %i
hdel table $nick
}
}