Shock Ability
#4
(05-22-2018, 11:16 AM)Lightning Wrote:
(05-22-2018, 02:34 AM)madsiur Wrote: Yes it's possible but you gotta code a check for enough MP, deduct the MP used from total and consider command disabling if MP below 50 and command enabling when MP goes back higher than 50, as an example following the use of an elixir. I'm not sure you could easily hook up to the existing system since Shock is not a spell and will likely have to redo part of the MP logic for this ability only. (Shock is also a spell but it is not cast here like spells are)

Sounds too complex for a non-coder like me to get into. Tongue

I'm not a coder by any means but it's less complicated if you know where to look.

If you go [here] it is disassembly of C2 (Assassin / Terri Senshi) and search for Shock you get the following:

Code:
Shock

C2/171A: A9 82        LDA #$82       ("Megahit" spell, which is what has Shock's data)
C2/171C: 80 02        BRA $1720      (go set that as spell/animation)


So if you use a coding tool (I use WinHex32) you can search for those pointers and make edits accordingly. I think this area might be relevant:

Code:
C2/57AA: BD 00 00     LDA $0000,X    (get spell # from menu)
C2/57AD: 30 0A        BMI $57B9      (branch if undefined)
C2/57AF: EB           XBA
C2/57B0: A5 EF        LDA $EF
C2/57B2: 10 07        BPL $57BB      (branch if character not an Imp)
C2/57B4: EB           XBA
C2/57B5: C9 23        CMP #$23    
C2/57B7: F0 02        BEQ $57BB      (branch if spell is Imp)
C2/57B9: 38           SEC            (spell will be unavailable)
C2/57BA: 60           RTS


(Set Carry if caster lacks MP to cast spell.
Clear it if they have sufficient MP.)

C2/57BB: BD 03 00     LDA $0003,X    (get spell's MP cost from menu data)
C2/57BE: CD 4C 3A     CMP $3A4C      (compare to Caster MP + 1, capped at 255)
C2/57C1: 60           RTS


But again, I'm a novice when it comes to coding so take this with a grain of salt.
Reply


Messages In This Thread
Shock Ability - by Lightning - 05-22-2018, 01:48 AM
RE: Shock Ability - by madsiur - 05-22-2018, 02:34 AM
RE: Shock Ability - by Lightning - 05-22-2018, 11:16 AM
RE: Shock Ability - by ShadowDreamer - 05-23-2018, 12:48 AM
RE: Shock Ability - by Turbotastic - 05-25-2018, 06:18 PM
RE: Shock Ability - by Tenkarider - 05-24-2018, 11:41 AM
RE: Shock Ability - by GrayShadows - 05-26-2018, 11:15 AM
RE: Shock Ability - by Turbotastic - 05-27-2018, 04:19 PM
RE: Shock Ability - by Lightning - 05-27-2018, 04:33 PM
RE: Shock Ability - by madsiur - 05-27-2018, 05:43 PM
RE: Shock Ability - by Lightning - 05-27-2018, 10:52 PM
RE: Shock Ability - by madsiur - 05-28-2018, 01:33 AM
RE: Shock Ability - by GrayShadows - 05-31-2018, 07:32 PM
RE: Shock Ability - by Lightning - 05-31-2018, 08:46 PM
RE: Shock Ability - by GrayShadows - 06-01-2018, 10:33 AM
RE: Shock Ability - by Lightning - 06-01-2018, 01:51 PM
RE: Shock Ability - by Warrax - 06-01-2018, 03:37 PM
RE: Shock Ability - by GrayShadows - 06-01-2018, 04:26 PM
RE: Shock Ability - by Lightning - 06-01-2018, 10:26 PM
RE: Shock Ability - by Turbotastic - 06-02-2018, 09:21 AM
RE: Shock Ability - by Lightning - 06-02-2018, 10:15 AM
RE: Shock Ability - by dn - 06-02-2018, 01:53 PM
RE: Shock Ability - by Turbotastic - 06-02-2018, 07:21 PM
RE: Shock Ability - by Lightning - 06-02-2018, 08:35 PM
RE: Shock Ability - by GrayShadows - 06-05-2018, 09:38 PM
RE: Shock Ability - by Lightning - 06-05-2018, 10:38 PM
RE: Shock Ability - by Lightning - 07-10-2018, 06:37 PM
RE: Shock Ability - by Lightning - 09-06-2018, 12:28 AM
RE: Shock Ability - by Gi Nattak - 07-10-2018, 07:35 PM
RE: Shock Ability - by Lightning - 07-10-2018, 11:05 PM
RE: Shock Ability - by Lightning - 07-19-2018, 03:52 PM
RE: Shock Ability - by GrayShadows - 07-20-2018, 12:53 AM
RE: Shock Ability - by Warrax - 07-20-2018, 01:24 AM
RE: Shock Ability - by PowerPanda - 07-20-2018, 12:19 PM
RE: Shock Ability - by GrayShadows - 07-20-2018, 12:26 PM
RE: Shock Ability - by Lightning - 07-20-2018, 05:44 PM
RE: Shock Ability - by Warrax - 07-20-2018, 05:56 PM
RE: Shock Ability - by Lightning - 07-20-2018, 05:58 PM
RE: Shock Ability - by PowerPanda - 09-10-2018, 10:53 AM
RE: Shock Ability - by Lightning - 09-10-2018, 01:01 PM
RE: Shock Ability - by PowerPanda - 09-10-2018, 01:37 PM
RE: Shock Ability - by Lightning - 09-10-2018, 01:42 PM
RE: Shock Ability - by PowerPanda - 09-10-2018, 02:13 PM
RE: Shock Ability - by Lightning - 09-10-2018, 03:20 PM
RE: Shock Ability - by PowerPanda - 09-10-2018, 04:22 PM
RE: Shock Ability - by Lightning - 09-10-2018, 06:44 PM
RE: Shock Ability - by PowerPanda - 09-10-2018, 07:46 PM
RE: Shock Ability - by Lightning - 09-10-2018, 09:03 PM
RE: Shock Ability - by madsiur - 09-10-2018, 09:31 PM
RE: Shock Ability - by Lightning - 09-10-2018, 09:41 PM
RE: Shock Ability - by PowerPanda - 09-10-2018, 10:35 PM
RE: Shock Ability - by Subtraction - 09-11-2018, 02:16 AM
RE: Shock Ability - by Lightning - 09-11-2018, 03:57 AM
RE: Shock Ability - by Warrax - 09-11-2018, 08:39 AM
RE: Shock Ability - by madsiur - 09-11-2018, 10:52 AM
RE: Shock Ability - by PowerPanda - 09-11-2018, 09:15 AM
RE: Shock Ability - by Lightning - 09-11-2018, 03:47 PM
RE: Shock Ability - by PowerPanda - 09-11-2018, 06:28 PM
RE: Shock Ability - by Lightning - 09-11-2018, 06:47 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Sabin kick ability Seifer 16 10,155 08-24-2022, 04:00 PM
Last Post: Seifer
  [From Discord] Shock step back C-Dude 0 1,194 01-11-2022, 08:49 PM
Last Post: C-Dude
  Replacing Runic with Shock Jeff 3 3,405 06-09-2021, 09:15 PM
Last Post: PowerPanda
  Shock/Health: Hardcoded animation? Kugawattan 6 6,523 05-16-2017, 06:14 PM
Last Post: Tenkarider
  Runic to Shock PowerPanda 6 7,988 02-20-2017, 06:09 PM
Last Post: Turbotastic
  Shock Location Snap006 3 3,840 06-23-2015, 07:31 AM
Last Post: SSJ Rick
  Runic AND SwdTech to Shock? Royaken 3 3,858 04-06-2014, 12:17 PM
Last Post: Xenovant
  Slot ability modification madsiur 6 9,071 02-17-2012, 08:39 PM
Last Post: madsiur

Forum Jump:


Users browsing this thread: 1 Guest(s)