Hello i wanna make some critical damage passive spell. To do that i need to get first what damage player will deal on next attack and then add to it like 3%,6% of this damage value and then character attacks normally but with that critical add value. It should look like :
1. Script checks that player have that critical damage passive skill / if do then
2. Get's next damage value from normal attack and save it to local damage variable
3. checks what level of that passive critical skill player have
4. depends on level it gives 3%,6%,9%,12% more damage
5. local critical = 3%*damage // if sklll level =1
6. damage = damage + critical
7. return damage and player attack
Problem is i don't know any function that will calculate next damage by normal hit and if there is some function like onAttack where i can send that critical damage to deal it.
- - - Updated - - -
bump!
1. Script checks that player have that critical damage passive skill / if do then
2. Get's next damage value from normal attack and save it to local damage variable
3. checks what level of that passive critical skill player have
4. depends on level it gives 3%,6%,9%,12% more damage
5. local critical = 3%*damage // if sklll level =1
6. damage = damage + critical
7. return damage and player attack
Problem is i don't know any function that will calculate next damage by normal hit and if there is some function like onAttack where i can send that critical damage to deal it.
- - - Updated - - -
bump!
Last edited: