builtins

3 views
Skip to first unread message

Nathan Smith

unread,
Sep 5, 2017, 2:16:28 PM9/5/17
to MOO Talk
hello folks!
I was just wondering if someone would be so kind as to give me a link to how to register new builtins.
I'd like to create, and or patch, a builtin into my server that allows me to list all of the builtins available in a server.
Any help would be appreciated in this matter.

Todd Sundsted

unread,
Sep 5, 2017, 5:05:20 PM9/5/17
to MOO Talk
if you mean built-in functions, you can call "function_info()".

Nathan Smith

unread,
Sep 6, 2017, 3:59:07 PM9/6/17
to MOO Talk

that's exactly what I was looking for!
thanks!
out of interest, is there a tutorial for patching patches by hand?
I'm using gamma, and so a lot of lambda patches fail to patch and I'd sort of like them.
I actually considered stunt, but my database won't load on it for a number of reasons.
a pain, really.

Michael Munson

unread,
Sep 10, 2017, 5:42:17 AM9/10/17
to Nathan Smith, MOO Talk
What does GammaMOO add that LambdaMOO doesn't? I dont notice any extra data types. 

--
You received this message because you are subscribed to the Google Groups "MOO Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to MOO-talk+unsubscribe@googlegroups.com.
To post to this group, send email to MOO-...@googlegroups.com.
Visit this group at https://groups.google.com/group/MOO-talk.
For more options, visit https://groups.google.com/d/optout.

Chris Norman

unread,
Sep 10, 2017, 10:18:59 AM9/10/17
to MOO-...@googlegroups.com



On 10/09/2017 10:42, Michael Munson wrote:
What does GammaMOO add that LambdaMOO doesn't? I dont notice any extra data types.

It's mainly the ability to use assignments like variable++ and variable-- I believe... I'm sure there was some other syntactic sugar but I can't remember what it was.

Cheers,

To unsubscribe from this group and stop receiving emails from it, send an email to MOO-talk+u...@googlegroups.com.

Nathan Smith

unread,
Sep 10, 2017, 3:24:18 PM9/10/17
to MOO Talk
themain thing for me in gamma is the ++n, thing. I've not found , or been able to patch, that into any other server. But the version of gamma I use comes ready equipped also with martians extentions, goblins stuff, file i/o, ETC. Even if I could fully patch a lambdamoo server with all the stuff I wanted, highly unlikely as apart from patch < the_patch.patch, I have no idea how to go about it, I doubt the database would convert back over.


On Sunday, September 10, 2017 at 10:42:17 AM UTC+1, Michael Munson wrote:
What does GammaMOO add that LambdaMOO doesn't? I dont notice any extra data types. 
On Wed, Sep 6, 2017 at 1:58 PM, Nathan Smith <lordva...@gmail.com> wrote:

that's exactly what I was looking for!
thanks!
out of interest, is there a tutorial for patching patches by hand?
I'm using gamma, and so a lot of lambda patches fail to patch and I'd sort of like them.
I actually considered stunt, but my database won't load on it for a number of reasons.
a pain, really.

On Tuesday, September 5, 2017 at 10:05:20 PM UTC+1, Todd Sundsted wrote:
if you mean built-in functions, you can call "function_info()".

On Tuesday, September 5, 2017 at 2:16:28 PM UTC-4, Nathan Smith wrote:
hello folks!
I was just wondering if someone would be so kind as to give me a link to how to register new builtins.
I'd like to create, and or patch, a builtin into my server that allows me to list all of the builtins available in a server.
Any help would be appreciated in this matter.

--
You received this message because you are subscribed to the Google Groups "MOO Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to MOO-talk+u...@googlegroups.com.

Michael Munson

unread,
Sep 12, 2017, 4:33:22 PM9/12/17
to Nathan Smith, MOO Talk
In that case, if you replace every n++ in the db with n = n +1 (can use sed: sed -i -E 's/([^\+\s])+\+\+;/\1 = \1 + 1;/g' moo.db) and then restart the MOO and dump it (to make sure there are no suspended tasks that use n++) then change the DB number to that of LambdaMOO stunt should convert it properly.

