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

Force Push Not Working


cooldood92
 Share

Recommended Posts

I made this script but it won't subtract mp or move the targeted person, hell it probably won't even return an invalid target, what's wrong with this script?

```
        ' Force Push
        if GetPlayerTarget( Index) = 0 then
            Call PlayerMsg( Index, "Invalid Target", 12)
            Exit Sub
        End If
        if GetPlayerMP( Index) > 29 then
            Call SetPlayerMP( Index, GetPlayerMP( Index) - 30)
            Call SendMP( Index)
        Else
            Call BattleMsg( index, "Not enough mana!", 12, 0)
            Exit Sub
        End If
        if GetPlayerDir( Index) = 0 then
            SetPlayerY(GetPlayerTarget( Index), GetPlayerY(GetPlayerTarget( Index)) - 1)
        End If
        if GetPlayerDir( Index) = 1 then
            SetPlayerY(GetPlayerTarget( Index), GetPlayerY(GetPlayerTarget( Index)) + 1)
        End If
        if GetPlayerDir( Index) = 2 then
            SetPlayerX(GetPlayerTarget( Index), GetPlayerX(GetPlayerTarget( Index)) - 1)
        End If
        if GetPlayerDir( Index) = 3 then
            SetPlayerX(GetPlayerTarget( Index), GetPlayerX(GetPlayerTarget( Index)) + 1)
        End If

```
Edit: None of my scripted spells are working now actually…wtf? Oh they work if I remove force push...
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...