Tempus Realms

Top | News | Realm | Classes | Clans | Mud Stories | Real Life | World | Newbies

Chat Window - Status Window
Aconite Posted 12 Sep 2010

Hey guys,

A few people have asked about how to make a chat window and a status window in Cmud/Zmud.

I'm going to list some triggers and syntax. If you don't know what to do with these, talk to me online, and we can figure it out.

For everyone else, this is how the format should be:

Pattern: Code:


CHAT WINDOW So, how do you make a chat window you ask? Well, by doing something like this:

Pattern: ^(%) tell{s you| (%)|s the group| the group}, '(%*)'$ Code: #Capture Public

This will create a window called "Public" and will capture anything someone tells you, or tells the group.

Now, if you follow this syntax, you can basically create a trigger for any type of social out there.

For example:

Pattern: ^(%) project(%), '(%*)'$ Code: #Capture Public

This will catch any project that is done.

So you can take this and basically replace project, or any other social and it will capture the text within the capture window.


STATUS WINDOW

The status window is a bit more tricky.

It involves the creation of not only triggers, but variables as well. You need to setup your variables in your status window for this to work also.

Basically it involves you have two triggers: 1) Trigger that happens when a spell is worn off, and 2) When a spell is casted.

You need to capture the text for both.

For example, the spell "armor". Two triggers are as follows:

1)

Pattern: ^You feel someone protecting you. Code: #va Armor %ansi( blue)"ON"%ansi( reset)

2) Pattern: ^You feel less protected. Code: tanker #va Armor %ansi( red)"OFF"%ansi( reset)

(In this example, tanker is my alias for casting the spell 'armor')

As you see, the variable is called "Armor". You must create this variable inside zmud/cmud for this tow ork. That way when this trigger goes off, you update the status of your spell. When the spell is casted, it updates as well.

Once you have these triggers/variables setup, you need to edit your status window. I'm having trouble finding the setting off the top of my head for cmud. They changed alot of the settings in the new version. I've done it, just need to find it again. If anyone has details let me know and I'll update it.

Once you get to the window status bar settings, you should do the format like this:

Your Armor Spell is @Armor

On your status window this will display: "Your Armor spell is (ON/OFF)"

It will display on or off depending on the status of the spell. Just continue to do this for all your triggers/variables.

If you have one for nopain, and your nopain variable is NoPain, you would just do: Your armor spell is @NoPain

Tada!

You now have an awesome public chat window, and a status window. You'll never miss another tell or spell status again!

–Aconite

Aconite Posted 12 Sep 2010

A example of what I have:

http://imgur.com/l4zGF.png

–Aconite

Deneb Posted 17 Sep 2010

Thanks. Nice set up. By the way, what're the " $ " at the end of your patterns for the chat window triggers?

Aconite Posted 19 Sep 2010

^ and $ Are anchors for the triggers.

So if someone tells you, "You feel less protected.", it will hit your armor spell and you'll cast it.

You can see how this can be abusive and annoying. So to save yourself from that, you can use ^(at the beginning) and $ (at the end of the trigger), so that it will only execute on a new line. That way no one can put anything before, ie "Piro tells you, 'You feel less protected.' and you won't cast the spell.

Merriam Posted 8 Apr 2011

I updated this for implants.

#TRIGGER {Hydraulic boosters auto switching off: depleted of energy.} {#VAR BoosterStat %ansi( bold, red)"OFF"%ansi( reset)} #TRIGGER {The energy levels of hydraulic boosters are too low.} {#VAR BoosterStat %ansi( bold, red)"OFF"%ansi( reset)} #TRIGGER {The energy levels of a heart of ice are too low.} {#VAR HeartOfIceStat %ansi( bold, red)"OFF"%ansi( reset)} #TRIGGER {Hydraulic boosters is already switched off.} {#VAR BoosterStat %ansi( bold, red)"OFF"%ansi( reset)} #TRIGGER {You deactivate hydraulic boosters (internal).} {#VAR BoosterStat %ansi( bold, red)"OFF"%ansi( reset)} #TRIGGER {Hydraulic boosters is already switched on.} {#VAR BoosterStat %ansi( bold, green)"ON"%ansi( reset)}

Search and replace 'hydraulic boosters' with your implant name, e.g. 'a telescopic eye' Search and replace BoosterStat with a variable name to describe it, e.g. EyeStat

Add the following text to a Status Window: Telescopic: @EyeStat

Merriam Posted 8 Apr 2011

I wish you could edit, but basically you can copy that block of #TRIGGER text after you modify it in notepad using the Find and Replace I mentioned. This creates the triggers automatically. File them in a Class (a.k.a. Folder) as you wish.


Realm-z is Copyright © 2003-2024. All rights reserved.
Tempus player name: Account Password:


Graphics by GIMP! Powered by Linux! Vote at topmudsites.com
All text and images Copyright © 1995-2024 by TempusMUD / All rights reserved