This is a simple snippet for your bot,
It will output the user nick in the correct casing.
If the user is not in the channel it will return as requested.
Example:
The users IlkoTech, User and Bot are in the channel
!slap UseR
* Bot slaps User
The bot would simply need this snippet loaded and in its script
on *:TEXT:!slap *:#:{ describe slaps $nickc($2) }
No matter what casing the user uses it will always return the correct casing.
If a user isnt in the channel it will just return the normal text,
Same example as above:
The users IlkoTech, PersON and Bot are in the channel
!slap PersOn
* Bot slaps PersON
I hope that helps.
```mirc
alias nickc {
if ( $1 ison $chan ) {
var %times $nick(#,0)
var %i = 1
while (%i <= %times) {
if ( $nick(#,%i) == $1 ) {
var %nick $nick(#,%i)
}
inc %i
}
return %nick
}
else {
return $1
}
}
```