Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Bank
#1
Ok I fixed the majority of a code and based the fixes off of Robin's code but I can not seem to get it to completely function, it makes the Bank folder and sets everything up for the system but it will not save the players bank within the bank folder, and here seems to be why but I can't figure out how to fix it and I have tried about every way I can think of

Ok first off in packet 'Login' it highlights .Bank and gives the error message "method or data member not found"
Code:
If FileExist("banks\" & Trim(Name) & ".ini") = False Then
                For i = 1 To MAX_CHARS
                    For n = 1 To MAX_BANK
                        Call PutVar(App.Path & "\banks\" & Trim(Name) & ".ini", "CHAR" & i, "BankItemNum" & n, STR(Player(Index).Char(i).Bank(n).Num))
                        Call PutVar(App.Path & "\banks\" & Trim(Name) & ".ini", "CHAR" & i, "BankItemVal" & n, STR(Player(Index).Char(i).Bank(n).Value))
                        Call PutVar(App.Path & "\banks\" & Trim(Name) & ".ini", "CHAR" & i, "BankItemDur" & n, STR(Player(Index).Char(i).Bank(n).Dur))
                    Next n
                Next i
            End If
and in sub clear player
Code:
For n = 1 To MAX_BANK
            Player(index).Char(i).Bank(n).Num = 0
            Player(index).Char(i).Bank(n).Value = 0
            Player(index).Char(i).Bank(n).Dur = 0
        Next n
By the way if it helps any this is server side only, the
Code:
for n = 1 to max_bank
is when I try running it, and
Code:
If FileExist("banks\" & Trim(Name) & ".ini") = False Then
is when I try to login and or create a new account, I worked out the rest and got it working(because origanally it was not saving the bank folder) but so far I am at a loss for a answer.
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)