Any idea on how to give staves custom range?

I tried simply setting Heal’s range to 1-2. The range was displayed properly, but it doesn’t actually work. Units 2 spaces away don’t prompt the Heal command.

So uh… what the heck’s that all about?

I don’t know how it works, but I know @brendor had a tech demo for extended staff range for last year’s FEE3

Which leads me to assume there’s some extra wizarding involved in making it work

Staff range is hard-coded. I was working on a fix for it, gave up for a bit, and will try again once I get some free time.

It’s in the item effect code itself, it passes 1 as a parameter to some master range routine you’d have to change that; dunno the address offhand though.

I have an idea. Why dont you creat a new magic tome with effect to heal a unit about 10 or 20 HP per used

Some items have something, that I like to call the target pointer. I think it’s that, that you like to edit. It starts at 0x27124 (I think?) it is for the Items 0x4A to 0x80. If you want for example make a custom heal staff, than you’ll need to edit this, otherwise you can target other characters with your heal stuff, even if they have full HP. I’d recommend to locate the physic’s target pointer and paste it to the heal staff’s one.

If that’s not working I would also recommend to take a look at the Effekt/Condition’s table. Maybe you’ll make some edits there too.

It has to do with the item/staff usability routine. See Blazer’s old post on custom items.

Is there an echo in here?
Anyway in FE7 the routine exists at $8023A74; however, this is used for all the 1 range unit commands (trade, rescue etc), so you have to make a new separate routine to call which should be identical to the one range except pass in 2 instead of 1 (mov r2, 2), else your unit commands will be fucked. tbh it’s probably more trouble than it’s worth unless you know what you’re doing or you realllly want it.

Why not use the existing routine for 1-2 range?

It doesn’t work for heal staves

Do you have the FE8 address for the routine? Also is it the same routine for both usability and effect?

Not on hand, no
You can trace it really easily though by setting a bpx on the effect address

1 Like

Found it at $8024f70