• Javascript Door

    From Rassilon@CITADEL to All on Thu Mar 25 23:37:00 2010
    I was just trying to add a javascript door & I seem to have run into a snag.
    I can't get the javascript to run. Synchronet just pauses for a second & returns to the prompt.

    Is it even possible to write a door in javascript or do I need to use baja or C++ or something?

    -Rassilon...


    ---
    ■ Synchronet ■ The Citadel BBS - citadel.synchro.net
  • From Digital Man to Rassilon on Fri Mar 26 00:54:46 2010
    Re: Javascript Door
    By: Rassilon to All on Thu Mar 25 2010 11:37 pm

    I was just trying to add a javascript door & I seem to have run into a
    snag. I can't get the javascript to run. Synchronet just pauses for a second & returns to the prompt.

    Please paste your configuration from SCFG here.

    Is it even possible to write a door in javascript or do I need to use baja or C++ or something?

    Yes, JavaScript modules can be executed as doors (e.g. xtrn/tw2/tw2.js). See http://wiki.synchro.net/howto:door:index#modules for details.

    digital man

    Snapple "Real Fact" #27:
    A ball of glass will bounce higher then a ball of rubber.
  • From Lord Time@TIME to Rassilon on Thu Mar 25 23:37:00 2010
    In a reply from Rassilon on 23:37 about Javascript Door

    I was just trying to add a javascript door & I seem to have run into a snag. I can't get the javascript to run. Synchronet just pauses for a second & returns to the prompt.

    what one?

    Is it even possible to write a door in javascript or do I need to use baja or C++ or something?

    this I can't answer

    ---
    Rob Starr
    Lord Time SysOp of Time Warp of the Future BBS
    telnet://time.synchro.net:24
    ICQ # 11868133 Yahoo : lordtime2000
    AIM : LordTime20000 MSN : Lord Time
    Jabber : lordtime2000@gmail.com Astra : lord_time


    ■ CMPQwk 1.42-R2 16554 ■ I [*] My dog. He [ate] My Cat.
    ---
    ■ Synchronet ■ Time Warp of the Future BBS - Home of League 10 IBBS Games
  • From John Guillory@MAINLINE to Rassilon on Fri Mar 26 06:42:00 2010
    Re: Javascript Door
    By: Rassilon to All on Thu Mar 25 2010 11:37 pm

    Is it even possible to write a door in javascript or do I need to use baja o C++ or something?
    Yeah, there's three or four allready written.... In a way, one would assume
    Javascript is the easiest to write a door in, since it automatically has
    support for writing to the serial port and console at the same time...


    ---
    ■ Synchronet ■ Roach Guts - roachguts.com
  • From Nightfox@DIGDIST to Rassilon on Fri Mar 26 07:30:56 2010
    Re: Javascript Door
    By: Rassilon to All on Thu Mar 25 2010 23:37:00

    I was just trying to add a javascript door & I seem to have run into a snag. I can't get the javascript to run. Synchronet just pauses for a second & returns to the prompt.

    To execute a JavaScript door, you need to start the command line with a ?. For example, for Deuce's FS editor:
    ?fseditor.js %f

    Is it even possible to write a door in javascript or do I need to use baja o C++ or something?

    Yes, doors can be written in JavaScript, although they tend to be Synchronet-specific doors. Synchronet comes with at least one Synchronet door (tw2), and things like Deuce's FS editor and SlyEdit are written in JavaScript.

    Nightfox

    ---
    ■ Synchronet ■ Digital Distortion BBS: digdist.bbsindex.com
  • From Corey@TSGC to Nightfox on Fri Mar 26 07:59:52 2010
    Re: Javascript Door
    By: Nightfox to Rassilon on Fri Mar 26 2010 07:30 am

    Re: Javascript Door
    By: Rassilon to All on Thu Mar 25 2010 23:37:00

    I was just trying to add a javascript door & I seem to have run into a sn I can't get the javascript to run. Synchronet just pauses for a second & returns to the prompt.

    To execute a JavaScript door, you need to start the command line with a ?. example, for Deuce's FS editor:
    ?fseditor.js %f

    Is it even possible to write a door in javascript or do I need to use baj C++ or something?

    Yes, doors can be written in JavaScript, although they tend to be Synchronet-specific doors. Synchronet comes with at least one Synchronet do (tw2), and things like Deuce's FS editor and SlyEdit are written in JavaScri

    Nightfox


    so how would you run a door from the js menu like classic_shell.js?

    Caput meum major podice meo.
    This message has ended, go in peace...

    ---
    ■ Synchronet ■ Three Stooges Gentlemens Club - Las Vegas, Nv
  • From Digital Man to Corey on Fri Mar 26 10:22:01 2010
    Re: Javascript Door
    By: Corey to Nightfox on Fri Mar 26 2010 07:59 am

    Re: Javascript Door
    By: Nightfox to Rassilon on Fri Mar 26 2010 07:30 am

    Re: Javascript Door
    By: Rassilon to All on Thu Mar 25 2010 23:37:00

    I was just trying to add a javascript door & I seem to have run into
    a sn I can't get the javascript to run. Synchronet just pauses for a second & returns to the prompt.

    To execute a JavaScript door, you need to start the command line with a ?. example, for Deuce's FS editor:
    ?fseditor.js %f

    Is it even possible to write a door in javascript or do I need to use baj C++ or something?

    Yes, doors can be written in JavaScript, although they tend to be Synchronet-specific doors. Synchronet comes with at least one
    Synchronet do (tw2), and things like Deuce's FS editor and SlyEdit are written in JavaScri
    Nightfox


    so how would you run a door from the js menu like classic_shell.js?

    bbs.exec_xtrn("code") is the most correct way to run any "door" from a shell, regardless of what language the door is written in. Alternatively, you could use load() or bbs.exec(), but I dont' recommend it.

    digital man

    Snapple "Real Fact" #71:
    There is a town called "Big Ugly" in West Virginia.
  • From Corey@TSGC to Digital Man on Fri Mar 26 14:49:22 2010
    Re: Javascript Door
    By: Digital Man to Corey on Fri Mar 26 2010 10:22 am

    Re: Javascript Door
    By: Corey to Nightfox on Fri Mar 26 2010 07:59 am

    Re: Javascript Door
    By: Nightfox to Rassilon on Fri Mar 26 2010 07:30 am

    Re: Javascript Door
    By: Rassilon to All on Thu Mar 25 2010 23:37:00

    I was just trying to add a javascript door & I seem to have run int a sn I can't get the javascript to run. Synchronet just pauses for second & returns to the prompt.

    To execute a JavaScript door, you need to start the command line with ?. example, for Deuce's FS editor:
    ?fseditor.js %f

    Is it even possible to write a door in javascript or do I need to u baj C++ or something?

    Yes, doors can be written in JavaScript, although they tend to be Synchronet-specific doors. Synchronet comes with at least one Synchronet do (tw2), and things like Deuce's FS editor and SlyEdit are written in JavaScri
    Nightfox


    so how would you run a door from the js menu like classic_shell.js?

    bbs.exec_xtrn("code") is the most correct way to run any "door" from a shell regardless of what language the door is written in. Alternatively, you could use load() or bbs.exec(), but I dont' recommend it.

    digital man

    Snapple "Real Fact" #71:
    There is a town called "Big Ugly" in West Virginia.


    ah, ok great. I config it properly in scfg and just call it by the name I gave it? sounds easy. thanks as always.


    Caput meum major podice meo.
    This message has ended, go in peace...

    ---
    ■ Synchronet ■ Three Stooges Gentlemens Club - Las Vegas, Nv
  • From Corey@TSGC to Digital Man on Fri Mar 26 15:04:25 2010
    Re: Javascript Door
    By: Digital Man to Corey on Fri Mar 26 2010 10:22 am

    Re: Javascript Door
    By: Corey to Nightfox on Fri Mar 26 2010 07:59 am

    Re: Javascript Door
    By: Nightfox to Rassilon on Fri Mar 26 2010 07:30 am

    Re: Javascript Door
    By: Rassilon to All on Thu Mar 25 2010 23:37:00

    I was just trying to add a javascript door & I seem to have run int a sn I can't get the javascript to run. Synchronet just pauses for second & returns to the prompt.

    To execute a JavaScript door, you need to start the command line with ?. example, for Deuce's FS editor:
    ?fseditor.js %f

    Is it even possible to write a door in javascript or do I need to u baj C++ or something?

    Yes, doors can be written in JavaScript, although they tend to be Synchronet-specific doors. Synchronet comes with at least one Synchronet do (tw2), and things like Deuce's FS editor and SlyEdit are written in JavaScri
    Nightfox


    so how would you run a door from the js menu like classic_shell.js?

    bbs.exec_xtrn("code") is the most correct way to run any "door" from a shell regardless of what language the door is written in. Alternatively, you could use load() or bbs.exec(), but I dont' recommend it.

    digital man

    Snapple "Real Fact" #71:
    There is a town called "Big Ugly" in West Virginia.


    works great, thanks. no I can learn javascript and build custom menus sections. here is the first code of my door menu.

    //############################ Doors Menu ###############################

    function doors()
    {
    var key;

    while(1) {
    if(!(user.settings & USER_EXPERT))
    bbs.menu("doors");

    console.print("\r\nGame Menu: ");
    key=get_next_keys("?XA\r");
    bbs.log_key(key);
    switch(key) {

    case '?':
    if(user.settings & USER_EXPERT)
    bbs.menu("doors");
    break;

    case 'A':
    bbs.exec_xtrn("amb4")
    break;

    case 'X':
    default:
    return;
    }
    }
    }

    I had done one in baja and now figured to make a js one.
    synchronet has changed a lot over the years, but the extern system stayed the same. thanks again.

    Caput meum major podice meo.
    This message has ended, go in peace...

    ---
    ■ Synchronet ■ Three Stooges Gentlemens Club - Las Vegas, Nv
  • From Rassilon@CITADEL to Digital Man on Fri Mar 26 18:22:00 2010
    Re: Javascript Door
    By: Digital Man to Rassilon on Fri Mar 26 2010 12:54 am

    Internal Code: TEST
    Start-up Directory: (It's in the exec. directory for now - so no value) Command Line: test.js
    Clean-up Command Line:
    Execution Cost: None
    Access Requirements: LEVEL 90|lEVEL 90 LEVEL 90
    Execution Requirements:
    Multiple Concurrent Users: No
    Intercept Standard I/O: No
    Native (32-bit) Executable: No
    Use Shell to Execute: No
    Modify User Data: No
    Execute on Event: No
    BBS Drop File Type: None
    Place Drop File In: Node Directory
    Time Options...
    BBS Drop File Type: None

    ??

    -Rassilon...

    ---
    ■ Synchronet ■ The Citadel BBS - citadel.synchro.net
  • From Rassilon@CITADEL to Lord Time on Fri Mar 26 18:34:00 2010
    Re: Javascript Door
    By: Lord Time to Rassilon on Thu Mar 25 2010 11:37 pm

    I was just trying to add a javascript door & I seem to have run into a sn I can't get the javascript to run. Synchronet just pauses for a second & returns to the prompt.

    what one?

    I was planning to write one.

    -Rassilon...

    ---
    ■ Synchronet ■ The Citadel BBS - citadel.synchro.net
  • From Rassilon@CITADEL to Nightfox on Fri Mar 26 18:37:00 2010
    Re: Javascript Door
    By: Nightfox to Rassilon on Fri Mar 26 2010 07:30 am

    To execute a JavaScript door, you need to start the command line with a ?. example, for Deuce's FS editor:
    ?fseditor.js %f

    Yeah, I tried that. Must be something else I'm doing wrong.

    -Rassilon...

    ---
    ■ Synchronet ■ The Citadel BBS - citadel.synchro.net
  • From Lord Time@TIME to Rassilon on Fri Mar 26 21:52:00 2010
    In a reply from Rassilon on 18:34 about Javascript Door

    I was just trying to add a javascript door & I seem to have run into a I sn can't get the javascript to run. Synchronet just pauses for a second & returns to the prompt.

    what one?

    I was planning to write one.

    ohh ok

    ---
    Rob Starr
    Lord Time SysOp of Time Warp of the Future BBS
    telnet://time.synchro.net:24
    ICQ # 11868133 Yahoo : lordtime2000
    AIM : LordTime20000 MSN : Lord Time
    Jabber : lordtime2000@gmail.com Astra : lord_time


    ■ CMPQwk 1.42-R2 16554 ■ Never, ever, french-kiss a dragon!
    ---
    ■ Synchronet ■ Time Warp of the Future BBS - Home of League 10 IBBS Games
  • From Digital Man to Rassilon on Mon Mar 29 00:11:57 2010
    Re: Javascript Door
    By: Rassilon to Digital Man on Fri Mar 26 2010 06:22 pm

    Re: Javascript Door
    By: Digital Man to Rassilon on Fri Mar 26 2010 12:54 am

    Internal Code: TEST
    Start-up Directory: (It's in the exec. directory for now - so no value) Command Line: test.js

    Change that to "?test.js" (without the quotes). See http://wiki.synchro.net/howto:door:index#command_line for details.

    digital man

    Snapple "Real Fact" #170:
    In 1878, the first telephone book ever issued contained only 50 names.