mIRC Home    About    Download    Register    News    Help

Print Thread
#250367 11/01/15 07:31 PM
B
Bramzee
Bramzee
B
Can't remember the bit that checks if the $nick is the owner of the channel... I looked in a few posts that I thought it was in, but haven't found it.

#250368 11/01/15 08:36 PM
Joined: Dec 2013
Posts: 771
N
Hoopy frood
Offline
Hoopy frood
N
Joined: Dec 2013
Posts: 771
I believe you're looking for
Code:
if ($nick == $mid(#,2-)) { do stuff }
Where
$nick = Nillen
$chan = #Nillen
$mid(#,2-) = Nillen

#250369 11/01/15 08:37 PM
Joined: Mar 2014
Posts: 214
J
Fjord artisan
Offline
Fjord artisan
J
Joined: Mar 2014
Posts: 214
is it twitch?
if so, you just need to check if $nick == ownername, there's no owner identifier.

if it's an channel, you'd need to work with the network's channel bot

Joined: Feb 2003
Posts: 2,737
Hoopy frood
Offline
Hoopy frood
Joined: Feb 2003
Posts: 2,737
judge: aren't all channels named after their owner? Eg, if the channel #IHeartRacingGames exists, then the owner is always going to be IHeartRacingGames ?


Well. At least I won lunch.
Good philosophy, see good in bad, I like!
Joined: Jan 2014
Posts: 107
M
Vogon poet
Offline
Vogon poet
M
Joined: Jan 2014
Posts: 107
Originally Posted By: Raccoon
judge: aren't all channels named after their owner? Eg, if the channel #IHeartRacingGames exists, then the owner is always going to be IHeartRacingGames ?


This is correct, except that (and I'm not sure if this matters) Twitch puts the entire owner name in lowercase.

So the channel name could be #IHeartRacingGames, but the chan owner would be iheartracinggames

B
Belhifet
Belhifet
B
channel names are case sensitive, so this is important. Fortunately this is particularly important because all nicks are lower case as well and then formatted after the fact.

#250403 13/01/15 08:52 AM
Joined: Feb 2003
Posts: 2,737
Hoopy frood
Offline
Hoopy frood
Joined: Feb 2003
Posts: 2,737
Channel names are case sensitive on Twitch? I don't believe this is the case.


Well. At least I won lunch.
Good philosophy, see good in bad, I like!
Joined: Dec 2013
Posts: 771
N
Hoopy frood
Offline
Hoopy frood
N
Joined: Dec 2013
Posts: 771
This is the case, #Nillens and #nillens are two different channels on twitch. If, as I have before when manually joining channels, you enter a channel with a capital letter, you won't be in the same room as the others as you'd expect to be.

Interesting fact however: If you're already in #nillens and attempt to join #Nillens, nothing will happen.

Joined: Feb 2003
Posts: 2,737
Hoopy frood
Offline
Hoopy frood
Joined: Feb 2003
Posts: 2,737
You shouldn't worry about case sensitivity then, since there will never be a condition where the opposing-case channel is populated by real people from the website, and there should never be a desire to join the wrong one from IRC. So, simply match the name against its owner; case-insensitive.


Well. At least I won lunch.
Good philosophy, see good in bad, I like!

Link Copied to Clipboard