Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

255 break PlayerStats limit


Ananke
 Share

Recommended Posts

i did it.

edit: ok i got it3

Sub SetPlayerStat(ByVal Index As Long, Stat As Stats, ByVal value As Long)
    ' If debug mode, handle error then exit out
    If Options.Debug = 1 Then On Error GoTo errorhandler

    If Index > MAX_PLAYERS Then Exit Sub
    If value <= 0 Then value = 1
    If value > MAX_byte Then value = MAX_byte    **<–-- change byte to long**

    Player(Index).Stat(Stat) = value

    ' Error handler
    Exit Sub
errorhandler:
    HandleError "SetPlayerStat", "modDatabase", Err.Number, Err.Description, Err.Source, Err.HelpContext
    Err.Clear
    Exit Sub
End Sub

Big thanks 2 You!!!
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...