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

A question regarding damage mods


Havear
 Share

Recommended Posts

I am trying to figure out how I can add the Magic stat level to the damage caused by the following script.
```
Case 1
Dim Target
' This is a simple flame spell
If Int(GetPlayerTarget(Index)) > 0 Then
Target = GetPlayerTarget(Index)
Call DamagePlayer(Index, Target, 5)
Else
Target = GetPlayerTargetNPC(Index)
Call DamageNPC(Index, Target, 5)
End If
    Exit Sub
```
Can anyone help?
Link to comment
Share on other sites

Well, it depends on how much damage you want to do with it… but basicly...
```
Case 1
Dim Target
Dim MDC
'This is a simple flame spell
'Damages target for Magic stat times 2
MDC = Int(GetPlayerMagi(index) * 2)
If Int(GetPlayerTarget(Index)) > 0 Then
Target = GetPlayerTarget(Index)
Call DamagePlayer(Index, Target, MDC)
Else
Target = GetPlayerTargetNPC(Index)
Call DamageNPC(Index, Target, MDC)
End If
Exit 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...