Edit Flags Grid Updated: vertex lighting GLOW

How to create models in XSI and other 3D applications and make them work in Battlefront 1 & 2. Post models, tips for application usage and share anything XSI, 3DMax, SketchUp, etc.

Moderator: Moderators

1st Lieutenant
User avatar
Posts: 420
Joined: Tue Jun 28, 2005 7:38 pm

Edit Flags Grid Updated: vertex lighting GLOW

Postby squipple » Mon May 01, 2006 10:49 pm

Some of you using the XSI Addon have been frustrated with a few items in there not-so-handily labeled, so I took it upon myself to do some testing and formatted a grid of the Render Types, Data0, Data1, and texture fields.

Since the forum doesn't support tables, and that's the best way I can think of to display this, I'll link a table here.

Edit Flags Grid

This grid will be updated as I test and find out more, but I wanted to get this out to you guys so you can start reaping the benefits.

The most exciting part - GLOW!! (you heard me right, Bandu) :D

Image

And of course, had to try it out on my map...a little intense in the pic :)
Image

TUTORIAL
THE ZERO EDITOR LIGHTING METHOD

Note: As/if anyone finds out more information that is not provided here, please let me know so that I can edit this and we can keep all the information in this tutorial.

Although you could conceivably apply edit flags items at any time, it's probably best to make it the last step before exporting your model out of XSI.

Here's a graphic to provide quick overview of the edit flags interface.

Image

PolygonIDs -This will automatically fill in with the polygon ID's you selected AFTER you apply the effect. See the end of this tutorial on how to get back to this dialog box to change your effects.

Emissive Color - As far as I can tell, this has to do with attaching lights to materials. See the BF2_lighting.doc

Cast Shadows - if the object should cast shadows, check this box.

Receive Shadows - if the object should recieve shadows, check this box.

Transparency - 0 sets the polygon to opaque (solid), 1 sets the polygons to use transparency (will use the texture's alpha channel), 2 is untested yet...perhaps additive transparency?

Hard Edged Transparency - (from the docs) Hard edged transparency enables alpha testing and does not write pixels whose alpha is below a certain value.

Render Types - This is the obscure setting that determines what effect is used. See the Edit Flags Grid for a key of what some of these are. The grid will be updated as things are discovered. Some are not as obvious as others, so testing is needed to figure it out.

Data 0, 1 - a variable for the Render Type. The function of this varies from mode to mode. See the Edit Flags Grid for reference.

Texture 1, 2, 3 - The name of a texture (in your msh folder) to be included as a variable for your texture. The function of this also varies between Render Types. See the Edit Flags Grid for reference.

Once you're done modeling and texturing your object, select the polygons that you want to apply the effect to. In this case we'll be applying glow to this object.
Hit 'u' to go into poly select mode and select the polys you'd like to glow.
Go to File -> Pandemic Tools -> Edit Flags.

Image

See the Edit Flags Grid to reference what effect you want. Glow is 11, so I set Render Types to 11.
In this case, Data 0 (I think..still testing :) ) refers to how much flicker the glow has. Set it accordingly.
Also in the case of glow, the Texture 1 field refers to a map for the glow (where it will glow). The lighter parts of the image will glow more intensely than the darker, and the glow color is also dependant on the color of this texture.
I used a 128x128 tga that is just solid white for this example. There's no 'explore' dialog for the texture fields, so you just have to type it in manually.
Once you're done with the settings, hit OK.
If at any time you want to go back and edit the attribute you just set, hit Alt+8 to bring up your explorer, find your object, expand it, and double click MAT_ATRB. If there are more than one polygons with different effects per object, they will be labeled MAT_ATRB1, MAT_ATRB2, etc.
Now, before exporting your model, be sure to get out of polygon mode. Just hit the spacebar to do so.
Once you've got your model into ZeroEditor, you'll notice that the polygons selected for glow are now in black & white. And, to my knowledge, in order for something to glow, it needs a light shining on it, so you’ll see I added a light and directed it at the object.

Image

That’s it! After I munged and brought it into the game, this is the result.

Image

--------------------------------------------

THE VERTEX LIGHTING METHOD

In XSI, texture your object as you normally would. I reccomend using Lord-Bandus method. 8)

Apply a Color At Verticies Map to your model. Property -> Color At Verticies Map

Image

You may apply vertex lighting to your model while viewing the texture mode, but I reccomend changing your view to Constant for better visibility. Swap back n forth between that and texture mode if needed.

