[PSX/PC] General editor - Hades Workshop (0.50b)

  • Thread starter Thread starter Tirlititi
  • Start date Start date
Status
Not open for further replies.
About the "Spells" panel: yes, the Magic Swords are in there as well, but they are spread around. Most of them are next to Dagger's summons and Flare/Doomsday are at the end of the list.

About the "Localization" field, yes I noticed that. As strange as it appears, it's not a bug from HW but that's how the latest Steam version texts are (they were correctly set in the previous Steam versions). Don't bother.
 
About the "Spells" panel: yes, the Magic Swords are in there as well, but they are spread around. Most of them are next to Dagger's summons and Flare/Doomsday are at the end of the list.

About the "Localization" field, yes I noticed that. As strange as it appears, it's not a bug from HW but that's how the latest Steam version texts are (they were correctly set in the previous Steam versions). Don't bother.
wow.. you're right. I didn't notice at all. Changed in english and I easly found. Thank you very much for you'ra patience.
 
I was hoping I could find a few resources. I'm looking for a list of CIL methods with definitions. For example, I found in this thread that "CalcSub_203" is the CIL method for "Physical Strike". I'd like to know what the other definitions are for the rest of the "CalcSub".

Couple things that would be handy:
The ability to import/export lists of new CIL methods for a specific CIL class. For example:

If I had a file that contained a list of Customized CIL methods ("SubCalc_100" through "SubCalc_525") for "btl_calc", I could upload that as a sub mod that could be imported by HW.
 
Hi Tirlititi, hope you are doing great, once again thank you for working on this tool! have been wonderful.

May I ask, since you told me to check the CIL codes to modify some parts of the game engine results (not sure how to put that), have been quite difficult for me to understand the language, even though I got a little bit more use to it.

I wanted to ask, and I am quite sure will be possible, but not sure how to put it inside the coding. Can the party HP and MP be recovered after a battle? or 25% of current hp and mp? If anybody know how to put it, will be awesome for letting me know.
 
This tool looks really cool just from browsing it for awhile but I want to ask; Will editing AI for someone who has no experience in coding whatsoever be a challenge for me and I guess a random question but am I able to make Protect, Shell, Haste and Regen last longer? Imo they don't last long enough in this game to make them useful.
 
@aidolu12: Yes, it's extremely difficult to do CIL changes by only looking at the CIL code. It's way better to look at the C# code to at least understand how the engine works before guessing how you can tweak it (it requires reading C# but that's always better than CIL).
You can see the C# code in Memoria's Github page, or using a tool like dnSpy or dotPeek.

For your particular question, it's not particulary easy in CIL, but you might change the method "BattleHUD::GoToBattleResult" and add this kind of lines:
Code: [Select]
Code:
call 0x6000F5D // FF9StateSystem::get_Battleldfld 0x4002267 // BattleState::FF9Battleldfld 0x4002230 // FF9StateBattleSystem::btl_listldfld 0x4000226 // BTL_DATA::nextldfld 0x400022A // BTL_DATA::curldfld 0x4000809 // POINTS::hpcall 0x6000F5D  // FF9StateSystem::get_Battleldfld 0x4002267 // BattleState::FF9Battleldfld 0x4002230 // FF9StateBattleSystem::btl_listldfld 0x4000226 // BTL_DATA::nextldfld 0x4000229 // BTL_DATA::maxldfld 0x4000809 // POINTS::hpldc.i4.4divaddcall 0x6000F5D  // FF9StateSystem::get_Battleldfld 0x4002267 // BattleState::FF9Battleldfld 0x4002230 // FF9StateBattleSystem::btl_listldfld 0x4000226 // BTL_DATA::nextldfld 0x400022A // BTL_DATA::curstfld 0x4000809 // POINTS::hp
This only restores 25% of max HP of the 1st character only (and doesn't even check if it goes over the max HP limit)...
Best is to use Memoria for that and add these lines instead, since you can surely use local variables when replacing C# code:
Code: [Select]
Code:
for (BTL_DATA next = FF9StateSystem.Battle.FF9Battle.btl_list.next; next != null; next = next.next) if (next.bi.player != 0 && next.cur.hp>0)  next.cur.hp = min(next.cur.hp + next.max.hp / 4, next.max.hp);
Much simpler indeed ^^'

@Gordo98: What you want to do is not related to AI but to the battle system, so CIL code or C# again :/
And increasing the duration of status effects is not possible with HW, as explained here. The best you can do is to change the tick for poison/venom/regen.
 
@Tirlititi guess I’ll leave that how it is, but by AI I meant enemy patterns and attacks. For example having the following script.

Turn 1: 50% Poison 50% Silence
Turn 2: Attack
Turn 3: 50% Flare, 40% Stop, 10% Doomsday
Turn 4: Attack
Repeat
50% Counter Physical Attack w/ Stop

Something like that or editing existing enemies and replacing attacks or patterns.
 
Ok yes, this is AI script.

So actually, the default AI scripts are usually quite complex. One thing you should do before editing AI scripts is import the local variable informations ("LocalVariableSettings_v1.hws" that is included with the tool). It makes the scripts a bit more readable.
But writing a simple AI script like what you say can be done quite easily. Here is how the "ATB" function would look like:
Code: [Select]
Code:
Function Enemy_ATB    if (turn_counter == 0) {        // Turn 1        if (GetRandom % 2) {            set SV_Target = RandomInTeam( SV_PlayerTeam )            Attack( Poison ) // It is not "Poison" that should be in the real thing but the attack ID instead        } else {            // You may avoid Silencing someone who's already silenced using this kind of lines            set SV_Target = RandomInTeam( NotMatching(SV_PlayerTeam[STATUS_CURRENT_A], 265) & NotMatching(SV_PlayerTeam[STATUS_CURRENT_B], 64) )            if (SV_Target == 0) { // Everyone is either dead or silenced already...                set SV_Target = RandomInTeam( SV_PlayerTeam )            }            Attack( Silence )        }    }    if ((turn_counter == 1) || (turn_counter == 3)) {        // Turn 2 and 4        set SV_Target = RandomInTeam( SV_PlayerTeam )        Attack( Physical Attack )    }    if (turn_counter == 2) {        // Turn 3        set rnd_num = GetRandom % 100        if (rnd_num < 50) {            set SV_Target = RandomInTeam( SV_PlayerTeam )            Attack( Flare )        } else {            if (rnd_num < 90) {                set SV_Target = RandomInTeam( SV_PlayerTeam )                Attack( Stop )            } else {                set SV_Target = SV_PlayerTeam | SV_EnemyTeam                Attack( Doomsday )            }        }    }    set turn_counter = ((turn_counter + 1) % 4)    return
And declare the local variables "turn_counter" and "rnd_num" in the local variable panel:
Code: [Select]
Code:
local uint8 turn_counterlocal uint8 rnd_num
For the counter-attack, I suggest that you take a look at Gizamaluke's AI and mimic it.
 
@aidolu12: Yes, it's extremely difficult to do CIL changes by only looking at the CIL code. It's way better to look at the C# code to at least understand how the engine works before guessing how you can tweak it (it requires reading C# but that's always better than CIL).
You can see the C# code in Memoria's Github page, or using a tool like dnSpy or dotPeek.

For your particular question, it's not particulary easy in CIL, but you might change the method "BattleHUD::GoToBattleResult" and add this kind of lines:
Code: [Select]
Code:
call 0x6000F5D // FF9StateSystem::get_Battleldfld 0x4002267 // BattleState::FF9Battleldfld 0x4002230 // FF9StateBattleSystem::btl_listldfld 0x4000226 // BTL_DATA::nextldfld 0x400022A // BTL_DATA::curldfld 0x4000809 // POINTS::hpcall 0x6000F5D  // FF9StateSystem::get_Battleldfld 0x4002267 // BattleState::FF9Battleldfld 0x4002230 // FF9StateBattleSystem::btl_listldfld 0x4000226 // BTL_DATA::nextldfld 0x4000229 // BTL_DATA::maxldfld 0x4000809 // POINTS::hpldc.i4.4divaddcall 0x6000F5D  // FF9StateSystem::get_Battleldfld 0x4002267 // BattleState::FF9Battleldfld 0x4002230 // FF9StateBattleSystem::btl_listldfld 0x4000226 // BTL_DATA::nextldfld 0x400022A // BTL_DATA::curstfld 0x4000809 // POINTS::hp
This only restores 25% of max HP of the 1st character only (and doesn't even check if it goes over the max HP limit)...
Best is to use Memoria for that and add these lines instead, since you can surely use local variables when replacing C# code:
Code: [Select]
Code:
for (BTL_DATA next = FF9StateSystem.Battle.FF9Battle.btl_list.next; next != null; next = next.next) if (next.bi.player != 0 && next.cur.hp>0)  next.cur.hp = min(next.cur.hp + next.max.hp / 4, next.max.hp);
Much simpler indeed ^^'

@Gordo98: What you want to do is not related to AI but to the battle system, so CIL code or C# again :/
And increasing the duration of status effects is not possible with HW, as explained here. The best you can do is to change the tick for poison/venom/regen.
Tirlititi, thanks, I have not try it yet, I have been busy, but as soon, will let you know.
 
AI script,
what function makes the enemy perform an attack (ex. Attack(3) ) first every time the battle starts? Attack (3) the enemy will do every start of the fight.
 
Look at Black Waltz 3's AI script (the battle on the Cargo Ship). He starts the battle by casting trance on Vivi.
Basically, you need to "set SV_FunctionEnemy[ATB] =$ SV_FunctionEnemy[MAX_ATB]" and use a flag for the first attack of the enemy.
 
Just found a bug with HW version 39b.
Cannot change the value of >Power<, value reverts back to default.
 
is there a function in the script that resets the LV back to 1? boolean variable?
 
It is possible, yes. You just need to empty the party reserve and then setup the characters' data: with the "Update level" option, it usually sets the character's level to the average level of the party reserve, but it sets the level back to 1 for an empty party reserve.
Code: [Select]
Code:
    SetPartyReserve( 0 )    SetCharacterData( character_id, 1, 255, 255, 255 )  // By using 255 in the other arguments, you don't change the value    SetPartyReserve( 255 ) // May be different if you don't want the 8 regular characters to be available
 
Thanks Tirlititi!
guess what,
there's always something missing.
This doesn't apply to all characters, it only applies to one: Eiko
It definitely did not apply to Zidane either.
 
Last edited:
Awesome progress as always.
Would it be possible to add an exporter thats just OBJ for now, for the walkmeshes, I understand the cameras are a bit of a pain, so if those aren't a priority then I can just guesstimate the rest easily enough.
Having the walkmesh will save a lot of time with recreating some of the environments in HD.
 
I don't exactly know what you're preparing us, but that sounds very neat :D
Here are the walkmeshes:
https://www.dropbox.com/s/p0yvu6ofcj658u1/FF9Walkmeshes.zip?dl=1

I don't think that I'll add an option to export them in HW as I am pretty sure that there will never be an importer of walkmeshes in OBJ format. Adding an exporter may make people think that walkmeshes are just a bunch of triangles. I'll just let the walkmeshes here.

PS: I double-faced the triangles because apparently the orientation of triangles is not relevant for walkmeshes.
 
Lining these up with Cameras is going to take quite a while, but I'll do what I can.

Ah yeah, this project is... going to take a long time, but I want to have some things to show before I see if anyone else is interested, see if I can get myself a good workflow and the like first.

Thankyou for those, I really appreciate it, if you by chance also happen to know how to export the cameras too, as FBX files, that'll speed things up even more.
I have a tool that exports the FF8 walkmeshes and camera all in the correct positions, which was super handy for running tests, though ironicly enough, I find that FF8 doesn't really have any good camera angles, or makes nearly as much use of its pre-render medium as ffix does.
 
Tirlititi, I noticed a glaring bug with Vivi using either Cure or Life spells outside of battle. I give him Cure/Cura etc. or Life/Full-Life, and attempt to revive or heal an ally outside of battle, it doesn't heal or revive a character, only depletes his MP, and the Target Window for "Life" shows as if you're curing Bad Statuses.
Differently If I give Steiner/Zidane/Freya Cure/Cura/Life etc., it works perfectly fine. Is this the game's way of showing a black mage just wasn't meant to have white magic?
Also, if a character like Eiko/Dagger (any character who can use Cure) is only in the party, and tries to use Cure outside of battle on themselves, the Target Window refuses to show up. I don't think that was ever present in PSX version.

And about the walkmeshes: specific foot sfxs datas (metal, sand, grain etc.) are stored in the walkmeshes? Replace it and those are lost?
These walkmeshes look like a similar to the meshes I did in The Mist: Resurrection, Memoria levels, tbh.
 
Status
Not open for further replies.
Back
Top