Changeset 291


Ignore:
Timestamp:
09/22/03 09:45:17 (8 years ago)
Author:
jamesoff
Message:

unbroke ruser and rbot h4x0ring

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/modules/output.tcl

    r288 r291  
    202202    set newText [bMotion_abstract_get $BOOM] 
    203203    if {$newText == ""} { 
     204      #insert old style 
    204205      set var [subst $$BOOM] 
    205206      set line [bMotionInsertString $line "%VAR\{$BOOM\}" [pickRandom $var]] 
    206     } else { 
    207       #insert old style 
     207    } else {       
    208208      set line [bMotionInsertString $line "%VAR\{$BOOM\}" $newText] 
    209209    } 
     
    295295  } 
    296296 
     297  set ruser "" 
     298 
    297299  #choose a new user? 
    298300  if [regexp {^%PICKUSER\[(.+)?\]} $line matches conditions] { 
     
    306308  #try to get sensible names 
    307309  #set uhost [getchanhost $bMotionCache(randomUser)] 
    308   set ruser [bMotionGetRealName $bMotionCache(randomUser)] 
    309   set line [bMotionInsertString $line "%ruser" $ruser] 
     310 
     311  catch { 
     312    set ruser [bMotionGetRealName $bMotionCache(randomUser)] 
     313  } 
     314 
     315  if {$ruser != ""} { 
     316    set line [bMotionInsertString $line "%ruser" $ruser] 
     317  } 
    310318 
    311319  #set uhost [getchanhost $bMotionCache(remoteBot)] 
    312320  #putloglev 3 * "bMotion: remote bothost = $uhost" 
    313   set rbot [bMotionGetRealName $bMotionCache(remoteBot)] 
     321  set rbot "" 
     322  catch { 
     323    set rbot [bMotionGetRealName $bMotionCache(remoteBot)] 
    314324  #putloglev 3 * "bMotion: remote bot nick = $rbot" 
    315   set line [bMotionInsertString $line "%rbot" $rbot] 
     325  } 
     326 
     327  if {$rbot != ""} { 
     328    set line [bMotionInsertString $line "%rbot" $rbot] 
     329  } 
    316330 
    317331  set line [bMotionInterpolation2 $line] 
Note: See TracChangeset for help on using the changeset viewer.