!info

Published  Feb 01, 2011
Updated  Feb 01, 2011

Description

need help, this script cant collecting infos from some users,idk why...

;=================== ;= User Stats v1.5 = ;===================

alias stats.save { hsave Stats Stats.hsh timersave 0 120 stats.save }

on *:START: { hmake Stats 9999 stats.save hload Stats Stats.hsh }

;=========== ;== Joins == ;===========

on :JOIN:: {

;========= ;= Start = ;=========

if ($hget(Stats,$nick $+ .TextCount) = $null) { hadd -m Stats $nick $+ .TextCount 0 } if ($hget(Stats,$nick $+ .ChrCount) = $null) { hadd -m Stats $nick $+ .ChrCount 0 } if ($hget(Stats,$nick $+ .BanCount) = $null) { hadd -m Stats $nick $+ .BanCount 0 } if ($hget(Stats,$nick $+ .PartCount) = $null) { hadd -m Stats $nick $+ .PartCount 0 } if ($hget(Stats,$nick $+ .BannedCount) = $null) { hadd -m Stats $nick $+ .BannedCount 0 } if ($hget(Stats,$nick $+ .KickCount) = $null) { hadd -m Stats $nick $+ .KickCount 0 } if ($hget(Stats,$nick $+ .KickedCount) = $null) { hadd -m Stats $nick $+ .KickedCount 0 } if ($hget(Stats,$chan $+ .BanCount) = $null) { hadd -m Stats $chan $+ .BanCount 0 } if ($hget(Stats,$chan $+ .KickCount) = $null) { hadd -m Stats $chan $+ .KickCount 0 } if ($hget(Stats,$chan $+ .PartCount) = $null) { hadd -m Stats $chan $+ .PartCount 0 }

;======== ;= Nick = ;========

;if ($hget(Stats,$nick $+ .JoinCount) = $null) { notice $nick 7Hello there $nick, I will be taking random statistics on you. If you wish to see these stats at anytime simply type !info $nick } if ($hget(Stats,$nick $+ .JoinCount) = $null) { hadd -m Stats $nick $+ .Start $fulldate | hadd -m Stats $nick $+ .JoinCount 1 } if ($hget(Stats,$nick $+ .JoinCount) != $null) { hadd -m Stats $nick $+ .JoinCount $calc($hget(Stats,$nick $+ .JoinCount) + 1) }

;=========== ;= Channel = ;===========

if ($hget(Stats,$chan $+ .JoinCount) = $null) {

hadd -m Stats $chan $+ .Start $fulldate 
hadd -m Stats $chan $+ .JoinCount 1 

} if ($hget(Stats,$chan $+ .JoinCount) != $null) { hadd -m Stats $chan $+ .JoinCount $calc($hget(Stats,$chan $+ .JoinCount) + 1) } }

;=========== ;== Parts == ;===========

on :PART:: {

;======== ;= Nick = ;========

if ($hget(Stats,$nick $+ .PartCount) = $null) { hadd -m Stats $nick $+ .PartCount 1 } if ($hget(Stats,$nick $+ .PartCount) != $null) { hadd -m Stats $nick $+ .PartCount $calc($hget(Stats,$nick $+ .PartCount) + 1) }

;=========== ;= Channel = ;===========

if ($hget(Stats,$chan $+ .PartCount) = $null) { hadd -m Stats $nick $+ .PartCount 1 } if ($hget(Stats,$chan $+ .PartCount) != $null) { hadd -m Stats $chan $+ .PartCount $calc($hget(Stats,$chan $+ .PartCount) + 1) } }

;======== ;= Bans = ;========

on *:BAN:#: {

;======== ;= Nick = ;========

if ($hget(Stats,$nick $+ .BanCount) = $null) { hadd -m Stats $nick $+ .BanCount 1 } if ($hget(Stats,$nick $+ .BanCount) != $null) { hadd -m Stats $nick $+ .BanCount $calc($hget(Stats,$nick $+ .BanCount) + 1) } if ($hget(Stats,$bnick $+ .BannedCount) = $null) { hadd -m Stats $bnick $+ .BannedCount 1 } if ($hget(Stats,$bnick $+ .BannedCount) != $null) { hadd -m Stats $bnick $+ .BannedCount $calc($hget(Stats,$bnick $+ .BannedCount) + 1) }

;=========== ;= Channel = ;===========

if ($hget(Stats,$chan $+ .BanCount) = $null) { hadd -m Stats $chan $+ .BanCount 1 } if ($hget(Stats,$chan $+ .BanCount) != $null) { hadd -m Stats $chan $+ .BanCount $calc($hget(Stats,$chan $+ .BanCount) + 1) } }

;========= ;= Kicks = ;=========

on *:KICK:#: {

;======== ;= Nick = ;========

if ($hget(Stats,$nick $+ .KickCount) = $null) { hadd -m Stats $nick $+ .KickCount 1 } if ($hget(Stats,$nick $+ .KickCount) != $null) { hadd -m Stats $nick $+ .KickCount $calc($hget(Stats,$nick $+ .KickCount) + 1) } if ($hget(Stats,$knick $+ .KickedCount) = $null) { hadd -m Stats $knick $+ .KickedCount 1 } if ($hget(Stats,$knick $+ .KickedCount) != $null) { hadd -m Stats $knick $+ .KickedCount $calc($hget(Stats,$knick $+ .KickedCount) + 1) }

