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

Scripting Help


Recommended Posts

I'm trying to make a script where on warp a message tells you that you have warped and plays an animation (like one used for spells) so far this is what i have, if you want to help, it's needed, feel free to use the idea
```
Sub OnPlayerWarp(Index)
  If GetPlayerMap(Index,) <>2
  Get PlayerMsg("You have been warped.",BLACK)

  Else
  Get PlayerMsg("You have been warped to (mapname).",WHITE)
  End IF
End Sub
```I replaced the name of the map with (mapname) so if you try to fix it know this
Link to comment
Share on other sites

Doesn't matter, OnPlayerWarp isn't a command, and you can't make it work like that, however, you can have WarpPlayerWithAnim or something like that, here's how you would do it.

```
Sub PlayerWarpWithAnim(Index, Map, X, Y)
  Call PlayerMsg("You have been warped to " & GetMapName(Map) & ".",WHITE)
  Call SpellAnim(SpellAnimationNumberhere, Map, X, Y)
  Call PlayerWarp(Index, Map, X, Y)
End Sub

```
Replace SpellAnimationNumberhere with the spell number animation you want to play.
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...