DestroyerofNorth Posted August 16, 2015 Share Posted August 16, 2015 Can someone help me to change attack speed of a character and the damage multiplier to a specific enemy? Link to comment Share on other sites More sharing options...
DarkXero Posted August 16, 2015 Share Posted August 16, 2015 (edited) change attack speed If you know how to make a new animation with less frames than the attack one, then you can make that your attack.So, for you, very difficult. Think of something else. damage multiplier to a specific enemy-- inside master_postinit of character.lualocal my_multiplier = 2local old_CalcDamage = inst.components.combat.CalcDamageinst.components.combat.CalcDamage = function(self, target, weapon, multiplier) if target and target.prefab == "spider" then multiplier = (multiplier or 1) * my_multiplier end return old_CalcDamage(self, target, weapon, multiplier)end Edited August 16, 2015 by DarkXero Link to comment Share on other sites More sharing options...
DestroyerofNorth Posted August 16, 2015 Author Share Posted August 16, 2015 thx when i use the damage multiplier it crashes it has a problem with the: multiplier = (multiplier or 1) * my_multiplier Link to comment Share on other sites More sharing options...
DarkXero Posted August 16, 2015 Share Posted August 16, 2015 @DestroyerofNorth, I cut and pasted away the "then" for the "if". I edited the code. Link to comment Share on other sites More sharing options...
DestroyerofNorth Posted August 16, 2015 Author Share Posted August 16, 2015 ok thx it work you really can help everytime Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now