Page 12 of 26 FirstFirst ... 2101112131422 ... LastLast
Results 111 to 120 of 254

Thread: Bored...anyone need a script written?

  1. #111

    Default

    Quote Originally Posted by Tgo01 View Post
    This should do what you want it to do:

    I know at the very least it counts each box once, that's good enough right?

    See?
    The function of it is perfect, but its math didn't seem quite right when I just tried it:

    >l
    >
    [Golden Helm, Hearth Room - 12506]
    An immense circular hearth fills the center of the room. A roast sizzles on a spit over the fire. The juices drip into the coals, popping and hissing as they land. Sturdy oak tables are set throughout, surrounded by chairs wide enough for the most ample of patrons. A pleasant breeze drifts through the open windows set high in the whitewashed wood-and-stone walls. You also see a plain gold strongbox, an enruned iron strongbox, a plain mithril strongbox, someone's disk, an acid-pitted brass trunk, a corroded mithril strongbox, a dented mithril coffer, an iron-bound maoral strongbox, a weathered wooden strongbox, an enruned gold coffer, an enruned mithril coffer, an enruned monir chest, an enruned steel box, an acid-pitted mithril box, a sturdy fel box, an enruned modwir box, a scratched steel box, a badly damaged modwir box, a disheveled calico cat, a sad ocean spirit that is flying around and a wood and glaes door.
    Also here: People
    Obvious exits: none
    >;boxcount
    --- Lich: boxcount active.
    gold strongbox x1
    iron strongbox x1
    mithril strongbox x2
    brass trunk x1
    mithril coffer x
    maoral strongbox x2
    wooden strongbox x1
    gold coffer x1
    monir chest x1
    steel box x
    mithril box x1
    fel box x2
    modwir box x1
    --- Lich: boxcount has exited.
    Several of the x2's were x1's and vice versa, a couple of them showed as just x when they were multiples. In particular, the fel box/modwir box one, the mithril coffer and steel box ones, and the x2 of the maoral strongbox.
    Last edited by Velfi; 10-02-2013 at 10:30 PM.

  2. #112

    Default

    It would probably be easier if I just had a list of all possible types of boxes; mithril, gold, iron, blah blah blah.

  3. #113

    Default

    Quote Originally Posted by Tgo01 View Post
    It would probably be easier if I just had a list of all possible types of boxes; mithril, gold, iron, blah blah blah.
    Brass, steel, iron, silver, gold, mithril, maoral, modwir, wooden, fel, monir ... I think that's all of the materials

    Chest, coffer, box, strongbox, trunk .. are all the box types

  4. #114

    Default

    Okay okay, this one should work for reals now.

    Code:
    box_name = Array.new
    box_count = Hash.new
    GameObj.loot.each{|i|
    	if i.type == 'box'
    		if i.name =~ /((brass|steel|iron|silver|gold|mithril|maoral|modwir|wooden|fel|monir|haon|tanik|thanot) (box|strongbox|chest|coffer|trunk))/i
    			name = $1
    			(box_name.push(name) unless box_name.include? (name);box_count[name] += 1)
    		end
    	end
    }
    box_name.each{|box|respond "#{box} x#{box_count[box]}"} if box_name != nil
    I also added haon, if you notice any other box types missing just add them to the list in the same format as they are already in.
    Last edited by Tgo01; 10-06-2013 at 09:42 PM.

  5. #115

    Default

    Quote Originally Posted by Tgo01 View Post
    Okay okay, this one should work for reals now.

    Code:
    box_name = Array.new
    box_number = Array.new
    GameObj.loot.each{|i|
    	if i.type == 'box'
    		if i.name =~ /((brass|steel|iron|silver|gold|mithril|maoral|modwir|wooden|fel|monir|haon) (box|strongbox|chest|coffer|trunk))/i
    			name = $1
    			(box_name.push(name);box_number[box_name.index(name)] += 1)
    		end
    	end
    }
    box_name.uniq! if box_name != nil
    box_name.each{|box|respond "#{box} x#{box_number[box_name.index(box)]}"} if box_name != nil
    I also added haon, if you notice any other box types missing just add them to the list in the same format as they are already in.
    I knew I was forgetting something. I'll try it again when I have another room of boxes. Thanks a bunch!

  6. #116

    Default

    Tanik too. Some picker used to exclaim "a ti-tanik chest!" whenever he opened a tanik coffer. I don't know what he said when he got a chest.
    Hasta pronto, porque la vida no termina aqui...
    America, stop pushing. I know what I'm doing.

  7. Default

    Also thanot. That should be it.
    Get Lich - Vote for Gemstone (topmudsites.com)

  8. #118

    Default

    Thanks for the other ones I forgot, hehe.

    I just tried it again, albeit with a few less boxes, and the math seemed good but I still have a blank x for some reason.

    s>l
    [Golden Helm, Hearth Room - 12506]
    An immense circular hearth fills the center of the room. A roast sizzles on a spit over the fire. The juices drip into the coals, popping and hissing as they land. Sturdy oak tables are set throughout, surrounded by chairs wide enough for the most ample of patrons. A pleasant breeze drifts through the open windows set high in the whitewashed wood-and-stone walls. You also see a cheery sunburst spirit that is flying around, the Velfi disk, a scratched gold strongbox, a badly damaged tanik chest, a plain brass chest, an enruned tanik strongbox, a corroded iron chest, a badly damaged fel strongbox, an engraved maoral strongbox, a badly damaged steel coffer, an iron-bound tanik coffer, a dented iron chest, a rotting modwir chest, a weathered thanot chest, the fiery red someone's disk, a disheveled calico cat and a wood and glaes door.
    Also here: People
    Obvious exits: none
    s>;boxcount
    --- Lich: boxcount active.
    gold strongbox x1
    tanik chest x1
    brass chest x1
    tanik strongbox x1
    iron chest x2
    fel strongbox x1
    maoral strongbox x1
    steel coffer x1
    tanik coffer x1
    modwir chest x
    thanot chest x1
    --- Lich: boxcount has exited.
    There was one modwir chest, but it just has an x for whatever reason.

  9. #119

    Default

    Quote Originally Posted by GS4-Seomanthe View Post
    Another wishlist script just occurred to me... One to squelch OOC whispers in the game window and punt them to the familiar, room, or other window -- I like making LOTR jokes during throwing-mysterious-artifacts-into-volcano events as much as the next guy, but sometimes I get completely derailed and lose track of what is going on around me...
    Code:
    fam_window_begin = "<pushStream id=\"familiar\" ifClosedStyle=\"watching\"/>"
    fam_window_end   = "<popStream/>\r\n"
    
    punt = proc { |ooc_string|
    	if ooc_string =~ /\(OOC\)/i
    		(puts("#{fam_window_begin}#{ooc_string}\r\n#{fam_window_end}"))
    		ooc_string = " "
    	else
    		ooc_string
    	end
    }
    DownstreamHook.add('script_name', punt)
    Last edited by Tgo01; 10-06-2013 at 01:36 PM.

  10. Default

    Something that can close my axe, run one of the sloots, then open my axe after sloot finishes so I'm not swinging with one axe instead of two. I could use the stow function of sloot, but I would prefer for safety's sake to close the axe instead of keeping it separated when it's not in hand.

    >open axe
    Holding your axe with both hands, you press a small button near your thumb and separate the weapon into two halves.
    >close axe
    Holding the two halves of your axe in each hand, you carefully recombine the two halves of your weapon into one.
    Last edited by Klinor; 10-04-2013 at 10:12 PM.

Similar Threads

  1. Looking to buy player written books
    By Morchal in forum Wanted
    Replies: 2
    Last Post: 04-23-2011, 10:31 PM
  2. Player-written Books
    By grossm in forum GSIV Merchant's Market
    Replies: 8
    Last Post: 12-01-2009, 03:59 PM
  3. The Greatest Plays Ever Written
    By Bobmuhthol in forum Off-Topic
    Replies: 10
    Last Post: 04-19-2007, 05:43 PM
  4. One of the best sci-fi short stories ever written
    By Numbers in forum Social Forum
    Replies: 4
    Last Post: 01-30-2007, 06:54 PM
  5. I got written up
    By Percocet in forum Social Forum
    Replies: 64
    Last Post: 09-08-2004, 02:27 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •