Author Topic: [PSX/PC] Field Editor - Makou Reactor (2.1.0)  (Read 523218 times)

Kaldarasha

  • *
  • Posts: 2449
  • Prince of Model Editing
    • View Profile
Re: [FF7PC/PSX] Field Editor - Makou Reactor (1.7.1)
« Reply #675 on: 2016-06-10 20:12:28 »
I currently investigating the light setting in the model loader. I absolutely sure that not everything is a color but coordinates from where the light comes. At the moment I only can say that the color in the right is setting the models global light color.

Edit1:
So I made the whole list white (except the last color at the right) and the model has no light shading. So I started to give the model its correct color settings back step by step. I only changed the first two and get an effect. That's what I have found:


The first defines the color while the second defines its source as well as the third.
It probably has that structure
1 color - direction one - direction two (maybe decides if far or near)
2 color - direction one - direction two
3 color - direction one - direction two
4 global color of the model
« Last Edit: 2016-06-10 21:03:04 by Kaldarasha »

Kaldarasha

  • *
  • Posts: 2449
  • Prince of Model Editing
    • View Profile
Re: [FF7PC/PSX] Field Editor - Makou Reactor (1.7.1)
« Reply #676 on: 2016-06-10 21:13:44 »
And here is my request.

At first change the light section to the color groups and their directions. Second add to the model viewer the three lights to see the effect immediately (also add a way to rotated around the model.

I assume that the ambient light can change the 3 lights and the light shader the global color of the model.

DLPB_

  • Banned
  • *
  • Posts: 11006
    • View Profile
Re: [FF7PC/PSX] Field Editor - Makou Reactor (1.7.1)
« Reply #677 on: 2016-07-30 16:25:24 »
Anyone know how opcode 7f works?  I assumed that if I set the generator to a certain number that all random numbers generated by opcode 99 would then follow a pattern.  But this doesn't seem to happen.

sithlord48

  • *
  • Posts: 1640
  • Dark Lord of the Savegame
    • View Profile
    • Blackchocobo
Re: [FF7PC/PSX] Field Editor - Makou Reactor (1.7.1)
« Reply #678 on: 2016-07-31 14:45:11 »
"Seeds the random number generator used by RANDOM. The lower four bits of the arguments are used as the seed value by altering the offset used to take a value from the table of pseudo-random numbers. "

try setting only the lower 4 ?  it does seam that it should allow you to get a pattern as you will ge setting the seed. unless they are also using some cycle count or time check when making the random numbers.

DLPB_

  • Banned
  • *
  • Posts: 11006
    • View Profile
Re: [FF7PC/PSX] Field Editor - Makou Reactor (1.7.1)
« Reply #679 on: 2016-07-31 14:55:26 »
I think the latter might be how it's working.  But I use Ochu with my save states - that can reset all vars to exactly as they were... and it still changes. So maybe other things to consider other than vars / time.

KakCAT

  • *
  • Posts: 1
    • View Profile
Re: [FF7PC/PSX] Field Editor - Makou Reactor (1.7.1)
« Reply #680 on: 2016-08-03 19:49:36 »
Hi!

first of all, thanks for this program. As an old-skool 'debug your favourite games' guy it's the best tool I've ever met :)

I wanted to ask a question about the script/events for the groups. For what I've seen there's two kind of groups, the "normal" ones (with init, main, when being field model talk, contact, and a number of scripts).

The other groups are usually of type "line" . The scripts in this "line" type are Init,Main, [OK], S2-Move, S3-Move, Go, Go1x, Go away , and scripts.

I suppose the 'line' group is to in example, mark exits or executing actions when reaching certain region, like in example climbing stairs.

My questions are

1) is the 'line' the only type of group with those scripts/events? Is there, i.e., polygon, or quad with the same events as line?

2) What is the meaning of [OK], S2-Move and S3-Move?  Main and Init are obvious, and if I'm not wrong, "Go" is to be run whenever the player is over that line, "Go 1X" is to be run the first frame the player is over that line, and "Go Away" is to be run the first frame the player is not stepping over the line after at least one frame stepping over the line. (feel free to correct me if those are not the meanings too)

Thanks! :)

DLPB_

  • Banned
  • *
  • Posts: 11006
    • View Profile
Re: [FF7PC/PSX] Field Editor - Makou Reactor (1.7.1)
« Reply #681 on: 2016-08-03 19:58:30 »
From what I can see S2 and S3 are the same thing.  They will be repeatedly fired when you move over the line.  Go-1x is only initiated once until you move away, which is Go away (seen with Save Points).