;=========== ;= Channel = ;===========

if ($hget(Stats,$chan $+ .BanCount) = $null) { hadd -m Stats $chan $+ .BanCount 1 } if ($hget(Stats,$chan $+ .BanCount) != $null) { hadd -m Stats $chan $+ .BanCount $calc($hget(Stats,$chan $+ .BanCount) + 1) } }

;======== ;= Text = ;========

on :TEXT::*: {

;================= ;= Channel Stats = ;=================

if ($hget(Stats,$chan $+ .TextCount) = $null) { hadd -m Stats $chan $+ .TextCount 1 } if ($hget(Stats,$chan $+ .TextCount) != $null) { hadd -m Stats $chan $+ .TextCount $calc($hget(Stats,$chan $+ .TextCount) + 1) } if ($hget(Stats,$chan $+ .ChrCount) = $null) { hadd -m Stats $chan $+ .ChrCount $len($1-) } if ($hget(Stats,$chan $+ .ChrCount) != $null) { hadd -m Stats $chan $+ .ChrCount $calc($hget(Stats,$chan $+ .ChrCount) + $len($1-)) }

;============== ;= User Stats = ;==============

if ($hget(Stats,$nick $+ .TextCount) = $null) { hadd -m Stats $nick $+ .TextCount 1 } if ($hget(Stats,$nick $+ .TextCount) != $null) { hadd -m Stats $nick $+ .TextCount $calc($hget(Stats,$nick $+ .TextCount) + 1) } if ($hget(Stats,$nick $+ .ChrCount) = $null) { hadd -m Stats $nick $+ .ChrCount $len($1-) } if ($hget(Stats,$nick $+ .ChrCount) != $null) { hadd -m Stats $nick $+ .ChrCount $calc($hget(Stats,$nick $+ .ChrCount) + $len($1-)) }

;========= ;= !info = ;=========

if ($1 = !info) {

if ($hget(Stats,$2 $+ .JoinCount) = $null) && ($2 !ison $chan) { 
  msg $chan 3S7orry 3 $+ $left($nick,1) $+ 7 $+ $right($nick,$calc($len($nick) - 1)) $+ , 3b7ut 3 $+ $left($2,1) $+ 7 $+ $right($2,$calc($len($2) - 1)) 3w7as 3n7ot 3f7ount 3i7n 3t7he 3d7atabase 
  halt
} 
if ($hget(Stats,$2 $+ .JoinCount) = $null) && ($2 ison $chan) { 
  msg $chan 4[ERROR]14 I have not started taking stats for $2 yet, i will as soon as they re-join. 
  halt
}

;=================
;= Channel Stats =
;=================

if (# isin $2) {
  msg $chan 15[4Stats for  $+ $2 $+ 15]
  msg $chan 15[14Lines of Text:  $+ $hget(Stats,$2 $+ .TextCount) $+ 15][7Characters said:  $+ $hget(Stats,$2 $+ .ChrCount) $+ 15]
  msg $chan 15[14Join Count:  $+ $hget(Stats,$2 $+ .JoinCount) $+ 15][7Part Count:  $+ $hget(Stats,$2 $+ .PartCount) $+ 15]
  msg $chan 15[14Ban Count:  $+ $hget(Stats,$2 $+ .BanCount) $+ 15][7Kick Count:  $+ $hget(Stats,$2 $+ .KickCount) $+ 15]
  msg $chan 15[14I have been taking stats for $2 since:  $+ $hget(Stats,$2 $+ .Start) $+ 15]
}

;==============
;= User Stats =
;==============

if (# !isin $2) {
  msg $chan 15[4Stats for 4 $+ $2 $+ 15]
  msg $chan 15[14Lines of Text: 4 $+ $hget(Stats,$2 $+ .TextCount) $+ 15][14Characters said: 4 $+ $hget(Stats,$2 $+ .ChrCount) $+ 15]
  msg $chan 15[14Join Count: 4 $+ $hget(Stats,$2 $+ .JoinCount) $+ 15][14Part Count: 4 $+ $hget(Stats,$2 $+ .PartCount) $+ 15]
  msg $chan 15[14Bans: 4 $+ $hget(Stats,$2 $+ .BanCount) $+ 15][14Kicks: 4 $+ $hget(Stats,$2 $+ .KickCount) $+ 15]
  msg $chan 15[14Times Banned: 4 $+ $hget(Stats,$2 $+ .BannedCount) $+ 15][14Times Kicked: 4 $+ $hget(Stats,$2 $+ .KickedCount) $+ 15]
  msg $chan 15[14I have been taking stats for $2 since: 4 $+ $hget(Stats,$2 $+ .Start) $+ 15]
} 

} }

Comments

Sign in to comment.
Aha2Y   -  Mar 27, 2011

lol'd

More
 Respond  
Callumlord   -  Mar 26, 2011

Why did you not put the code as Code not in the Description?

More
 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.