Uh... Acocunt banning

Here you can post threads requesting help on the official POL Ultima Online Emulator Core 095. Note: Core 095 is no longer officially supported.

Moderator: POL Developer

Post Reply
Poi
Grandmaster Poster
Posts: 298
Joined: Fri Apr 14, 2006 9:36 am

Uh... Acocunt banning

Post by Poi »

I seen this in a post recently i thought, but i cant find it, anyway how do you set the # of days for ana ccount to be banned for inactivity?
User avatar
CWO
POL Expert
Posts: 1159
Joined: Sat Feb 04, 2006 5:49 pm

Post by CWO »

You probably have to set up your own system for that since POL doesnt have that option and I dont know if any default scriptsets do. If so, it'd be up to the scriptset if it exists in there.
Poi
Grandmaster Poster
Posts: 298
Joined: Fri Apr 14, 2006 9:36 am

Post by Poi »

It does do it, it shows it in the console
User avatar
CWO
POL Expert
Posts: 1159
Joined: Sat Feb 04, 2006 5:49 pm

Post by CWO »

Then your scriptset is doing it because I have never seen anything like this for the POL core itself. Only scripts would do it.
Yukiko
Distro Developer
Posts: 2825
Joined: Thu Feb 02, 2006 1:41 pm

Post by Yukiko »

POL 95 Distro auto bans accounts after 30 days of inactivity. Look in saver.src in the \pol\pkg\systems\saver directory.

The following function, starting on line 24, is where the actual time check is done and the account deletion is accomplished:

Code: Select all

function accountcheck()
  var accts := ListAccounts();
  var lasttime;
  var acct, chr, holder;
  var i := 1;
  var rgc := ReadGameClock();
  foreach nme in accts
    acct := FindAccount(nme);
    if(acct)
      lasttime := acct.GetProp("LastLogin");
      if(!lasttime)
        acct.setprop("LastLogin", rgc);
      else
        if((rgc - lasttime) > 2592000)
          i := 1;
          while(i <= 5)
            chr := acct.GetCharacter(i);
            if(chr)
              holder := GetObjProperty(chr, "LastLogin");
              if(holder > lasttime)
                lasttime := holder;
              endif
            endif
            i := i + 1;
          endwhile
          if((rgc - lasttime) > 2592000) // if account has been inactive for 30 days (in seconds)
            DeleteAccount(nme, acct); // then ban it!
          endif
        endif
      endif
    endif
  endforeach
endfunction

Just decide the number of days you wish the account to remain inactive before banning. Then convert that to seconds (days * 60 * 60 * 24) and enter the seconds in the function and recompile.
Marilla

Post by Marilla »

Ummm... wow!

May I gently suggest that is a BAD idea, and recommend significantly changing it, or making it optional, in the 096/7 distro?

First, 30 days seems far too short. I can't count the number of times players have been gone from our shard for longer than 30 days, and then come back. It would have been a nightmare for them to have found their accounts apparently completely deleted upon their return! If I have players taking hiati (the plural of hiatus?) longer than 30 days, I know other shards are!

Second, I don't know what that function does, but by the name, it appears to not just disable or ban, but actually DELETE the account. On the one hand, I see no reason whatsoever to ban or disable an account simply for being inactive, so actually deleting it, along with characters, bank boxes, and housing at least seems to serve a purpose. But again, I'd have to go back to the above: 30 days? Ack!!!



I would suggest a change that, by default, does nothing to accounts or at minimum, perhaps, increases the time to one year. (60*60*24*365). I would then recommend perhaps an admin-level command which can be used to manually delete old, unused accounts based on an input parameter # of days, complete with lots of 'idiot-proofing' code to be sure that nothing bad happens if the admin using the command accidentally enters that they want to delete accounts that have been inactive for 0 or more days!
Yukiko
Distro Developer
Posts: 2825
Joined: Thu Feb 02, 2006 1:41 pm

Post by Yukiko »

I agree with you Marilla, it should be changed or may I suggest that things like the above noted "features" be documented so that people like me, back in the very early days of my experience with POL, don't pull all our hair out trying to figure out why player's accounts get banned for no apparent reason. It took me a long time to find the reason 4 years ago when I started my original shard.

Since POL is (or was) designed to emulate OSI/EA this begs the question, "Does OSI/EA auto ban accounts that are inactive for 30 days?" I am certain they ban non paid accounts but paid but inactive...? I doubt that.

I personally have no problem with a six (6) month inactive ban time but 30 days is a bit crazy.

May I add to your suggestion Marilla the inclusion of a check for a CProp to prevent an account from being deleted at all. Oh maybe if "NoDelete == 1" then the account stays active indefinitely.

Anyway, I am not aware if this exists in the 97 Distro. Frankly I am working on a converted 95 Distro and slowly converting stuff I like to my "POL95-->96" system. So if the same exists in 97 then hopefully the devs will take note of this thread.
Post Reply