Author Topic: A question  (Read 4934 times)

Anonymous

  • Guest
A question
« on: 2001-05-18 03:56:00 »
is anyone working on a way to edit the places you can walk in? Its probably somewhere in flevel.lgp. And i dont think it would be that hard to do..... Its probably just coordinates of vertecies and what vertecies are connected. and what polygons you cant walk get into. or something like that.

The SaiNt

  • *
  • Posts: 1300
    • View Profile
A question
« Reply #1 on: 2001-05-18 05:46:00 »
It could be a single byte value for each tile in the field files or something else.  :)

A question
« Reply #2 on: 2001-05-18 22:23:00 »
From what we've learned from Halkun, that's more or less essentially correct.
IIRC, there's 2 separate plains, the foreground that the 3D models walk on, and the background that the models walk in front and behind of.

halkun

  • Global moderator
  • *
  • Posts: 2097
  • NicoNico :)
    • View Profile
    • Q-Gears Homepage
A question
« Reply #3 on: 2001-05-20 01:22:00 »
Kind of, there are *three* plains in that sense, but one in't really a plain at all

I guess I better name them. They are the root plain, the overlay plain and the poly plain.

The root plain is the background, but where the character can walk "behind" an object, a color mask is applied.

The overlay plain is placed over the color mask so it overwrites cloud when he's "behind" something.

The ploy plain is an invisible 3d "road" that cloud walks on and is used for placement calculations.

Let me expand a bit. then I really, really, have to go to bed.

Let us say that cloud is in a square room with a piller in the middle. We are looking into the room from above at an angle so cloud has the ability to walk "behind" the piller.

First let's define the poly plain. This is just the floor where cloud can walk. If we were to make it visable we would see a square with a hole in the center. When the field is loaded into memory it takes that poly plain and moves the camera into the correct angle so that the invisable poly plain matches the root plain's floor. Cloud can walk anywhere in the square, but if he's placed into a "null spot", like the hole in the center where there is no road, he will get stuck and only be able to spin around when you move him.  Now where the piller is supposed to go we will put a bright pink color mask (this is still on the root plain) and then the overly plain goes ontop with the piller grpahic.

So let's step through how cloud wallks "behind" the piller.

The model of cloud "knows" the invisable poly plain is there, even though we don't see it. when we walk cloud around to behind the piller. the engine loop does this.

First it draws the root plain. Then caluclates clouds postion in 3d place using the poly plain. Then they render cloud. Then they put the overlay plain ontop of the root plain and then blit finished render to the display. If cloud is behind the piller he will be painted over by the piller graphic. that's how the clipping is done.

One last thing. If a character walks up or down a flight of stairs. He's actully walking up/down a ramp in the poly plain. No reason to put stairs there if all he needs to do is go up at an angle. Ladders, are walls though ^_^

I hope I didn't thoughly confuse you all.

[This message has been edited by halkun (edited May 20, 2001).]

[This message has been edited by halkun (edited May 20, 2001).]

[This message has been edited by halkun (edited May 20, 2001).]


A question
« Reply #4 on: 2001-05-25 00:31:00 »
Ah, I get it now. Thanks for the info.

This information has been assimilated into the tech doc. Have a nice day.  :wink:


Anonymous

  • Guest
A question
« Reply #5 on: 2001-05-25 02:54:00 »
Aight.....is anyone working on how to edit the poly level?

Fice.....any progress on being able to edit the things beside the palette? If not, is there anything i can do to help? I only know vb......but maybe i can make a conversion/editor program if someone can supply me infomation about those layers.


ficedula

  • *
  • Posts: 2178
    • View Profile
    • http://www.ficedula.co.uk
A question
« Reply #6 on: 2001-05-25 03:39:00 »
Sorry, no progress. Partly that's due to the fact I've been at home (ie. not at my PC) for the past week, plus I have exams coming up (these ones are important; they determine whether I get to do another year at uni...) So I simply haven't been able to work much on my FF7 programs.

That said, I have got one or two ideas on *how* to implement proper FF7 background editing. I don't know whether any of them would work or not, but it's not like I'm at a dead end.

I will have *some* time for my programs now I'm back at my PC; there's no way in hell I'm going to revise all day! But obviously it isn't going to be as much as when I didn't have exams.

How much do you guys know about the background format? I mean, mine and Qhimm's source is already available (and has been for a while), but would it help if I wrote another one of my famous (ha) documents explaining it in more detail? I could do that, it's not like it'd take an enormous amount of time.


A question
« Reply #7 on: 2001-06-02 05:32:00 »
Here's the information I currently have in the tech doc:
The backgrounds have been matched to the 9th block (assuming we're calling the first block #1) of the field file (which is started by the word "Texture"). The Pallet can be found in block 4 (started by the word "Pallet") They have been mostly decoded, but things get kind of complicated. Their structure is as follows:
The original backgrounds were rendered in Lightwave. Then, the background files were taken and cut up into smaller 8x8 files. These smaller files are divided into two layers of 128x128 square blocks. One of these layers is the surface (what the field models walk on) and the other is the rest of the scene (what the characters walk in front of). The backgrounds are sprite based and have multiple layers (so models can walk behind things).
Each of the backgrounds is made of 128x128 bitmap that has all of the sprites (8x8 with 16 in each row) and a sprite map (tells where each sprite goes). It is possible for multiple sprites to use the same coordinates, which, in turn, allows for layers and animation. The sprites seem to be defined like this:
# %d: x %d, y%d, u%d, v%d, clut%d Depth % ',0Ah,0
While this isn't confirmed, this probably means that the sprites are defined in:
X-coordinates (decimal)
Y-coordinates (decimal)
Depth(Z)-coordinate (decimal).
Apparently, certain backgrounds have to have their layers rendered differently. The problem is that, unlike most of FF7's backgrounds, they have a foreground
and background that can "float" (to give the appearance of distance). Most of the backgrounds don't need/have this, and, instead, the background and the part of the picture that obscures 3D models (to show they're walking behind it) are non-floating.

Combine this with Halkun's info above, and that sums up about all I/we currently know. Ficedula, if you know more, I'd welcome another one of your documents.  :D


ficedula

  • *
  • Posts: 2178
    • View Profile
    • http://www.ficedula.co.uk
A question
« Reply #8 on: 2001-06-02 06:14:00 »
I'm not sure how much that meshes with my understanding of the background. I'll compare it to what I know when I have time: exams start in half a week, so revision is now becoming a full-time activity, damn it.

halkun

  • Global moderator
  • *
  • Posts: 2097
  • NicoNico :)
    • View Profile
    • Q-Gears Homepage
A question
« Reply #9 on: 2001-06-03 12:34:00 »
I have an update. It's about the color mask behind the background. Turns out that's not a color mask as I thought but light source. Let my try and explain this one. I'm going to use a real example here. It's the scene right after the train at the way beginning of the game. It's the field file where you first meet jessie, biggs and wedge, put in your name and barettes name.

Now for those playing along, when you first enter the scene there is a street lamp near the bottom. Cloud can walk behind that. Now The "color mask" for this field file is bright green. that gets layed down first, then the root plain. Now, the root plane has semi-trasparent "holes" that allow lights and other doodads to "shine through". The polygons are then rendered and placed on the root plane. Then the overlay plain is placed on top of that. That also has semi-trasparent "holes" (like the streetlamp) To have the green color "shine through" That's how lighting is done. I hope this helps out.