Greeeetings y'all!
I was looking to put some color to the health of NPC's on my MUD.
When you send the "health all" command, you can see the following:
You are physically somewhat hurt and mentally in full vigour.
The foot soldier is physically in a very bad shape and has a multi-colored swollen left hip.
The foot soldier is physically feeling very well.
What I want to color code is the in a very bad shape
and feeling very well
with different colors depending on their physical state: at death's door, barely alive, terribly hurt, in a very bad shape,in a bad shape, very hurt, feeling rather hurt, hurt, somewhat hurt, slightly hurt and feeling very well.
So I would like the result to be something like:You are physically somewhat hurt and mentally in full vigour.
The foot soldier is physically at death's door and has a multi-colored swollen left hip.
The foot soldier is physically feeling very well.
The grim knight is physically in a very bad shape.
What I tried to do was creating a trigger that catches everthing in between but not including "is physically" and either "." or " and has", and then match the caputured string with an array to get the corresponding color I want. With no luck... And I thought it was going to be a walk in the park...
Anyone whou could assist in this task of mine? Mayhap point me in the right direction?
"May the Force be with you"
[url]peewee@mars11.net[/url]