Section One BBS

Welcome, Guest.


Subject: Baja argument help Date: Mon Feb 14 2022 03:51 pm
From: DesotoFireflite To: Digital Man

  Re: Baja argument help
  By: Digital Man to DesotoFireflite on Sun Feb 13 2022 02:26 pm

 >> I can't understand it, I've worked with Baja before, and I thought I
 >> undersood it. I'm figuring with a new user, the last on would be
 >> 0(zero), and the Guest would be a restriction of "G", hence
 >> "compare_ars LASTON EQUALS 0 OR REST G", so as a regular user with no
 >> restrictions, and laston field populated with a date, it should be
 >> false, and go to else, the second half, but it's acting like it never
 >> sees the second half with regular users, but treats them like a new
 >> user or guest. I also tried "compare_ars LASTON=0 OR REST G" and got
 >> the same results. My logic must be flawed. It may be the LASTON
 >> causing the issue, but I don't know another way of determining a new
 >> user with ars or any other method. 

 DM> LASTON is initialized to the current date/time when a new user account is
 DM> created. "LOGONS" is probably the value you want to be checking. It should
 DM> be equal to 1 for a user's first logon.

 DM> By what you're describing, the second "else" section should *always* be
 DM> executing and it's the first ("if_true") section that isn't being
 DM> executed. In that case, fixing the ARS should solve that.

"LOGONS" was the key, it's working like I want it to now. I cleaned up the code 
a bit, so it doesn't look as klunky, see below. Thanks for the help.

!include sbbsdefs.inc
!include file_io.inc
!include dir_attr.inc

SETSTR "LOCAL"
MSG_SET_GROUP
SETSTR "NEWS"
MSG_SET_AREA

    compare_ars LOGONS=1 OR REST G
        if_true
        # If New User or Guest, go to Local Message Base and Read News...
            MSG_READ
        else
        # All other users, go to Local message Base, check for new messages In N
ews, and
        # show New Messages and if no New Messages exist, do nothing, and exit.
            MSG_NEW_SCAN_SUB
        end_if

SysOp: C.G. Learn, AKA: DesotoFireflite
Valhalla Home Services! - (Synchronet) - bbs.valhallabbs.com
Valhalla II! - (GAP) - bbs.valhallabbs.com:24
Valhalla III! - (RemoteAccess) - bbs.valhallabbs.com:5023
Valhalla IIII! - (Dungeons & Dragons BBS) - bbs.valhallabbs.com:26
Valhalla Home Services Web! - http://bbs.valhallabbs.com
A Gamers Paradise - Over 150 Registered Online Game Doors!
Home Of Odin's Maze Game Server!

--- Don't eat the yellow snow!
 ■ SynchronetValhalla Home Services USA http://valhalla.synchro.net

Previous Message       No More Messages
In Reply To: Baja argument help (Digital Man)