To unsubscribe from this group and stop receiving emails from it, send an email to MOO-talk+unsubscribe@googlegroups.com.

Brendan B

unread,
Nov 10, 2017, 4:41:44 PM11/10/17
to MOO Talk
It also incorporates some patches, like an updated FILE I/O patch. There are other improvements that aren't just syntatic sugar.



On Sunday, September 10, 2017 at 10:18:59 AM UTC-4, Chris Norman wrote:



On 10/09/2017 10:42, Michael Munson wrote:
What does GammaMOO add that LambdaMOO doesn't? I dont notice any extra data types.

It's mainly the ability to use assignments like variable++ and variable-- I believe... I'm sure there was some other syntactic sugar but I can't remember what it was.

Cheers,

On Wed, Sep 6, 2017 at 1:58 PM, Nathan Smith <lordva...@gmail.com> wrote:

that's exactly what I was looking for!
thanks!
out of interest, is there a tutorial for patching patches by hand?
I'm using gamma, and so a lot of lambda patches fail to patch and I'd sort of like them.
I actually considered stunt, but my database won't load on it for a number of reasons.
a pain, really.

On Tuesday, September 5, 2017 at 10:05:20 PM UTC+1, Todd Sundsted wrote:
if you mean built-in functions, you can call "function_info()".

On Tuesday, September 5, 2017 at 2:16:28 PM UTC-4, Nathan Smith wrote:
hello folks!
I was just wondering if someone would be so kind as to give me a link to how to register new builtins.
I'd like to create, and or patch, a builtin into my server that allows me to list all of the builtins available in a server.
Any help would be appreciated in this matter.
--
You received this message because you are subscribed to the Google Groups "MOO Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to MOO-talk+u...@googlegroups.com.
To post to this group, send email to MOO-...@googlegroups.com.
Visit this group at https://groups.google.com/group/MOO-talk.
For more options, visit https://groups.google.com/d/optout.

Luke Dashjr

unread,
Nov 11, 2017, 2:22:00 AM11/11/17
to MOO-...@googlegroups.com, Michael Munson, Nathan Smith
On Monday 04 September 2017 1:48:02 PM Nathan Smith wrote:
> I was just wondering if someone would be so kind as to give me a link to
> how to register new builtins.

The simplest way to add new "builtins" to GammaMOO is to define and implement
#0:bf__NEW_BUILTIN_NAME (note the double underscore after "bf").

On Wednesday 06 September 2017 7:58:37 PM Nathan Smith wrote:
> out of interest, is there a tutorial for patching patches by hand?
> I'm using gamma, and so a lot of lambda patches fail to patch and I'd sort
> of like them.

Typically: patch -p1 --merge=diff3 <PATCHFILE

Then look for "<<<<<<<" in the files and resolve the conflicts. You'll need to
know C for that...

Feel free to open a pull request on GitHub with your changes to get it
reviewed and/or merged into mainline GammaMOO:
https://github.com/luke-jr/gammamoo/pulls

On Sunday 10 September 2017 9:42:16 AM Michael Munson wrote:
> What does GammaMOO add that LambdaMOO doesn't? I dont notice any extra data
> types.

Most notable:

- Ability to define "builtins" in the MOO itself.
- Internal "network" connections (simulate an incoming connection within the
MOO).
- Binary handling and other webserver-helpful improvements. For example, I
have a webserver MOO object that uses this along with the internal network
connections to provide a web interface to the MOO.
- MOO code language improvements (+=, ++, bit operators).
- File I/O with a special append-only mode for logs (ie, so wizards can't
modify them).
- Access to the entire library of libgcrypt hash algorithms instead of just
the broken MD5.


Brendan B

unread,
Nov 13, 2017, 9:59:12 AM11/13/17
to MOO Talk
If you know other programming languages that are similar in syntax to C, you may be able to muddle through a patch. That's how I managed.
Reply all
Reply to author
Forward
0 new messages