Image

You may also apply vertex lighting using the entire model, but for this example, I'm selecting individual polygons and applying lighting to the selection only. As you can see in the image above, I've textured a cube with the default texture and arranged it so one square of the texture is on each polygon division on the front face of the cube. I selected the first polygon (u key) and hit Ctrl+w. This will bring up the Brush properties of the vertex coloring brush. Mess with the size, opacity, hardness, etc if you wish. If you're applying your vertex lighting to a polygon selection, click the Vertex Colors tab and in the selection dropdown, choose Use. Select the color you want to paint with from the pallette. The brighter the color, the brighter the lighting and the brighter the glow.

Image

To paint color (lighting) onto your mesh, press Shift+w, and paint away. Note that you need to paint the verticies. Painting the faces will not produce any results.

You can see in my example image above that I've colored my cube with a nice grayscale from black to white (again, shown in constant mode for greater visibility).

Now, to add glow, it's the same steps.
Select the polygons you wish to apply the glow to (shortcut key u)
File -> Pandemic Tools -> Edit Flags
Choose 11 under Render Type
Adjust Data0 and Data1 for flicker (I think :) )
Select a glow map in the Texture 1 field (in this case I just used a 128x128 white tga to apply glow to the entire surface)
Hit OK.
If at any time you want to go back and edit the attribute you just set, hit Alt+8 to bring up your explorer, find your object, expand it, and double click MAT_ATRB (or MAT_ATRB2, etc).

Be sure to get out of polygon mode before exporting. Just hit the spacebar to do so.

Once exported, and an odf is created, you must also designate this model as vertex lit. To do, create an option file.
Just make a new text file, and name it your msh name and add the extension option. In my case, I exported cube.msh from xsi, so my option file's name would be cube.msh.option.
Pop open the option file and just type "-vertexlighting" (no quotes).

That should be it. Place your model in ZE as normal, munge, and enjoy your vertex-lit object. Here's what my gradient cube looks like (notice I got fireflies to work too 8) ).

Image

Note that there are NO lights in the image above, just the ambient top & bottom colors in ZE
I'm still working on how to adjust the brightness of the glow. It currently seems like the glow just 'turns on' after a certain point. Haven't found a way to fine tune it and tone down the brightness of it. If anyone figures it out, notify me and I'll post an addendum.
Last edited by squipple on Thu May 11, 2006 10:30 pm, edited 5 times in total.

Command Sergeant Major
Posts: 250
Joined: Sat Mar 04, 2006 2:21 am

