mIRC Home    About    Download    Register    News    Help

Print Thread
Autochanging the Topic if someone enters #36726 16/07/03 05:03 PM
Joined: Jan 2003
Posts: 8
S
SirPeter Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
S
Joined: Jan 2003
Posts: 8
Are there ways to autochang the Topicname if someone enters a chan?

e.g. " a visitor -=Welkom=- (>^^)> Visitors_name <(^^<)

So what i would like to do is replace "Visitors_name" by the name of the person that enters the channel.


(ps im a noob here, so please make it simple for me to understand smile)


Re: Autochanging the Topic if someone enters #36727 16/07/03 05:07 PM
Joined: Jun 2003
Posts: 68
D
Dr4g0n Offline
Babel fish
Offline
Babel fish
D
Joined: Jun 2003
Posts: 68
on *:Join:#yourchan:{ topic $chan welcome $nick }

Re: Autochanging the Topic if someone enters #36728 16/07/03 05:11 PM
Joined: Dec 2002
Posts: 2,809
C
codemastr Offline
Hoopy frood
Offline
Hoopy frood
C
Joined: Dec 2002
Posts: 2,809
Note that that probably isn't a very good idea, if someone happens to load a bunch of clones into your channel, you will likely be killed for flooding.

Re: Autochanging the Topic if someone enters #36729 16/07/03 05:13 PM
Joined: Jan 2003
Posts: 8
S
SirPeter Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
S
Joined: Jan 2003
Posts: 8
Is it possible to make a timer in there?
Like only change the topic after 5 seconds after last topicchange?

Last edited by SirPeter; 16/07/03 05:13 PM.
Re: Autochanging the Topic if someone enters #36730 16/07/03 05:15 PM
Joined: Jun 2003
Posts: 68
D
Dr4g0n Offline
Babel fish
Offline
Babel fish
D
Joined: Jun 2003
Posts: 68
do this:
/set %topicprot off

on *:Join:#:{
if (%topicprot == on) { goto end }
else { goto :start }
:start
topic $chan welcome $nick
set %topicprot on
.timerprot 1 5 set %topicprot off
:end
}

Re: Autochanging the Topic if someone enters #36731 16/07/03 05:26 PM
Joined: Mar 2003
Posts: 1,271
L
LocutusofBorg Offline
Hoopy frood
Offline
Hoopy frood
L
Joined: Mar 2003
Posts: 1,271
on @*:JOIN:#channelname: {
if (!%topic) { /topic # NEW_TOPIC_HERE | set -u5 %topic yes }
}


DALnet #Helpdesk
I hear and I forget. I see and I remember. I do and I understand. -Confucius
Re: Autochanging the Topic if someone enters #36732 16/07/03 05:36 PM
Joined: Jan 2003
Posts: 8
S
SirPeter Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
S
Joined: Jan 2003
Posts: 8
Ok this is what ive done so far, with help of Borg and dragon:

In variabels:
%topicprot on

In Remote:
on @*:JOIN:#kotrn: {
if (%topicprot == off) { goto end }
else { goto :start }
:start
/timerprot 1 5 set %topicprot on
if (!%topic) { /topic # OMG!!! a visitor 10-=Welkom=- 4(>^^)> $nick <(^^<)  | set -u5 %topic yes }
:end
}


Not working thou

Re: Autochanging the Topic if someone enters #36733 16/07/03 06:31 PM
Joined: Jun 2003
Posts: 68
D
Dr4g0n Offline
Babel fish
Offline
Babel fish
D
Joined: Jun 2003
Posts: 68
do this:
/set %topicprot off

on *:Join:#yourchan:{
if (%topicprot == on) { goto end }
else { goto start }
:start
topic $chan welcome $nick
set %topicprot on
.timerprot 1 5 set %topicprot off
:end
}

This is the good one

Re: Autochanging the Topic if someone enters #36734 16/07/03 06:48 PM
Joined: Jan 2003
Posts: 8
S
SirPeter Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
S
Joined: Jan 2003
Posts: 8
Jep now it works

smile

Re: Autochanging the Topic if someone enters #36735 16/07/03 06:49 PM
Joined: Mar 2003
Posts: 1,271
L
LocutusofBorg Offline
Hoopy frood
Offline
Hoopy frood
L
Joined: Mar 2003
Posts: 1,271
Actually the code I pasted, was all you need to change the topic whenever someone joins, but no more than once every 5 seconds.... Don't need any goto stuff and timers...


DALnet #Helpdesk
I hear and I forget. I see and I remember. I do and I understand. -Confucius
Re: Autochanging the Topic if someone enters #36736 16/07/03 07:48 PM
Joined: Jun 2003
Posts: 68
D
Dr4g0n Offline
Babel fish
Offline
Babel fish
D
Joined: Jun 2003
Posts: 68
if (!%topic) doe mean?
if (%topic != $null) { ?????

Re: Autochanging the Topic if someone enters #36737 16/07/03 08:03 PM
Joined: Mar 2003
Posts: 437
M
MTech Offline
Fjord artisan
Offline
Fjord artisan
M
Joined: Mar 2003
Posts: 437
more or less

if (!%topic)
means
if (%topic == $null)

Re: Autochanging the Topic if someone enters #36738 16/07/03 08:04 PM
Joined: Mar 2003
Posts: 1,271
L
LocutusofBorg Offline
Hoopy frood
Offline
Hoopy frood
L
Joined: Mar 2003
Posts: 1,271
Or , in english, if %topic has no value. Be careful tho, because the value 0 is considered to not be a value.


DALnet #Helpdesk
I hear and I forget. I see and I remember. I do and I understand. -Confucius
Re: Autochanging the Topic if someone enters #36739 16/07/03 08:23 PM
Joined: Dec 2002
Posts: 2,809
C
codemastr Offline
Hoopy frood
Offline
Hoopy frood
C
Joined: Dec 2002
Posts: 2,809
$false is also treated that way as well.