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

Proofread, it doesn't work (solved)


Diskmaster
 Share

Recommended Posts

Hi, I am not good at timers (in fact, I used them for the first time ever today) but, I can't get this simple timer to work, as in, It is a scripted tile that is supposed to freeze you in place with a nifty little animation then, after 4 seconds, you unfreeze, NONE of the script activates which means there is a syntax error somewhere in there, but I am no good at timers so, could someone take a look at this and see what is wrong.  Here is the scripted tile:
```
Case 5
Call SpellAnim(index, GetPlayerMap(index), GetPlayerX(index), GetPlayerY(index), 200)
Call LockPlayer(index, 1)
Call PlayerMsg(index, "aah, a blast of ice has frozen you in place!", CYAN)
Call SetTimer("Freeze(index)" & index & "," & "Freeze(index)", 4000)

```Here is the sub the timer calls:
```
Sub Freeze(index)
Call PlayerMsg(index, "You have been defrosted!", CYAN)
Call LockPlayer(index, 0)
Call RemoveTimer("Freeze(index)")
End Sub

```ANY help would be appreciated  :azn:
Link to comment
Share on other sites

```
Case 5
Call SpellAnim(SPELLNUM, GetPlayerMap(index), GetPlayerX(index), GetPlayerY(index))
Call LockPlayer(index, 1)
Call PlayerMsg(index, "aah, a blast of ice has frozen you in place!", CYAN)
Call SetTimer("Freeze " & index, 4000)
```
```
Sub Freeze(index)
Call PlayerMsg(index, "You have been defrosted!", CYAN)
Call LockPlayer(index, 0)
Call RemoveTimer("Freeze " & index)
End Sub
```
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...