Very little information is available on all this, so do some testing and come back and tell us.  I'd be happy to know too.  I've done a bit of testing with lines, but nothing in-depth.  Lines use certain scripts for these specific functions.

jusete

  • *
  • Posts: 416
  • https://www.paypal.me/JRGV
    • View Profile
    • Donate here
Re: [FF7PC/PSX] Field Editor - Makou Reactor (1.7.1)
« Reply #682 on: 2016-08-18 13:23:38 »

Hey guys, do you know How to ask for materia in the inventory? I want to create a event that needs a specific materia in the inventory but I don't know How to do that.

Kaldarasha

  • *
  • Posts: 2449
  • Prince of Model Editing
    • View Profile
Re: [FF7PC/PSX] Field Editor - Makou Reactor (1.7.1)
« Reply #683 on: 2016-08-19 10:43:08 »
Add module -> Party and inventory -> Amount of Materia.

jusete

  • *
  • Posts: 416
  • https://www.paypal.me/JRGV
    • View Profile
    • Donate here
Re: [FF7PC/PSX] Field Editor - Makou Reactor (1.7.1)
« Reply #684 on: 2016-08-19 11:52:24 »
Thanks kaldarasa. I tried that one you mean, but don't works. I want to active a script when cloud cross a line with 3 conditions: yuffie must be in the party, cid must be in the party and you should to have bahamut zero in the inventory. With the first and second condition works perfect but I dont know How to figure out the last one.

I'm modding the Pc versiĆ³n

Enviado desde mi D6503 mediante Tapatalk
« Last Edit: 2016-08-19 11:54:50 by jusete »

Kaldarasha

  • *
  • Posts: 2449
  • Prince of Model Editing
    • View Profile
Re: [FF7PC/PSX] Field Editor - Makou Reactor (1.7.1)
« Reply #685 on: 2016-08-19 11:55:51 »
Look how they have done it to get the master materia.

DLPB_

  • Banned
  • *
  • Posts: 11006
    • View Profile
Re: [FF7PC/PSX] Field Editor - Makou Reactor (1.7.1)
« Reply #686 on: 2016-08-19 13:29:11 »
You have to look at what variable is set when Bahamut Zero is collected. Do what Kaldarasha said.

Also, this thread is not for queries like this, really.
« Last Edit: 2016-08-19 15:35:10 by DLPB »

jusete

  • *
  • Posts: 416
  • https://www.paypal.me/JRGV
    • View Profile
    • Donate here
Re: [FF7PC/PSX] Field Editor - Makou Reactor (1.7.1)
« Reply #687 on: 2016-08-19 15:31:21 »
Sorry about that, dlpb. And Thanks for the answers, guys. I will try to do that you mean.

Enviado desde mi D6503 mediante Tapatalk


DLPB_

  • Banned
  • *
  • Posts: 11006
    • View Profile
Re: [FF7PC/PSX] Field Editor - Makou Reactor (1.7.1)
« Reply #688 on: 2016-08-23 19:37:05 »
Info:

Modules - Display a Menu -

"Menu 22" is used to determine if certain materias are available in your inventory.

Parameters:

0: Are all Magic materias present in party's inventory and are they mastered?
1: Are all Summon materias present in party's inventory and are they mastered?
2: Are Command materias present (those that can be fused) in party's inventory and are they mastered?
3: Are Bahamut and Neo Bahamut materias present in party's inventory?

Number 3 could have been done without the need for a dedicated operation by using the vars that are set when you gain Bahamut and Neo Bahamut, but they chose to do it this way on field bugin1b.

The result is placed into var [15][111]. If [15][111] is 0, then the result of the above conditions is false. Obviously [15][111] has to be set to 0 before the operation is called.
 
« Last Edit: 2016-08-23 19:41:05 by DLPB »

myst6re

  • *
  • Posts: 648
  • Light King of the Savegame - Field Master - FF8.fr
    • View Profile
    • FF8.fr
Re: [FF7PC/PSX] Field Editor - Makou Reactor (1.7.1)
« Reply #689 on: 2016-08-23 21:44:27 »
Thanks DLPB :-)

DLPB_

  • Banned
  • *
  • Posts: 11006
    • View Profile
Re: [FF7PC/PSX] Field Editor - Makou Reactor (1.7.1)
« Reply #690 on: 2016-08-24 08:52:57 »
Additionally, Menu 23 removes the materias (once you have fused them, Menu 23 is called with the same parameters to remove the Mastered materias).