RE: Edit Flags Grid (that

Postby RAymo » Mon May 01, 2006 11:02 pm

wow, thats awesome. nice finding/experimenting lol

Jedi Admin
User avatar
Posts: 11083
Joined: Wed Sep 07, 2005 11:42 pm
Location: Indiana
Projects :: No Mod project currently.
Games I'm Playing :: Destiny
xbox live or psn: No gamertag set

RE: Edit Flags Grid (that

Postby Teancum » Mon May 01, 2006 11:11 pm

I know the '8' flag will use the texture's alpha channel, allowing for transparency.

Old School Staff
User avatar
Posts: 1176
Joined: Fri Oct 21, 2005 2:33 pm

RE: Edit Flags Grid (that

Postby Epena » Tue May 02, 2006 9:18 am

Omg, yes!

I knew your little experiment would work!

Now to get Bandu to amke those gowing with relics.... :P

Sith
User avatar
Posts: 1278
Joined: Fri Oct 15, 2004 6:34 pm
Location: Germany

RE: Edit Flags Grid (that

Postby Rends » Tue May 02, 2006 4:31 pm

Great finding!

Rends

Old School Staff
User avatar
Posts: 2059
Joined: Wed Feb 23, 2005 9:54 am

RE: Edit Flags Grid (that

Postby Qdin » Tue May 02, 2006 4:47 pm

You're AWESOME!!!!

great job :D

Droid803

RE: Edit Flags Grid (that

Postby Droid803 » Tue May 02, 2006 4:53 pm

AWESOME!
Where would we be with glow...

Jedi
Posts: 1001
Joined: Mon Apr 03, 2006 9:12 pm
Location: plundering yer booty
Projects :: No Mod project currently.
xbox live or psn: No gamertag set

RE: Edit Flags Grid (that

Postby PvtParts » Tue May 02, 2006 9:06 pm

Great find. Im suprised theres not more excitement about this...

Trans

RE: Edit Flags Grid (that

Postby Trans » Tue May 02, 2006 9:09 pm

OMFG This is AWESOME!!!!! any better ;)

This is good news I really need this for the map I am making! :D

pinioncorp

Postby pinioncorp » Tue May 02, 2006 11:06 pm

_____________________________________________________________
¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯


Sweet Jesus Awesome!!!

How do I apply a texture? It only lets you input text, I have no idea what format the text should be. Is it the texture name (as in texture.tga) or is it the property name on the applied texture (which I can't give an example to)? Will you make a detailed tutorial for this?

_____________________________________________________________
¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯

Edit: Question.

SmokeY_Trooper'

Postby SmokeY_Trooper' » Wed May 03, 2006 1:22 pm

Thoes this mean that we can get Bandu to Make his Maps??

sh4d0wl0rd

Postby sh4d0wl0rd » Wed May 03, 2006 1:51 pm

Let's hope he will come back!

Jedi Admin
User avatar
Posts: 11083
Joined: Wed Sep 07, 2005 11:42 pm
Location: Indiana
Projects :: No Mod project currently.
Games I'm Playing :: Destiny
xbox live or psn: No gamertag set

Postby Teancum » Wed May 03, 2006 1:54 pm

What I'm wondering is if the flag is inputted manually into the exporter in XSI or if you hexed this, or used BConstructor.

Old School Staff
User avatar
Posts: 2059
Joined: Wed Feb 23, 2005 9:54 am

Postby Qdin » Wed May 03, 2006 2:10 pm

hmm...

There were a Edit Flag for the SWBF1 Exporter - I installed that one :) then I installed the SWBF2 Exporter, and I now have a SWBF2 Exporter and the Edit Flags option too :)

1st Lieutenant
User avatar
Posts: 420
Joined: Tue Jun 28, 2005 7:38 pm

Postby squipple » Wed May 03, 2006 4:53 pm

Yes, good idea. I'll post a tutorial this evening. This was to get the initial info out to people who were intimately familiar with the issue (Bandu & possibly others). It wasn't hexed, it's just using the edit flags option under the pandemic tools addon menu in XSI. To test, I set up a grid (seen in the first pic) with a different render type on each object to see what they'd do. You can see the one right below the glowing square is a little off compared to the others..because it's scrolling.

EDIT: Tutorial added in first post.

Jedi Admin
User avatar
Posts: 11083
Joined: Wed Sep 07, 2005 11:42 pm
Location: Indiana
Projects :: No Mod project currently.
Games I'm Playing :: Destiny
xbox live or psn: No gamertag set

Postby Teancum » Wed May 03, 2006 8:50 pm

Moved to XSI forum and stickied. Nice work Squip.

Lord-Bandu

Postby Lord-Bandu » Thu May 04, 2006 8:50 am

Great work Squip!

Hopefully we can figure out a way that doesnt involve using ZE lights shining on the object since I dont think the shipped 'glowing objects' did it this way (lights can be quite temperamental) .

It could be something to do with 'vertex lighting' which im not too familiar with.

1st Lieutenant
User avatar
Posts: 420
Joined: Tue Jun 28, 2005 7:38 pm

Postby squipple » Thu May 04, 2006 9:29 am

Yes, lights can be an issue. AFAIK it's because an object is only allowed to be lit by three lights. So if you've got a 'sun' in your world, that's already taking up one, so you don't have much to work with. I'm trying to find out if there's a Render Type for a self-illuminated surface. I may be on to something with types 26-28, but I'm still testing

Sith
User avatar
Posts: 1396
Joined: Tue Jun 07, 2005 11:50 am

Postby JabbaLovesLava » Thu May 04, 2006 6:52 pm

what if you add a light in XSI? It sounds stupid to me... but it could work...

Lord-Bandu

Postby Lord-Bandu » Thu May 04, 2006 7:12 pm

I think thats along the line of vertex lighting.

TBH , I know very little/nothing about VL but I think its basically lighting the actual mesh and not the texture... if you look at the Utapau walkway (the walkway with the red lights) you'l notice the actual texture doesnt have any light on it ...however when you place it in ZE there seems to be a whole in it where the red light appears in game.... this implys something to do with XSI parameters (be it edit flags or materials etc) .

Next

Return to 3D Modeling & Animation

Who is online

Users browsing this forum: No registered users and 1 guest