A couple of slash commands

Moderators: dorpond, trevor, Azhrei, giliath, jay, Mr.Ice

User avatar
palmer
Great Wyrm
Posts: 1367
Joined: Sat Sep 06, 2008 7:54 pm

A couple of slash commands

Post by palmer »

Real simple request here...

OK, we have /me. This produces

* Phaien swings his staff to block the attack

But what about possessives?

REQUEST: /mes
OUTPUT: * Phaien's staff blocks the attack

= = = =

/clr clears the chat pane. This is nice now and then. However, my old DOS days have stuck with me, and I find myself regularly typing /cls

REQUEST: /cls
EFFECT: Same as /clr

User avatar
Rumble
Deity
Posts: 6235
Joined: Tue Jul 01, 2008 7:48 pm

Re: A couple of slash commands

Post by Rumble »

For the first, you could just type:

"/me 's staff blocks the attack."

It's not perfect, though - notably, it puts a space in between the name and the "'s."

As for the second, make an alias:

/alias cls /clr

Then, if you type /cls, it runs the /clr command.

User avatar
palmer
Great Wyrm
Posts: 1367
Joined: Sat Sep 06, 2008 7:54 pm

Re: A couple of slash commands

Post by palmer »

I'm aware of that.

However, A looks bad and B has the hassle of needing to redefine the alias every single time I start MT. Not practical, especially when the purpose is because I am not thinking, but typing reflexively.

User avatar
Brigand
Read-only User
Posts: 1623
Joined: Thu Feb 14, 2008 8:57 am
Location: Nosy GM's can go frak themselves!

Re: A couple of slash commands

Post by Brigand »

So create a macro to recreate your aliases.

User avatar
Rumble
Deity
Posts: 6235
Joined: Tue Jul 01, 2008 7:48 pm

Re: A couple of slash commands

Post by Rumble »

Or have it load an alias file.

I'm with you on the first one, but I think the second one should be handled via alias. However, perhaps the best permanent update (if such thing should be) is to make one of the built-in aliases for /clear be /cls. I don't see any reason to create a new basic command.

I don't see a problem with doing that (although, generally, my response would be "well, stop typing /cls"). :)

User avatar
jfrazierjr
Deity
Posts: 5176
Joined: Tue Sep 11, 2007 7:31 pm

Re: A couple of slash commands

Post by jfrazierjr »

The first one is easy to fix with a new slash command. The second one is in principle, but I would have a lot of hesitancy about this. For one, clearing means no saving data, it's gone (which may be what you want). Second, are you expecting it to clear just for you or for all users connected to the server(in which case, it should probably be a GM only function)?

Back to the first one again. What should the defined behavior be? ie, should it just collapse the space or should it include the "'s" part followed by a space and then the message?
I save all my Campaign Files to DropBox. Not only can I access a campaign file from pretty much any OS that will run Maptool(Win,OSX, linux), but each file is versioned, so if something goes crazy wild, I can always roll back to a previous version of the same file.

Get your Dropbox 2GB via my referral link, and as a bonus, I get an extra 250 MB of space. Even if you don't don't use my link, I still enthusiastically recommend Dropbox..

User avatar
palmer
Great Wyrm
Posts: 1367
Joined: Sat Sep 06, 2008 7:54 pm

Re: A couple of slash commands

Post by palmer »

I don't see what the big deal about clearing is? The idea behind /cls is simply an alias for the existing /clear. This isn't adding new functionality or anything.

And /mes would go

Code: Select all

*[Name]'s %1
Really simple stuff.

User avatar
Mrugnak
Dragon
Posts: 745
Joined: Mon Jul 21, 2008 7:38 pm

Re: A couple of slash commands

Post by Mrugnak »

However /mes would be added, I'd try to make sure it's consistant with /me, so when someone starts monkeying with chat channels, mes and me go to the same place.

User avatar
Rumble
Deity
Posts: 6235
Joined: Tue Jul 01, 2008 7:48 pm

Re: A couple of slash commands

Post by Rumble »

Yes, that was what I was getting at: adding a second built-in alias for /clear as well. I mean, the ability exists to redefine it that way right now anyway. Palmer just didn't want to have to set the alias when MapTool starts.

All I was saying is that I don't think there needed to be a top-level command called "/cls" when it could be an alias of /clear.

User avatar
jfrazierjr
Deity
Posts: 5176
Joined: Tue Sep 11, 2007 7:31 pm

Re: A couple of slash commands