So Menu 22 - is a check, as stated above.  And Menu 23 is "remove Mastered materias that were fused". 

I am not sure why Menu 23 is called for Bahamut Zero - since Neo and Bahamut are not removed from the inventory - and do not need to be Mastered.  Perhaps at one point this was going to serve that function.  So Menu 23 parameter 3 is redundant.

Well, Menu 23 Parameter 3 does add the Bahamut Zero to your inventory, but you could do that with the normal function.  Worth noting that Menu 23 does also add the Master Magic, Master Summon, Master Command, and Bahamut Zero materia to your inventory - but before it removes the mastered materias :P Which is backwards and leads to the issue of losing all your mastered materias for nothing if your inventory is full.

An issue I have fixed with additional check.
« Last Edit: 2016-08-24 09:06:44 by DLPB »

DLPB_

  • Banned
  • *
  • Posts: 11006
    • View Profile
Re: [FF7PC/PSX] Field Editor - Makou Reactor (1.7.1)
« Reply #691 on: 2016-09-14 21:03:47 »
I've decided to try and work out what the unknown akao operations are by just forcing the function to be called in assembly.  The latest confirmed is operation 0x10.  It is a "Play music" operation. You don't need music to be set for a field in order to play music. Operation 0x10 takes the first parameter as the music ID (which is -1 compared to the field music IDs... because there isn't two "none". In other words, "Farm Boy" is ID 0x20 (32) and not 0x21 (33). )

If you search function call 00740D80 you'll see that this is akao (and you'll see that there are a lot of calls made to akao from hard code - including the Game Over music volume set). It is fed in 9 parameters.  If the desired music is already playing, no change will be made.

The music play is especially important to begin the credit music at game end (as well as other musics that have to be set, like the opening credits).  You can see this at 7A79B2.

The world map music is set at 75e61a. You can see it pulls the ID from a table (the Great Crater music, the 2nd world map music - post Meteor - is at 96D5A0).

0x10, 0x14: Play music assigned at parameter 1. Both of these are exactly the same operation.
0x18, 0x19: Play music assigned at parameter 1, but resume if previously played (if the music has been played before, carry on from last point). This will work even if the module changes from field to world map (and is probably remembered regardless of module). 0x18 and 0x19 are exactly the same operation, so just make Makou have one operation, rather than two.

The world map music uses 0x18, because it has to resume.

0x00 to 0x0F don't exist. The funtion actually deducts 16 (0x10) from the first parameter immediately :P So basically, 0x10 is the first ID that can be used.

Also, the main operation to be carried out occurs at 740DB9. From that you can also see which operations are just calling the same part.

Confirmed as doing nothing (function jumps to end). These can safely be removed from Makou Reactor:

0x11, 0x12, 0x13, 0x16, 0x17,  1A - 1F, 2C -  2F, 31 - 97, 9E - 9F, BE - BF, C3 - C7, CB-D3 - EF, F2 - FF.

Additionally, these are all the duplicates:

0x10 is the same as 0x14  [Note - this is also what "Play Music" Opcode F0 does. It just calls akao with this operation].
18 is the same as  19
20 is the same as 24
21 is the same as 25
22 is the same as 26
23 is the same as 27

I have checked these against the wiki.

On the wiki it doesn't show 0x30 as used - but it is.
0x30 plays a sound effect - but always centred panning. It takes parameter 1 as the effect ID (whereas 0x28 - 0x2B use the first parameter as the left / right balance, and the 2nd parameter as the effect).  It does not appear to be using Channel 1 - 4, which means this could be considered channel 5? It should be noted that there appears to be no way to stop this effect once it has started. You can change to another effect, but effect #0 will not silence it.  My guess is that 0x30 is meant to be used when you have an ambient sound effect in the background that isn't ever meant to be terminated.  Leaving the field module will terminate it, same as any other effect.

0x20: Play a sound effect (will be terminated if another effect is played on channel 1-4) [param1=Panning, param2=Effect ID]

This *seems* to be the same as 0x28 with one major difference: If any other sound effect is played from Channel 1-4, the sound effect playing from 0x20 will be terminated. So this one, as far as I can see, is simply a "play effect - but terminate if ANY other effect is played". However, 0x30 will not affect this.

0x21 - 0x23 do the exact same thing as 0x20, except they take in additional parameters. What these parameters do, I don't know. I can't get anything to sound different by using them. They may be broken on PC - or simply serve no function.

0xC8, 0xC9, 0xCA have been completely removed from PC version, but are still needed in Makou as per PSX game.


