ThreadBoard ArchivesSite FeaturesActiveworlds SupportHistoric Archives |
How can I create Object in my world? (Sdk)
How can I create Object in my world? // SdkbluemeJan 25, 1999, 7:36am
I want to create object in my world with SDK.
But I can't create object dynamically. And how can I located Bot in my universe server? I don't know weather The first argument of aw_create() was mean's URL address or others. Please,help me!! edward sumerfieldJan 25, 1999, 11:20am
<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html> I can answer your second question. The first two arguments of aw_create are the URL and port of the universe server but if you just pass NULL then it will assume the AW universe server. <p>So you will do <p> int instance; <br> aw_create(0, 0, &instance); <br> aw_login(); <p>To do object creation that is all you will need. If you want an avatar in the world then continue. <p> aw_int_set(AW_AVATAR_X, 0); <br> aw_int_set(AW_AVATAR_Y, 0); <br> aw_int_set(AW_AVATAR_Z, 0); <br> aw_state_change(); <p>Check out sample program 2 on the web site. It searches for and changes a speaker object. See if that makes sense for you. [View Quote] bluemeJan 25, 1999, 10:53pm
Thanks.
But, I don't know still first argument of aw_create(). It's long value. But if I enter "my.activeworlds.com" with string, how can I convert with long value. And How can I know my port number that connect my universe server. I don't know... edward sumerfieldJan 26, 1999, 2:23am
The prototype for aw_create is as follows.
int aw_create (const char* domain, int port, void** instance); This is copied out of the aw.h header file from version 10 of the sdk. When you say the first argument is a long, I will agree that it takes up four bytes on the intel platform just like the char *. If you want to access the AW universe and insist on specifying the arguments then void *instance; aw_create("auth.activeworlds.com", 5670, &instance); but aw_create(0, 0, 0); does the same thing and is adequate if you only want one bot in you program. You can find this information out using the DOS/windows command netstat -an. It will show the active connections on your machine. So run active worlds browser and do a netstat and you will see it there. May the create force be with you. [View Quote] > Thanks. > But, I don't know still first argument of aw_create(). > It's long value. But if I enter "my.activeworlds.com" with string, > how can I convert with long value. > And How can I know my port number that connect my universe server. > > I don't know... ima geniusJan 26, 1999, 6:31pm
Also, keep in mind that the 2.1 uniservers haven't been released yet so it won't
work anyway. - Ima [View Quote] > The prototype for aw_create is as follows. > > int aw_create (const char* domain, int port, void** instance); > > This is copied out of the aw.h header file from version 10 of the sdk. > > When you say the first argument is a long, I will agree that it takes up four > bytes on the intel platform just like the char *. > > If you want to access the AW universe and insist on specifying the arguments > then > > void *instance; > aw_create("auth.activeworlds.com", 5670, &instance); > > but > > aw_create(0, 0, 0); > > does the same thing and is adequate if you only want one bot in you program. > > You can find this information out using the DOS/windows command netstat -an. > It will show the active connections on your machine. So run active worlds > browser and do a netstat and you will see it there. > > May the create force be with you. > [View Quote] edward sumerfieldJan 26, 1999, 7:42pm
<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html> You mean that it will not work with any other universe other than the AW universe which is already a 2.1 server. [View Quote] ima geniusJan 26, 1999, 8:50pm
Yep. He said in his original post "And how can I located Bot in my
universe server?". - Ima [View Quote] > You mean that it will not work with any other universe other than the > AW universe which is already a 2.1 server. > [View Quote] edward sumerfieldJan 27, 1999, 3:26pm
<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html> Ahhh, the subtleties of deduction from a fine mind. My hat's off to you Ima. I hadn't noticed that. [View Quote] |