Home » Fable TLC » Discussion » Graphics Editing » Effects Discussion
Effects Discussion [message #60542] |
Wed, 01 December 2010 06:19 ![Go to next message Go to next message](/forum/theme/default/images/down.png) |
![](http://fabletlcmod.com/forum/images/custom_avatars/3.png) |
Keshire
Messages: 1266 Registered: July 2005
|
Administrator
|
|
|
Tearing myself away from minecraft for a few minutes....
04[05:13] <JohnDoe> Hey Kesh, at your convenience I'd love to see what you've got labeled with those effect structs.
I cleaned up the spec you gave me a bit for ease of reading.
I noticed that the unknowns that range from 0-1000 are percentages. value/10. So 1000 = 100%
The ones I messed with caused the sprite to blur, movexyz, and rotate. Just not sure which ones are which since I didn't have time to single them out.
typedef struct CPSCRenderSprite
{
zstring CPSCRenderSprite;
dword SectionCRC;
ubyte Boolean15;
dword SpriteName;
dword TrailName;
ubyte StartColourBGRA[4];
ubyte MidColourBGRA[4];
ubyte EndColourBGRA[4];
dword SpriteType;
//These dwords are percentages for sprite effects. 0-1000
dword Unknown5;
dword Unknown6;
dword Unknown7;
dword Unknown8;
dword Unknown9;
dword Unknown10;
dword Unknown11;
dword Unknown12;
dword Unknown13;
dword Unknown14;
dword Unknown15;
dword Unknown16;
//Sounds??
dword Unknown17;
dword Unknown18;
dword Unknown19;
dword Unknown20;
dword Unknown21;
dword Unknown22;
ubyte Boolean;
ubyte Boolean;
ubyte Boolean;
ubyte Boolean;
ubyte Boolean;
ubyte Boolean;
ubyte Boolean;
ubyte SectionTerminator1;
}CPSCRenderSprite;
struct CPSCSpline
{
zstring CPSCSpline;
dword CRC2;
ubyte Boolean23;
ubyte Boolean24;
ubyte Boolean25;
float Unknown23;
dword SplineUserPointsArraySize;
float SplineUserPointsArray[SplineUserPointsArraySize*3];
ubyte Boolean26;
ubyte UseSplinePoints; //Not sure
ubyte Boolean28;
dword SplineConnectedEndPoints;
dword CRC[SplineConnectedEndPoints];
ubyte SectionTerminator2;
}CPSCSpline;
struct CPSCEmitterGeneric
{
zstring CPSCEmitterGeneric;
dword CRC;
ubyte Boolean29;
dword CRC; //Emitter Type
dword Unknown25;
dword Unknown26;
dword Unknown27;
dword Unknown28;
ubyte Boolean30;
ubyte Boolean31;
ubyte Boolean32;
ubyte Boolean33;
ubyte Boolean34;
ubyte Boolean35;
ubyte Boolean36;
ubyte Boolean37;
ubyte Boolean38;
ubyte Boolean39;
dword Unknown29;
dword Unknown30;
dword Unknown31;
dword Unknown32;
dword Unknown33;
dword Unknown34;
ubyte Boolean40;
ubyte Boolean41;
dword Unknown35;
dword Unknown36;
dword Unknown37;
ubyte Boolean42;
dword Unknown38;
dword Unknown39;
dword Unknown40;
dword Unknown41;
dword Unknown42;
dword Unknown43;
ubyte Boolean43;
switch(Boolean43)
{
case 1:
float Unknown44;
dword UnknownCount2;
dword Unknown45[UnknownCount2*3];
break;
default:
break;
};
ubyte SectionTerminator3;
}CPSCEmitterGeneric;
struct CPSCUpdateNormal
{
zstring CPSCUpdateNormal;
dword CRC4;
ubyte Boolean44;
dword Unknown46;
dword Unknown47;
ubyte Boolean45;
ubyte Boolean46;
ubyte Boolean47;
ubyte Boolean48;
ubyte Boolean49;
ubyte Boolean50;
ubyte Boolean51;
ubyte Boolean52;
ubyte Boolean53;
ubyte Boolean54;
ubyte Boolean55;
ubyte Boolean56;
ubyte Boolean57;
ubyte Boolean58;
ubyte Boolean59;
ubyte Boolean60;
ubyte Boolean61;
ubyte Boolean62;
ubyte Boolean63;
float Unknown48;
float Unknown49;
float Unknown50;
float Unknown51;
float Unknown52;
float Unknown53;
float Unknown54;
float Unknown55;
float Unknown56;
float Unknown57;
float Unknown58;
float Unknown59;
float Unknown60;
float Unknown61;
float Unknown62;
float Unknown63;
float Unknown64;
float Unknown65;
float Unknown66;
float Unknown67;
float Unknown68;
float Unknown69;
float Unknown70;
float Unknown71;
float Unknown72;
float Unknown73;
float Unknown74;
float Unknown75;
float Unknown76;
float Unknown77;
float Unknown78;
float Unknown79;
ubyte SectionTerminator4;
ubyte EffectsTerminator;
}CPSCUpdateNormal;
//32bit switch is BROKEN!!
typedef struct Section
{
//zstring SectionName;
dword SectionCRC;
switch (SectionCRC)
{
case 2362561053:
CPSCRenderSprite CPSC;
break;
default:
break;
};
}Section;
struct header
{
dword Unknown1;
zstring EffectName;
ubyte Booleans[7];
float Floats[3];
dword Unknown2;
dword Unknown3;
dword Unknown4;
ubyte Booleans[5];
dword effectcount;
}header;
struct effect
{
zstring EffectName;
ubyte Booleans[2];
float ScaleXYZ[3];
dword SectionCount;
}effect;
Apathy Cannot Inspire.
Ambivalence cannot lead.
Loved me. Feared me.
Changed me. Killed me.
Anything would be something.
But nothing is worst of all.
[Updated on: Wed, 01 December 2010 06:22] Report message to a moderator
|
|
|
Re: Effects Discussion [message #60544 is a reply to message #60542] |
Wed, 01 December 2010 11:01 ![Go to previous message Go to previous message](/forum/theme/default/images/up.png) ![Go to next message Go to next message](/forum/theme/default/images/down.png) |
![](http://fabletlcmod.com/forum/images/custom_avatars/3276.png) |
JohnDoe
Messages: 3007 Registered: October 2007
|
Retired
|
|
|
I've dicked around with the effects a few times in the past and I'm kicking myself now for not documenting anything.
The only thing I did hold on to was a slimmed-down effect (attached) that includes just the essentials for flourish/multistrike/augment-type effects, I nulled out everything I could null out and still have the effect work. All of the booleans that are switched on are necessary to keep the effect working, at least one of them keeps it permanent (as opposed to augment effects, which die out), not sure which one. At least one of the booleans that are switched off must remain switched off, and again I have no idea which. I don't even know why it has to be switched off.
Usage note.And the problem with implementing this one as an augment effect results in it compounding with each swing of the weapon because the effect doesn't die like augment effects are supposed to, resulting in lag. It was meant to be implemented directly on the mesh and using the CTCMeshAutomaticEntityCreator in the definitions to make it work, keeps the effect from going away when being swung.
The slimmed effect will be useful when noting boolean differences between it and similar type effects. I'll have a lot of free time in a day or two, I can take some time to figure out some stuff. If nothing else I'll at least waste a few hours cursing Lionhead, BreakPoint, etc., the usual.
-
Attachment: BAREBONES
(Size: 0.59KB, Downloaded 605 times)
[Updated on: Wed, 01 December 2010 11:31] Report message to a moderator
|
|
|
|
|
Re: Effects Discussion [message #60572 is a reply to message #60571] |
Thu, 02 December 2010 06:05 ![Go to previous message Go to previous message](/forum/theme/default/images/up.png) |
![](http://fabletlcmod.com/forum/images/custom_avatars/3276.png) |
JohnDoe
Messages: 3007 Registered: October 2007
|
Retired
|
|
|
Keshire wrote on Thu, 02 December 2010 07:24 | More efficient until you come up on an effect that has a shitload of sections in it. And like five or six effect stages. ![Razz](images/smiley_icons/icon_razz.gif)
| Ah, very good point. So far I've only used it on that barebones effect, which is too simple to appreciate the organization.
Edit: Just going to collect my findings here.
Dwords.
CPSCRenderSprite
Unknown6 0x00 may be a boolean. Unknown6 0x00 looks to deal with how the effect determines alpha. 00 = black is alpha; 01 = black is black. But using other values makes it appear as normal. The following 3 bytes appear to have no effect on this either way.
Unknown8 determines distance from the spline where the effect will revolve around the spline based on the camera angle. Think of a barber pole, value determines radius of the red stripes.
Unknown9 affects strength of the sprite. Higher values = smaller sprite. Alpha intensity? Attenuation?
Unknown10 appears to be the opposite of Unknown9. Higher values = more opaque sprite.
Unknown15 affects size. I recommend values under 1000.
Unknown17 also affects size, but differently. Will have to investigate unknowns 14-18 to find exact relations between the values.
Unknowns 5, 7, 11, 12, 13, 14, 16, 18, 19, 20, 21 and 22 produced no noticeable effect at first glance.
Boolean Crash Tests
Using the posted structs.
Entry
Boolean01: 00 = Normal; 01 = kills effect.
Boolean02: 00 = Normal; 01 = Only appears in background, pic.
Boolean03: ?
Boolean04: 00 = Black is alpha; 01 = Black is black.
Boolean05: ?
Boolean06: 00 = Normal; 01 = kills effect.
Boolean07: 00 = Always appears in foreground; 01 = normal, pic.
Boolean08: ?
Boolean09: ?
Boolean10: ?
Boolean11: ?
Boolean12: ?
Effect
Boolean13: 00 = Kills effect; 01 = normal.
Boolean14: ?
CPSCRenderSprite
Boolean15: ?
Boolean16: ?
Boolean17: ?
Boolean18: ?
Boolean19: ?
Boolean20: 00 = Normal; 01 = kills glow around sprites.
Boolean21: 00 = Normal; 01 = randomly twinkles/sparkles, pic.
Boolean22: ?
CPSCSpline
Boolean23: ?
Boolean24: 00 = Normal; 01 = kills refresh, pics: start, mid, end.
Boolean25: ?
Boolean26: 00 = Normal; 01 = Crash.
Boolean27: 00 = Crash; 01 = Normal.
Boolean28: ?
CPSCEmitterGeneric
Boolean29: ?
Boolean30: ?
Boolean31: 00 = Normal; 01 = Kills sprite refresh, pic, then fades away.
Boolean32: ?
Boolean33: ?
Boolean34: ?
Boolean35: ?
Boolean36: ?
Boolean37: ?
Boolean38: ?
Boolean39: ?
Boolean40: ?
Boolean41: ?
Boolean42: ?
Boolean43: 00 = Crash; 01 = Normal.
CPSCUpdateNormal
Boolean44: ?
Boolean45: ?
Boolean46: ?
Boolean47: 00 = Normal; 01 = Smooths/rounds the sprite.
Boolean48: ?
Boolean49: 00 = Sprites stay where they are generated, pic; 01 = Sprites stay where they are generated relative to the effect origin (normal).
Boolean50: 00 = Normal; 01 = kills effect.
Boolean51: ?
Boolean52: ?
Boolean53: ?
Boolean54: ?
Boolean55: ?
Boolean56: ?
Boolean57: ?
Boolean58: ?
Boolean59: ?
Boolean60: ?
Boolean61: ?
Boolean62: ?
Boolean63: 00 = Normal; 01 = Strobe/pulse flow, pic.
Because I suck at testing, I missed at least three things. Somewhere in bools 3, 5, 8-12, 14-19, 22-23, 25, 28-30, 32-42, 44-46, 48, and 51-62, something controls whether or not the effect eventually dies out, something acts similarly to bool 49 (maybe 48?), and something affects brightness/intensity. When all of these are 00, the changes are noticeable. When all of these are 01, everything appears as normal.
Stuff to look for.
I've screwed with the effects before, so there are a few things I know can happen. My barebones effect won't do it, but there exists a way to make the effect interact with the landscape (elongated effect 158), so that it will not go through the ground. And augment effects twirl about in various directions, while my barebones effect only renders the sprite facing directly at the camera. Something makes that happen, just need to find out what.
Update: Just remembered (because I'm absent-minded and have a ten-second short term memory) that there are some variable names in the wiki. I don't know if they're complete, but they'll help me label some of these things.
Apologies for the night shots, I made the assumption it would be easier to notice changes in the effects, but it's hard on the eyes. Also, more apologies for having my WIP costume in the pics, I keep forgetting to remove it when testing. Should probably just make it so it doesn't spawn with the Hero.
[Updated on: Thu, 02 December 2010 16:46] Report message to a moderator
|
|
|
Goto Forum:
Current Time: Mon Feb 17 02:05:48 PST 2025
Total time taken to generate the page: 0.05761 seconds
|