http://wiki.qhimm.com/view/FF7/Field/Script/Opcodes/F2_AKAO

I have updated the Wiki.

Finally: 0x15.  Not sure what this does.  But at 740E49 it is jumping to Aali's driver. So he'd have more idea. It does not take any parameters.
« Last Edit: 2016-09-15 12:50:28 by DLPB »

DLPB_

  • Banned
  • *
  • Posts: 11006
    • View Profile
Re: [FF7PC/PSX] Field Editor - Makou Reactor (1.7.1)
« Reply #692 on: 2016-09-24 13:01:16 »
Request:

When scripts change or are deleted, Makou defaults to a script that exists. This makes debugging very difficult and leads to issues.  If a called script no longer exists, it should stop Makou from saving and warn user.

This should also be the case when a script is called but is totally empty (i.e., no ret).

pating

  • *
  • Posts: 33
    • View Profile
Re: [FF7PC/PSX] Field Editor - Makou Reactor (1.7.1)
« Reply #693 on: 2016-09-24 14:21:18 »
I know, I might be wrong in doing this . But is there something that completely fix the bugs in FFVII in the PSX versions? Because I only saw one which is the Mdef thingy. And I already got it. I currently thinking if first with your help guys we might able to fix all the PSX versions bugs and then go with the retranslations and anything. Sorry if I interrupted anything here in the post. I admit when I saw the list of bug fixes in here I felt a little bit unsatisfied because well like you guys I believe Final Fantasy VII is a great game to play.

DLPB_

  • Banned
  • *
  • Posts: 11006
    • View Profile
Re: [FF7PC/PSX] Field Editor - Makou Reactor (1.7.1)
« Reply #694 on: 2016-09-26 03:27:22 »
See The Reunion thread.

in other news, something interesting I spotted.  If you remove the return from the contact script (and all other code), the talk script becomes a contact script instead. So far I have spotted this used on  nivl_b1.

DLPB_

  • Banned
  • *
  • Posts: 11006
    • View Profile
Re: [FF7PC/PSX] Field Editor - Makou Reactor (1.7.1)
« Reply #695 on: 2016-10-05 04:58:31 »
Opcode CA - Party Change.

Currently you have 254 and 255 as "Empty" - but this isn't true.

254 empties the slot, but 255 simply moves the other character that is currently in the party. So "Ignore" is probably a better description for 255.

myst6re

  • *
  • Posts: 648
  • Light King of the Savegame - Field Master - FF8.fr
    • View Profile
    • FF8.fr
Re: [FF7PC/PSX] Field Editor - Makou Reactor (1.7.1)
« Reply #696 on: 2016-10-12 19:29:20 »
Wow thanks DLPB for these contributions!

Request:

When scripts change or are deleted, Makou defaults to a script that exists. This makes debugging very difficult and leads to issues.  If a called script no longer exists, it should stop Makou from saving and warn user.

This should also be the case when a script is called but is totally empty (i.e., no ret).

There is no way to delete a script, so I assume you mean group script?
Yeah when a group script is removed, I update opcodes with greater group ID, but I don't warn user about opcodes that still reference the deleted group.
This is the same mechanism as when a text or a akao/tutorial is deleted.

Also warn the user about completely empty scripts is a good idea, but I remember that somewhere in the original game data there is at least one reference to an empty script, and that's not really an issue.

DLPB_

  • Banned
  • *
  • Posts: 11006
    • View Profile
Re: [FF7PC/PSX] Field Editor - Makou Reactor (1.7.1)
« Reply #697 on: 2016-10-12 20:23:24 »
I only say warn so that the user knows they've made a change they potentially did not want.  It's true that scripts are ignored if empty.

DLPB_

  • Banned
  • *
  • Posts: 11006
    • View Profile
Re: [FF7PC/PSX] Field Editor - Makou Reactor (1.7.1)
« Reply #698 on: 2016-10-18 09:25:35 »
https://s3.postimg.org/7m7t628oz/untitled99.jpg

When optimizing code (from if then statements) Makou gets confused where to branch and this happens.  If it can't be worked around in a good way, perhaps an option to disable branching - or a new way to do it is needed., At moment I cannot edit further down at all.

genesis063

  • *
  • Posts: 612
  • Self proclaimed number 1 Sephiroth fanboy
    • View Profile
Re: [FF7PC/PSX] Field Editor - Makou Reactor (1.7.1)
« Reply #699 on: 2016-10-23 12:19:36 »
Is it possible to get an export all music option?  Since we know what the battle music is in and how to change it and add it would save a lot of time exporting it all one at a time.