• Login Prompt

    From Mindless Automaton@ELDRITCH to DOVE-Net.Programming_(Javascript) on Tuesday, December 29, 2009 12:53:54
    For the login prompt, I wanted to display an ansi file in the background
    and then overlay the prompt text (Enter User Name..) on top.
    (Print ansi file, console.up & right to move cursor to print prompt)

    I can do this but when I just hit enter at the prompt, only the prompt
    text gets printed again, the ansi does not.
    <code>
    // Display login prompt
    console.down(10);
    console.printfile(system.text_dir+"login.ans",P_NONE);
    console.up(7);
    console.right(17);
    console.print("\1n\1h\1cEnter \1wUser Name");
    if(!(bbs.node_settings&NM_NO_NUM))
    console.print("\1c or \1wNumber");
    if(!(system.settings&SYS_CLOSED))
    console.print("\1c or '\1yNew\1c'");
    if(guest)
    console.print("\1c or '\1yGuest\1c'");
    console.down(1);
    console.left(45);
    console.print("NN:\b\b\bLogin: \1w");
    </code>

    Any ideas or any samples in the other js files on doing something like
    this?

    Thanks!

    Mindless Automaton
    ---
    ■ Synchronet ■ Eldritch Clockwork BBS - eldritch.darktech.org
  • From Mindless Automaton@ELDRITCH to Mindless Automaton on Tuesday, December 29, 2009 13:00:11
    Mindless Automaton wrote:


    Any ideas or any samples in the other js files on doing something like
    this?

    Thanks!

    Mindless Automaton

    Naturally I figured it out 5 seconds after posting. I sprinkled in a
    few console.home() before the ansi & each prompt and it works now.

    Let me know if there is a better way or tweak for this anyone can
    think of though..


    Thanks!

    Mindless Automaton
    ---
    ■ Synchronet ■ Eldritch Clockwork BBS - eldritch.darktech.org
  • From mrproper@WARZONE to Mindless Automaton on Tuesday, December 29, 2009 21:14:47
    Re: Login Prompt
    By: Mindless Automaton to DOVE-Net.Programming_(Javascript) on Tue Dec 29 2009 12:53 pm

    Any ideas or any samples in the other js files on doing something like
    this?

    I used to do that just with animated ansis being printed by the NN and PW prompts, with movement storage ending at where you want the typing to begin, you can even make them fade in with checkerboard etc.. if you slow the framerate down.

    did'nt really have to mess with much JS.. or any at all cause at the time the login and logon routines were baja.


    --

    Tim Smith (Mrproper)
    WarZone BBS: warzone.synchro.net
    BBSsearch : http://search.synchro.net

    ---
    ■ Synchronet ■ Warzone - warzone.synchro.net - Chatsworth GA, USA
  • From art@FATCATS to Mindless Automaton on Thursday, January 07, 2010 15:54:16
    Re: Re: Login Prompt
    By: Mindless Automaton to Mindless Automaton on Tue Dec 29 2009 13:00:11

    Let me know if there is a better way or tweak for this anyone can
    think of though..

    Hi Mindless Automaton,

    You can also make use of ANSI escape codes to do this.

    I.e., use your login script to display ansi background page, then the login prompt ansi part after.

    The Login ansi would begin by home-ing the cursor, for example (but not clearing the screen).

    However, the end result is the same as you've done so this isn't necessarily a better way, just a different one.

    Kind regards,
    +------------------------------+
    | Art % fatcats.poorcoding.com |
    +--------------- ----- -- -

    ---
    ■ Synchronet ■ fatcats bbs - http://fatcats.poorcoding.com
  • From Tracker1@TRN to Mindless Automaton on Wednesday, January 13, 2010 17:27:42
    For the login prompt, I wanted to display an ansi file in the background
    and then overlay the prompt text (Enter User Name..) on top.
    (Print ansi file, console.up & right to move cursor to print prompt)

    I can do this but when I just hit enter at the prompt, only the prompt text gets printed again, the ansi does not.

    Any ideas or any samples in the other js files on doing something like
    this?

    I have my entire mods directory in an archive on the website for this bbs on the download/files page.
    --
    Michael J. Ryan - tracker1(at)theroughnecks(dot)net - www.theroughnecks.net icq: 4935386 - AIM/AOL: azTracker1 - Y!: azTracker1 - MSN/Win: (email)

    ---
    ■ Synchronet ■ Roughneck BBS - telnet://roughneckbbs.com - www.roughneckbbs.com
  • From Tracker1@TRN to Mindless Automaton on Wednesday, January 13, 2010 17:29:53
    Any ideas or any samples in the other js files on doing something like this?

    Naturally I figured it out 5 seconds after posting. I sprinkled in a
    few console.home() before the ansi & each prompt and it works now.

    Let me know if there is a better way or tweak for this anyone can
    think of though..

    bbs.show() and console.home() are perfectly acceptable for this. One hint, is you can replace the text for the password prompt from script, if you wanted
    the username and password embedded inside the ansi itself.
    --
    Michael J. Ryan - tracker1(at)theroughnecks(dot)net - www.theroughnecks.net icq: 4935386 - AIM/AOL: azTracker1 - Y!: azTracker1 - MSN/Win: (email)

    ---
    ■ Synchronet ■ Roughneck BBS - telnet://roughneckbbs.com - www.roughneckbbs.com