Attribute VB_Name = "GroupedLists"
Option Explicit

Public Operators(1 To 255)      As String
Public TotalOperators           As Integer

Public CapitalShips(1 To 255)   As String
Public TotalCapitalShips        As Integer

Public Ignores(1 To 255)        As String
Public TotalIgnores             As Integer

Public Sub AddOp(Name As String)
    If TotalOperators = 255 Then Exit Sub
    TotalOperators = TotalOperators + 1
    Operators(TotalOperators) = LCase(Name)
End Sub

Public Sub RemOp(Name As Integer)
    Dim I As Integer
    
    For I = Name To TotalOperators
        Operators(I) = Operators(I + 1)
    Next
    TotalOperators = TotalOperators - 1
End Sub

Public Sub AddCap(Name As String)
    If TotalCapitalShips = 255 Then Exit Sub
    TotalCapitalShips = TotalCapitalShips + 1
    CapitalShips(TotalCapitalShips) = LCase(Name)
    If CInt(GetProfile("CapitalDate", LCase(Name))) <> CInt(Day(Date)) Then
        Call SetProfile("CapitalCount", LCase(Name), "1")
        Call SetProfile("CapitalDate", LCase(Name), CStr(Day(Date)))
    Else
        Call SetProfile("CapitalCount", LCase(Name), CStr(GetCapCount(Name) + 1))
    End If
End Sub

Public Sub RemCap(Name As Integer)
    Dim I As Integer
    
    For I = Name To TotalCapitalShips
        CapitalShips(I) = CapitalShips(I + 1)
    Next
    TotalCapitalShips = TotalCapitalShips - 1
End Sub

Public Sub AddIgnore(Name As String)
    If TotalIgnores = 255 Then Exit Sub
    TotalIgnores = TotalIgnores + 1
    Ignores(TotalIgnores) = LCase(Name)
End Sub

Public Sub RemIgnore(Name As Integer)
    Dim I As Integer
    
    For I = Name To TotalIgnores
        Ignores(I) = Ignores(I + 1)
    Next
    TotalIgnores = TotalIgnores - 1
End Sub
