Scripting Support, Programmable triggers anyone? |
Scripting Support, Programmable triggers anyone? |
May 2 2003, 01:01 PM
Post
#1
|
|
Administrator Group: Admin Posts: 168 Joined: 2-May 03 From: New Hampshire Member No.: 1 |
A common user feature request has been to adding the ability to program a trigger. You know, with if-then statements and for loops, etc.
If you had to choose a language, what would it be? Why? |
|
|
Guest_Shan_* |
May 10 2003, 01:38 AM
Post
#2
|
Guests |
Perl! The language was built for processing text.
|
|
|
May 10 2003, 04:22 AM
Post
#3
|
|
Newbie Group: Members Posts: 3 Joined: 9-May 03 Member No.: 9 |
I'd vote for C/C++, but only because that's the language with which I am most familiar. Really, almost anything that allows trigger and macro programming is great.
—Alorael, who would have to except a few languages. FORTRAN, for one, is a bit esoteric for casual client-users. A punchcard system might also prove less than popular. |
|
|
Guest_Guest_* |
Aug 5 2003, 05:58 PM
Post
#4
|
Guests |
Dangit, I JUST got done e-mailing Jay with this idea, and now I find out there's a topic devoted to it. Hehe, sorry 'bout that.
Being a guest, I can't vote, and I'm too lazy to register, but I think Javascript would be best. Many people are already familiar with it(me being one of them), and it's very easy to learn, easier than C++ or Perl. |
|
|
Aug 9 2003, 01:57 AM
Post
#5
|
|
Administrator Group: Admin Posts: 168 Joined: 2-May 03 From: New Hampshire Member No.: 1 |
I was reading macslash.com today and there is a discussion about Ruby 1.8, a scripting language. Reading thru the threads, here's a couple of choice comments people made:
QUOTE Ruby is cool (Score:0) by Anonymous Coward on Tuesday August 05, @01:31PM ( #45698 ) Ruby is pretty cool. It has a nice smalltalky approach which makes it quite agreeable if you love OOD - far nicer than Perl or Python. I still prefer Perl for scripting since CPAN has a lot more to offer than Ruby, and I generally am writing sysadmin scripts where OOD is not really needed or appropriate. Plus Perl is still a lot faster than Ruby or Python. But I am looking forward to seeing a wider availability of libs for Ruby's since when OOD/OOP is appropriate Ruby is a lot nicer to work with that the inconsistent mess that is Python, and Perl is even worse (though Perl 6 looks really promising). And someone else wrote: QUOTE Ruby is cool but I prefer F-Script (Score:0) by Anonymous Coward on Wednesday August 06, @09:11AM ( #45776 ) Ruby is quite nice and it is cool to see it included in OS X. However, I much prefer Smalltalk (in some way, it is sad to see that Ruby is not as good as a language designed 30 years ago), and as far as OS X scripting is concerned, I recommend looking at F-Script [fscript.org], which is natively based on the Cocoa/Objective-C object model. Any of you guys familar with Ruby and/or F-Script? /Jay |
|
|
Guest_cybern8r_* |
Aug 9 2003, 03:40 AM
Post
#6
|
Guests |
...Never heard of it. But any language for Savitar would be great, even one that's custom made for it. Unless it's like binary or something. That would be too confusing.
|
|
|
Guest_Shan_* |
Dec 31 2003, 04:11 PM
Post
#7
|
Guests |
I vote for Perl or Lua.
|
|
|
Guest_Vesence_* |
Feb 11 2004, 11:15 PM
Post
#8
|
Guests |
I dont know much about programming but I think I know what you all are talking about. I used to use another client and in the trigger editing window there were options for the trigger firing conditions. Such as:
If: <variable> Is: <greater than, less than, equal to> Then: <fire trigger, gag text, send text, etc> This was followed by the Reply Text window. I belive changeable menu tabs like this client had would be better than user programable triggers and such because like I said I have no idea how to program. |
|
|
Guest_Brennan Young_* |
Apr 4 2006, 12:36 PM
Post
#9
|
Guests |
PERL is an obvious choice, because of it's special strengths with text processing, but it's ugly.
Python and Applescript are both good choices too, although Applescript has quite poor string handling. HOWEVER, Applescript has a *very* neat thing called 'do shell script' which means that if you support Applescript, we can use whatever language we like - including C, just pass a string to whatever shell script, written in whatever language. Many Applescript folks just call grep, sed or PERL with 'do shell script' if they want to do any serious string crunching. Works very nicely. A basic scripting implemetation would need at least TWO input parameters: 1 String - the server output (trigger), or user input (macro) 2 A reference to the world where this is happening (name?, id?) The script should return true or false, indicating whether it handled the event or not. It should also be possible to send messages to the server, and/or write something into the input line ready to be sent. That's the bare minimum, but we can already do a lot with it. I would suggest looking at the scripting implementations of various irc clients, such as Snak, ircle, Xchat and so on. (Snak and Xchat both support more than one scripting language). Apart from tinyfugue, scripting MUDs on Mac is almost impossible. I'll buy Savitar in a trice if I could have this feature. |
|
|
Aug 18 2006, 08:51 PM
Post
#10
|
|
Newbie Group: Members Posts: 1 Joined: 18-August 06 Member No.: 143 |
I think most will vote for any language they already know.
I would look for a language and a) takes little time to implement on the coding side, and has a history of being simple to learn, and has good and available (online free) documentation. No matter what you choose, the majority will have to learn it. The language must be able to do arithmetic functions, and assign values to variables. Number and String variables are needed. I am eager to see this implemented in Savitar. I would put it high on the priority list of 'things to do'. Thanks |
|
|
Aug 18 2006, 10:20 PM
Post
#11
|
|
Newbie Group: Members Posts: 5 Joined: 29-April 06 Member No.: 97 |
I don't know it, but I've seen lots of positive comments for Ruby.
|
|
|
Oct 22 2006, 09:05 PM
Post
#12
|
|
Newbie Group: Members Posts: 2 Joined: 22-October 06 Member No.: 193 |
Since it's been over three years since this topic was first created, and more than two months since the last post.... is there any chance this'll be implemented? I'd really be interested to see it added.
|
|
|
Oct 23 2006, 02:28 PM
Post
#13
|
|
Administrator Group: Admin Posts: 168 Joined: 2-May 03 From: New Hampshire Member No.: 1 |
Its still something I want to add.
Do you have a preferred scripting language? (Been wanting more feedback from the user community.) |
|
|
Nov 1 2006, 06:13 PM
Post
#14
|
|
Newbie Group: Members Posts: 2 Joined: 22-October 06 Member No.: 193 |
I wouldn't mind PERL myself.
|
|
|
Dec 21 2006, 01:29 AM
Post
#15
|
|
Newbie Group: Members Posts: 1 Joined: 6-October 06 Member No.: 183 |
Personally I'd vote for javascript, like mentioned above most would probably vote for what they are most familiar, and I can't say my opinion is any different from that. But Javascript is fairly powerful language, is not that hard to learn (I've coded my own yahtzee game in it for fun, I'm still in the process of learning perl, I know its a powerful language but it takes some getting used to, for me anyhow) and it has plenty of references out there. Otherwise I'd say go with perl
[Quick Edit:] I think support for another language would be a very good thing for savitar. I've always loved rapscallion for its range of features that even today 8 years after it lost any development are still quite good, but I moved to Savitar when I moved to OS X and have enjoyed it since, though I have used other clients such as Mudwalker, GGmud or Atlantis for their other languages that I can write scripts for, either Lua which has a syntax somewhat similar to Javascript, or Perl respectively and would be a great thing for savitar to have as well. |
|
|
Lo-Fi Version | Time is now: 5th November 2024 - 03:52 PM |