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

Time Bounus error.


cheatking
 Share

Recommended Posts

I get an error with this script. Anyone kow why?
```
' Executes every second, based on the server time.
Sub TimedEvent(Hours, Minutes, Seconds)
    If Minutes = 0 Then
        If Seconds = 0 Then
            Call PlayerMsg(Index, "Credits form in your hand.", WHITE)
            SLOT = 1
            Do While SLOT < 24
            If GetPlayerInvItemNum(index, SLOT) = 1 Then
                Call SetPlayerInvItemNum(index, SLOT, 1)
                Call SetPlayerInvItemValue(index, SLOT, GetPlayerInvItemValue(index, SLOT) + 50)
                Call SendInventoryUpdate(index, SLOT)
                SLOT = 24
                A = 1
            End If
            SLOT = SLOT+1
            Loop
            SLOT = 1
            Do While SLOT < 24 And A = 0
            If GetPlayerInvItemNum(index, SLOT) = 0 Then
                Call SetPlayerInvItemNum(index, SLOT, 1)
                Call SetPlayerInvItemValue(index, SLOT, 50)
                Call SendInventoryUpdate(index, SLOT)
                SLOT = 24
            End If
            SLOT = SLOT+1
            Loop
        End If
    End If
End Sub

```
Link to comment
Share on other sites

you can't use index's without specifying them in the timed event sub, because if you'll notice, it's not```
Sub Timeevent(index, hours, minutes, seconds)
```like the other subs in EE
so you need to run aloop for index's aswell as for slots..
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...