#P5R - Editing Enemy Attacks

62 messages · Page 1 of 1 (latest)

next basin
#

Hey everyone, I tried replacing an enemy skill, in this case, Kelpie replacing Garu with Garudyne. I'm using 010 Editor and attempted to modify it in UNIT.TBL, but it still seems to cast Garu. Obviously I am not giving a Dyne tier skill to an enemy this early but this is for testing purposes.

sly parrot
#

And unfortunately, I have zero clue how to edit those.

#

Ive decompiled P4G's AI scripts out of curiosity, but I have zero clue how youd go about properly editing them

next basin
sly parrot
next basin
#

Will keep this marked as unresolved for now, if anyone does know how to modify AI files, a comment or documentation would be appreciated here.

cobalt linden
#

If you get as far as decompiling the AI scripts to get a Flow script, it's actually pretty easy to change the used skills around for any existing scripts, and the syntax for using a skill is pretty clear. It just takes the skill ID used elsewhere and sticks that inside of a function to use it if the script meets a certain condition, eg you might see something like "AI_ACT_SKILL( 14 )" which will use Maragion

#

Where it gets a little more complicated is if the enemy you're trying to modify doesn't have a script assigned to them, with 010 Editor you can check segment 0 of ELSAI to see if they have a script by their enemy ID, if there's a 0 listed there, they work off a default that there isn't much documentation for

#

you can freely switch around which AI scripts are assigned to which enemies in that table though, and you can naturally have multiple enemies pull from a single script if you wanted

next basin
sly parrot
cobalt linden
sly parrot
cobalt linden
#

There's that and also getting the robots to spawn in the first place iirc

sly parrot
#

Isnt that controlled by Okumura himself though?

#

Since Work Order is a Summon skill

cobalt linden
#

Right, part of it would be in his script and the other part would be in theirs

sly parrot
#

What about their spawning is controlled by the robots?

#

I have a lot of stuff written down about stuff id like to do with P5R if I had the proper knowledge

#

Like a harder/superboss variant of Yaldabaoth

#

ive heard that a lot of stuff about yaldy is hardcoded too

cobalt linden
#

The spawning would be in his script, the detonating would be in theirs

sly parrot
#

I kind of assumed that

cobalt linden
#

yeah Yaldy I haven't even looked at much for precisely that reason

sly parrot
#

Sacrifice Order does nothing on its own, but when used on the robots, it must trigger some kind of AI flag that has priority over all other actions

#

Also, one thing I wish we could change, though it might not be currently possible. Allow strength-based Magic attacks (Yes, these do work (somewhat)) to crit

#

Though, as far as I know, the only strength based magic attack in the original P5 was Akechi's Laevateinn

#

Ive tested it, and it actually consumes Charge, not Concentrate

cobalt linden
#

Not a whole lot is written about hardcoded things at present, pretty much why ELSAI.tbl is good for changing around scripts but trying to mess with the "default AI" in the other segment is more trouble than it's worth

sly parrot
#

Ive also tried fiddling with the skill tables and setting magic attacks like Agi to be strength based to see if I can get them to crit, but it doesnt work.

sly parrot
cobalt linden
#

Mostly everyone I've seen going the AI route ends up just writing scripts from scratch for every enemy

#

pretty much what I'm doing lol

sly parrot
#

So wait, theres a default AI script that most enemies use?

#

I know that some enemies, particularly the red Savage Shadows use their own special scripts

#

Anubis has the scale tipping which determines what element of insta-kill he uses

#

And Kali has the rage mechanic which allows her to attack once you hit her enough iirc

cobalt linden
#

not so much a default AI script but something built into the ELSAI table that anyone with 0 as their script number tries to pull from

sly parrot
#

Im guessing its very simple, because I remember there being an unused Metatron Shadow in vanilla P5 that would only use its normal attack if fought

#

Which was eventually repurposed to be used in one of Royal's Challenge Battles

#

What about enemies that literally dont do anything? Treasure demons, Im assuming they have their own script because it displays the message that they "groan" and causes them run after two/three turns

#

But enemies like Kamoshida's Trophy and Cognitive Shiho

#

they literally do nothing

cobalt linden
#

For something to not have any AI at all they get 9999 as their script ID

sly parrot
#

ah ok

cobalt linden
#

and yeah Metatron and Beelzebub are sequentially 1 and 2 in the entire unit table, and yeah they also have 0 as their script iD

#

so that's essentially how it works

sly parrot
#

I wonder if its possible to replace an enemy's normal attack

#

As in, if their AI defaults back to having them use a normal attack, it could be replaced by a custom normal attack

#

Like in Nocturne Hardtype

#

Metatron in that rom hack has a very powerful normal attack that is guaranteed to inflict Seal

#

I can think of many things that could be done with such a thing

#

@cobalt linden one thing itd be my fucking dream to do is the split Physical back into Strike, Slash and Pierce in p5r

full shadow
#

Gun pretty much is Pierce. Guns in P3 were considered Pierce Phys

sly parrot
#

I know that, but id still like to do it

#

Id consider Pierce to be more like spears or javelins

#

And theres been plenty of skills like that

next basin
#

In fact most of them have a ton of "UNKNOWN_FUNCTION" entries.

#

(Maybe don't decompile for SMT3 Nocturne you idiot...) Okay