IceChat Forums

IceChat 5 Scripting => Scripting => Topic started by: DarkStar on December 29, 2006, 02:28:58 PM

Title: onnick
Post by: DarkStar on December 29, 2006, 02:28:58 PM
is there a onnick sub? i couldnt find one but i noticed there was one in the mIRC style engine, so I kinda made my own, but i get problems with it whenever there is a [ or ] in the name.
the .ics file:
Code: [Select]
on *:NICK:/nickchange $oldnick $newnick $servernumberAlias:
Code: [Select]
/nickchange //! nickchange $1|$2|$3the .ice file:
Code: [Select]
Sub nickchange(oldnick,newnick,servernumber)
if lcase(newnick) <> lcase(mynickname) then
protect=getinifile("nicks.ini",network,newnick,"")
if len(protect) > 0 then SendCommand "/ns ghost " & newnick & " " & protect,servernumber
end if
End Sub
Sub ONJOIN(Nickname,Host,Channel,ServerNumber)
newnick=nickname
if lcase(newnick) <> lcase(mynickname) then
protect=getinifile("nicks.ini",network,newnick,"")
if len(protect) > 0 then SendCommand "/ns ghost " & newnick & " " & protect,servernumber
end if
End Sub
this is what i get when someone changes there name and there is a [ or ] in it.


* Orbis_[maybe] is now known as Orbis_[bathgoat]
->> maybe :Unknown command
->> bathgoat :Unknown command
Title: Re: onnick
Post by: Snerf on December 30, 2006, 02:46:58 AM
No, there never was any ONNICK sub created for VBS Scripting.
There is an obvious bug where its parsing the [ ]'s in a nickname to some kind of a script engine issue. I'll have a look at it.
Title: Re: onnick
Post by: Snerf on July 11, 2008, 11:22:48 AM
Sub ONNICK(NewNick,OldNick,ServerNumber)

End Sub