|
jysmystry Beginner
Joined: 28 Nov 2012 Posts: 16
|
Posted: Mon Feb 04, 2013 6:25 pm
#tags help |
Hi,
Can anyone have a look at this and help me?
I am trying to set up tags.
This is a sample room desc
Quote: |
-= Room Name =-
This is the room description This is the room descriptionThis is the room description
This is the room descriptionThis is the room descriptionThis is the room description
This is the room descriptionThis is the room descriptionThis is the room description
This is the room descriptionThis is the room descriptionThis is the room description
MOBS/Items/Stuff goes here
Obvious exits are:
North : roomname
West : roomname
East : roomname
Aura:100/100 Health:154/154
|
I have the following trigger to catch the roomname which it seems to do fine stripping out the superfluous -= =-
Quote: |
<trigger name="-= (*) =- " priority="160" prompt="true" id="55">
<pattern>-= (*) =-</pattern>
<value>#tag name %1</value>
</trigger>
|
and i have all the usual #NOMAP and #NODIR which also seem fine.
My problem here is descriptions and exits as with this config i just get the roomname (which is fine) and then either the last line of the room desc or the first 2 exits. I dont know how to take this further, any ideas or suggestions?[/quote] |
|
|
|
jysmystry Beginner
Joined: 28 Nov 2012 Posts: 16
|
Posted: Mon Feb 04, 2013 11:18 pm |
reading back this sounds confusing but really what im saying is now that I have the room name working fine how do i add the room description?
|
|
|
|
MattLofton GURU
Joined: 23 Dec 2000 Posts: 4834 Location: USA
|
Posted: Mon Feb 04, 2013 11:40 pm |
Use a multistate trigger. In the Package Editor, you would create a new trigger for whatever was going to be your first state (in this case, you want to use your room name trigger). For everything else, you would select New Trigger State. Trigger State objects cannot be standalone, and CMud will automatically handle the enabling/disabling of each one as appropriate to the state type, but other than that they function identically as triggers.
|
|
_________________ EDIT: I didn't like my old signature |
|
|
|
jysmystry Beginner
Joined: 28 Nov 2012 Posts: 16
|
Posted: Tue Feb 05, 2013 2:40 pm |
Oh i was hoping there would be a simple way to capture everything from the roomname trigger down to the newline before the exit as the room desc :(
So i would need to have a series of triggers that matched on patterns of any letter or digit and assign each a variable and concantate those together just to capture the rooms desc? |
|
|
|
Rahab Wizard
Joined: 22 Mar 2007 Posts: 2320
|
Posted: Thu Feb 07, 2013 4:16 pm |
Not a series of triggers. A multi-state trigger. Check out the #COND command. And you should be able to concatenate directly onto the variable you are building for the room desc.
|
|
|
|
|
|