MOO-cows Mailing List Archive
[Prev][Next][Index][Thread]
register_function line
-
Date: Tue, 28 May 1996 19:23:56 PDT
-
From: Diana L Harris <dlh5226@erc.jscc.cc.tn.us>
-
Content-Type: TEXT/PLAIN; charset=US-ASCII
Okay, I'm adding a built-in to a MOO called 'distance'. A sample call to
distance would be: ;distance({1.0,2.0,3.0},{4.0,5.0,6.0}) => some float
To add this, what line(s) would I put before the first opening bracket ({)
of the code?
I have:
float bf_distance(float stop[3], float start[3])
{
[... the code ...]
}
Also, what would the register_function(???) be? I tried:
register_function("distance",2,2,bf_distance,TYPE_LIST,TYPE_LIST);
but when I compiled I got something like arg 4 being passed to
register_function is incompatible (Note: It did compile anyway.)
The way I had it orginally it compiled, but when I called it it paniced the
server, and had 'Caught Signal 11' in the log.
Thanks in advance for your help.
Follow-Ups:
Home |
Subject Index |
Thread Index