Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » CMUD Beta Forum
oldguy2
Wizard


Joined: 17 Jun 2006
Posts: 1201

PostPosted: Fri Sep 11, 2009 4:48 am   

[3.10] Logging and %expandlist
 
For some reason when I #print %expandlist($list,",") for example it prints the line multiple times in the log. I'm curious why it is writing it 2 or 3 times to the log file? It only prints it once to the display but multiple times to the log file.
Reply with quote
Tech
GURU


Joined: 18 Oct 2000
Posts: 2733
Location: Atlanta, USA

PostPosted: Sat Sep 12, 2009 7:51 pm   
 
I think something must be going on with one of your other triggers. I just tested this in a blank session on it only printed once to the log.
_________________
Asati di tempari!
Reply with quote
oldguy2
Wizard


Joined: 17 Jun 2006
Posts: 1201

PostPosted: Tue Sep 15, 2009 9:04 pm   
 
I don't know how because it only prints to the screen one time like it should.
Reply with quote
oldguy2
Wizard


Joined: 17 Jun 2006
Posts: 1201

PostPosted: Mon Oct 05, 2009 12:14 am   
 
Well it seems to do it while connected. I have a master list of all defenses which I iterate through and check against the variable value.

It looks like this:

Code:
$count = 0
$list = ""
#forall @DEFLIST {
  #if (!@{%i}) {
    $count = $count + 1
    #additem $list %i
    }
  }
#if ($count > 0) {
  #wait 500
  #print ""
  #print {<color brown>%repeat("=",92)</color>}
  #print {<color yellow><strong>You are missing the following defs:</strong></color>}
  #print {<color brown>%repeat("=",92)</color>}
  #print {<color khaki> %expandlist($list, ", ") </color>}
  #print {<color brown>%repeat("=",92)</color>}
  } {
  #print ""
  #print {<color red>No defenses have been recorded!</color>}
  }


Almost every time it prints the list a couple times in the log. It only prints the list multiple times though. It doesn't print the other lines multiple times. On the screen it shows just like it does in the script here, but in the log you see something like the following:

===================================
You are missing the following defs:
===================================
a, b, c, d, e, f, g
a, b, c, d, e, f, g
a, b, c, d, e, f, g
===================================


Last edited by oldguy2 on Mon Oct 05, 2009 12:19 am; edited 1 time in total
Reply with quote
oldguy2
Wizard


Joined: 17 Jun 2006
Posts: 1201

PostPosted: Mon Oct 05, 2009 12:14 am   
 
Oops. It seems I double posted.
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » CMUD Beta Forum All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

© 2009 Zugg Software. Hosted by Wolfpaw.net