Possible to change menue color? (and more ...)
#9

Hi all,
Fly_zo has shared his GUI templates, and i've been playin' around with them, and the mysterious .SFS & .mat files. I'm a raw beginner at hacking (...errr... "modding") IL-2, so ...
I've wondered where the texture on the GUI panel came from (the cross-hatchy thing that is either trying to be "wrinkle paint", or I don't know what..), since it wasn't in any of fly_zo's GUI mod files. Digging through the .SFS files, i noticed a 128x128 texture file, "detail.tga", which looked just about right. I've loaded it in Photoshop, scribbled a black line on it, saved it in the mods/fly-zo's gui mod/gui/game folder, along with it's .mat, and, sure enough, it showed up. Increased the size to 256, worked. 512 worked (now we're getting somewhere). 1024 worked! Color? Not quite. Bummer (though you can tint it with the .mat file).
Aynyhow, the panel can have a B&W graphic on it (see screen shots below). This is not a polished GUI, the choice of graphics & blatant plagiarization of fly-zo's buttons & all, but a "proof of concept", as self-important folks call half-finished projects. There's also the associated .mat file below, with some stuff i managed to learn by trial & error. Any help on .mat & .SFS files would be awesome.
-d.
[Image: 00.jpg]
(had to use my hotmail photos thingy - for the first time in my life, *no server*.)
This is it - you can see the screenshot used for the panel background, with fly_zo's bttons (slightly modified & sitting in those annoying brit-style slot-nuts (ala early marshall, sound-shitty, vox etc. - the kind you have to take off with sharpened needle-nosed pliers, since you're too cheap to buy the slot-ring tool). They are very British, though, which is neither here nor there...
[Image: 000.jpg]
This is kind'a of a problem - by default, the GUI *tiles* the texture (if you're old enough to remember early windows wallpaper, it was all "tiled", to save the precious ram). Tiling bites, but could be disabled in the .mat file, which makes the thing "pull" the last (right-most) row of pixels. Not too much of a problem, though, 'coz you can either vignette the picture, leaving the right row black (smooth transition), or simply draw a color (shade of gray?) line at the right edge.
[Image: 0000.jpg]
The pain o making mats is ... You can never see them, unless you go out of your way to shove things on the *very* edge. If someone could tell me how to work on meshes & where they live, I'd love to make over the menu from scratch. Anyhow, here's the .mat file:

//********************************************************************************************
//---------------------- detail.mat, and what i got from it by trial & error... ------------*
// The "//" are, obviously, comment tags, so stuff which follows after them is ignored by *
// whatever mysterious java thingy parses these files... *
// If anyone could point me to *real* info on .mat files, i'd be grateful. This is what *
// i've got so far: *
//********************************************************************************************

[ClassInfo]
ClassName TMaterial
[Layer0]
TextureName detail.tga
// ColorScale 0.0 0.0 0.0 0.0
ColorScale 0.0 0.0 0.0 0.99 //was 15. The last 2 digits are mask (or layer) "hardness",
// - 0 being transparent, 99 being full-on. 2 digits only. The other number pairs,
// AFAIK, are RGB color values, but not 0-256.
tfModulate 0 // was 1. 1 seems to act as a mask, 0 as a transparent layer. If set to 1,
// detail.tga shows up as a negative.
tfNoWriteZ 1 // ?????????
tfNoDegradation 0 //?????????
tfMinLinear 0 //?????????
tfMagLinear 1 //?????????
tfBlend 1 //binary, 1=blend, 0=noblend
// tfNoCompressARB 1 ??????????????????
tfWrapX 0 //1 repeats (tiles), 0 "drags" (repeating the last pixel row). Same below.
tfWrapY 0

[fbv200]

Hope this is of interest to someone.
-d
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 8 Guest(s)