Jump to content
  • 0

Normal Attacks to use SP


Humble_Bee

Question


  • Group:  Members
  • Topic Count:  54
  • Topics Per Day:  0.03
  • Content Count:  112
  • Reputation:   9
  • Joined:  09/22/19
  • Last Seen:  

How do I get normal attacks to use SP? I want to do this for every enemy and player type I can. Adding "status_zap" in various places hasn't worked for me yet, but perhaps I'm doing it in the wrong places.

Link to comment
Share on other sites

1 answer to this question

Recommended Posts

  • 0

  • Group:  Members
  • Topic Count:  54
  • Topics Per Day:  0.03
  • Content Count:  112
  • Reputation:   9
  • Joined:  09/22/19
  • Last Seen:  

So I didn't find the perfect way to do it, I'm sure, but I found A way to do it. I went into the "battle_damage" function in battle.cpp, and I added:

if (attack_type&BF_NORMAL)
		status_fix_spdamage(src, src, status_get_max_sp(src)/100, 0);

Meaning for both players and mobs (and likely others), it zaps 1% sp per normal attack. Haven't tested it with other mercs, pets, homs, or etc, but it seems to be working so far. It still allows people to keep attacking with 0 sp, but I fixed that by lowering the damage to 5% of what it normally would be, making into an "I'm exhausted, and all I can do is weakly swing my arms about" struggle feature. It works quite nicely.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...