mIRC Home    About    Download    Register    News    Help

Print Thread
#144542 11/03/06 11:50 AM
Joined: Mar 2006
Posts: 10
M
Massari Offline OP
Pikka bird
OP Offline
Pikka bird
M
Joined: Mar 2006
Posts: 10
Okay, now Im working on a kebab script :tongue: (im lebanese)

;KEBAB SCRIPT
on 1:TEXT:*kebab*:#: {
if ($nick == Dave) { /msg $chan $me eats the kebab infront of $nick }
else { /msg $chan $me gives $nick a kebab smile $me has given out XX Kebabs }
}

I have a couple of questions that couldn't be answered by the help file as it made no sense to me.

1. I want it to keep record of how many kebabs I have given out. This would be on the line
Code:
  else { /msg $chan $me gives $nick a kebab :) $me has given out XX Kebabs }  
I know its got something to do with variables but I just cant get it...

2. For this line
Code:
  if ($nick == Dave) { /msg $chan $me eats the kebab infront of $nick } 
how do I make it like if the nick is dave, bob, katie (have more names in the place of dave) it says that message.

3. How would i make a limit of the amount of times you can use the code. EG you can only ask for a kebab once every 10 seconds or so (to stop spamming)

Thanks all for your response in advance.

#144543 11/03/06 12:27 PM
Joined: Feb 2006
Posts: 54
T
Babel fish
Offline
Babel fish
T
Joined: Feb 2006
Posts: 54
we are talking about doner kebab or just kebab ? j/k smile
Code:
  
on 1:TEXT:*kebab*:#: {
  inc -u10 %kebab.reguest.all.sites
  if (%kebab.reguest.all.sites == 1) {
    var %names = Dave,bob,dylan,achmet
    if ($istok(%names,$nick,44)) { msg $chan $me eats the kebab infront of $nick }
    else { inc %kebab.give.out | msg $chan $me gives $nick a kebab $me has given out %kebab.give.out Kebabs }
  }
}




#144544 11/03/06 10:46 PM
Joined: Mar 2006
Posts: 10
M
Massari Offline OP
Pikka bird
OP Offline
Pikka bird
M
Joined: Mar 2006
Posts: 10
Code:
 KEBAB SCRIPT
on 1:TEXT:*kebab*:#: {
  inc -u60 %kebab.reguest.all.sites
  if (%kebab.reguest.all.sites == 1) {
    var %names = Dave,commander55,massari
    if ($istok(%names,$nick,44)) { inc %kebab.rotten | /msg $chan $me eats the LEBANESE kebab infront of $nick . $me has eaten xx kebabs today. $me has eaten %kebab.rotten Kebabs since 12/03/06 }
    else { inc %kebab.give.out | { msg $chan $me gives $nick a LEBANESE kebab. $me has given out %kebab.give.out Kebabs today. $me has given out XX Kebas since 12/03/06 }
    }
  }
 


LOL firstly its a LEBANSE Kebab wink anyway, ive changed the script a bit. But I dont udnerstand these lines, and what they do (i think its a timer script)


Code:
 inc -u60 %kebab.reguest.all.sites
  if (%kebab.reguest.all.sites == 1) { 


Anyways, some other things i want to do to this script is.. for this line (and the other one)
Code:
 | /msg $chan $me eats the LEBANESE kebab infront of $nick . $me has eaten xx kebabs today. $me has eaten %kebab.rotten Kebabs since 12/03/06 } 


make it say how many kebabs I have eaten/given out in one day.

the last thing I want to do is make an if statment that says if i have given > 10 kebabs or eaten more then > 10 kebabs i do *action here* where would the statement go, and how do i add a second variable that restarts daily....

thanks again wink


Link Copied to Clipboard