Post by jfrazierjr »

Patch send to Trevor. For the cls, that was easy as it appears Trevor already has in place a method for handling multiple alias for a slash command(YEAH Trevor!). Added a new class for /emotes with an alias of /mes.
I save all my Campaign Files to DropBox. Not only can I access a campaign file from pretty much any OS that will run Maptool(Win,OSX, linux), but each file is versioned, so if something goes crazy wild, I can always roll back to a previous version of the same file.

Get your Dropbox 2GB via my referral link, and as a bonus, I get an extra 250 MB of space. Even if you don't don't use my link, I still enthusiastically recommend Dropbox..

User avatar
Full Bleed
Demigod
Posts: 4736
Joined: Sun Feb 25, 2007 11:53 am
Location: FL

Re: A couple of slash commands

Post by Full Bleed »

palmer wrote:I don't see what the big deal about clearing is? The idea behind /cls is simply an alias for the existing /clear. This isn't adding new functionality or anything.

And /mes would go

Code: Select all

*[Name]'s %1
Really simple stuff.
However, when a character's name end in "s" it does look funny.

Name: Bones

Would yield:
"Bones's staff blocks the attack."

Ugh.

Anyway to put in an exception for names that end in "s" to just use the apostrophe so we get:
"Bones' staff blocks the attack."
Maptool is the Millennium Falcon of VTT's -- "She may not look like much, but she's got it where it counts."

User avatar
jfrazierjr
Deity
Posts: 5176
Joined: Tue Sep 11, 2007 7:31 pm

Re: A couple of slash commands

Post by jfrazierjr »

Full Bleed wrote:
palmer wrote:I don't see what the big deal about clearing is? The idea behind /cls is simply an alias for the existing /clear. This isn't adding new functionality or anything.

And /mes would go

Code: Select all

*[Name]'s %1
Really simple stuff.
However, when a character's name end in "s" it does look funny.

Name: Bones

Would yield:
"Bones's staff blocks the attack."

Ugh.

Anyway to put in an exception for names that end in "s" to just use the apostrophe so we get:
"Bones' staff blocks the attack."
Dang nabbit! How come yall have to go and put grammar into it?

In any event, I am not an expert in grammar for English, much less any other languages, but I seem to think that this model would break for some other languages also. This makes it hard to know the exceptions unless I know all the exceptions ahead of time based on locale... ie, this is an easy fix if we want to fix it for English only, but ma be much harder for other languages (or not, I just don't know)
I save all my Campaign Files to DropBox. Not only can I access a campaign file from pretty much any OS that will run Maptool(Win,OSX, linux), but each file is versioned, so if something goes crazy wild, I can always roll back to a previous version of the same file.

Get your Dropbox 2GB via my referral link, and as a bonus, I get an extra 250 MB of space. Even if you don't don't use my link, I still enthusiastically recommend Dropbox..

User avatar
Azhrei
Site Admin
Posts: 12086
Joined: Mon Jun 12, 2006 1:20 pm
Location: Tampa, FL

Re: A couple of slash commands

Post by Azhrei »

As time goes on, I am slowly replacing all hard-coded strings in the program with references to an external file that can have translation applied to it. Such external files would be given the name of the token and told to make it possessive.

However, they won't have the benefit of being able to actually execute code. So looking at the name to see if it ends with an "s" (for English) will always require code (AFAICT). Not sure what the right solution is here.

User avatar
Full Bleed
Demigod
Posts: 4736
Joined: Sun Feb 25, 2007 11:53 am
Location: FL

Re: A couple of slash commands

Post by Full Bleed »

jfrazierjr wrote:Dang nabbit! How come yall have to go and put grammar into it?
Actually, according to a site I just read it's ok to use "Bones's" and you only have to worry about the apostrophe-only rule if the you're using a plural noun.

Guess I've been doing that wrong most of my life because it looks stupid the "right" way. ;)

(Frankly, I'll probably continue to do it the "wrong" way, regardless. We do, after all, have every right to change language to suit new standards of acceptable use.)
Maptool is the Millennium Falcon of VTT's -- "She may not look like much, but she's got it where it counts."

User avatar
Azhrei
Site Admin
Posts: 12086
Joined: Mon Jun 12, 2006 1:20 pm
Location: Tampa, FL

Re: A couple of slash commands

Post by Azhrei »

And wouldn't "Bones" become "Boneses" in that case? Such as "keeping up with the Boneses"?

Post Reply

Return to “Resolved”