Inventory

Posted by Ashass on Fri 26 Nov 2010 11:14 PM — 3 posts, 17,700 views.

#0
So I was pondering, does anybody know a good method for tracking inventory? Below is a sample of what a typical inventory lookup looks like, when I push 'i' it shows the inventory. I was thinking a fairly easy way would be something like...

Match between "You are carrying:" and "***Prompt***"
EXCLUDE "***Any continuation prompts***"
If possible, I'd also like to capture the quantities of each items, ( NUMBER) - but not to have it mistaken with things like (Glowing)

Any ideas?

<1286/1286hp, 532/532m, 370/370mv, (Small Footpath)[NE]> 5:00pm. 
You are in excellent condition.
TICK IN 7 SECONDS!
i
You are carrying:
     (Glowing) Xiao's Bo
( 2) a sack of doughnut seeds
     a lumberjack's axe
( 9) a jerkied trail steak
     a simple wooden staff
     (Glowing) a jewel-encrusted shield
     a simple wooden staff
     a fine alloy studded leather helmet
     a decanter of endless water
     a black duster
( 4) a Robe of Many Pockets

<1286/1286hp, 532/532m, 370/370mv, (Small Footpath)[NE]> 5:00pm. 
You are in excellent condition.
Australia Forum Administrator #1
Have you seen this?

Template:post=9965
Please see the forum thread: http://gammon.com.au/forum/?id=9965.


Admittedly that is Lua and not VBscript. But the general idea is the same.

Or this:

Template:faq=37
Please read the MUSHclient FAQ - point 37.
#2
I'll take a look tomorrow morning when I'm fresh and see if I can digest it, looks like it will be a bit involved but I should be able to convert it *hopes*