-
Notifications
You must be signed in to change notification settings - Fork 0
6.2. LSFX Effect Components
- Effect Components Defined
- Duration
- Effect Components
- Bounding
- Light
- Post Processing
- Camera Shake
- Force Effects
- Particle System
- Model
- Decal
- Overlay Material
- BillBoard
- Sound
Here we will talk about all of the important data blocks you'll find in the LSFX
file. Later, we'll go in-depth on the contents of the blocks.
This is usually the first thing you'll see just before the EffectComponents
. This determines the total length of the entire file. As in, this should generally match, or exceed the max time of the longest EffectComponent
.
The Effect Components are all the individual effect pieces that make up a an individual visual effect file. You can find various types of Effect Components, which we will now discuss.
As of right now, the
ID
uuid Attribute seems to be irrelevant. Personally, I make sure to change these just in case a future update might change that, but you can have duplicates even if they are not related, and your effect will still work.
Usually, the first EffectComponent
you'll likely find in any LSFX Files, is the Bounding Sphere
or Bounding Box
. This is the core, or catalyst of the whole file. Without it, all you will see, again, is
Inside, you'll find a few properties, such as:
<node id="EffectComponent">
<attribute id="EndTime" type="float" value="6" />
<attribute id="ID" type="guid" value="a0f8cf27-d487-42cc-a074-0793c92ab581" />
<attribute id="Name" type="LSString" value="BoundingSphere" />
<attribute id="StartTime" type="float" value="0" />
<attribute id="Track" type="uint32" value="4" />
<attribute id="Type" type="LSString" value="BoundingSphere" />
<children>
<node id="Properties">
<children>
<node id="Property">
<attribute id="AttributeName" type="FixedString" value="Name" />
<attribute id="FullName" type="FixedString" value="Name" />
<attribute id="Type" type="uint8" value="7" />
<attribute id="Value" type="LSString" value="BoundingSphere" />
</node>
<node id="Property">
<attribute id="AttributeName" type="FixedString" value="Position" />
<attribute id="FullName" type="FixedString" value="Center" />
<attribute id="Type" type="uint8" value="8" />
<attribute id="Value" type="fvec3" value="0 4 0" />
</node>
<node id="Property">
<attribute id="AttributeName" type="FixedString" value="Radius" />
<attribute id="FullName" type="FixedString" value="Radius" />
<attribute id="Type" type="uint8" value="4" />
<attribute id="Value" type="float" value="5" />
</node>
<node id="Property">
<attribute id="AttributeName" type="FixedString" value="Visible" />
<attribute id="FullName" type="FixedString" value="Visible" />
<attribute id="Type" type="uint8" value="0" />
<attribute id="Value" type="bool" value="False" />
</node>
</children>
</node>
</children>
</node>
This defines where the Bounding type is relevant to the effect
This defines the size.
For the Bounding element. You will find these two in every EffectComponent
. Although, subsequent EffectComponents
Time attributes will vary, the Bounding Element will always have a StartTime
of 0, and an EndTime
at or very near the total Duration
.
The difference between the two is only relevant to the type of spell.
In the Bounding Box, instead of Radius, you'll find a an attribute id that sets the bounds, quite similar to what you see in the Merged. This is usually for large, generally forward casting AoE effects, like Lightning Bolt, Sun Beam, and Gust of Wind.
In most cases, your .lsfx
file will probably have a Bounding Sphere instead, even if it's just a single target spell effect.
On some, but not all effects, they will have an EffectComponent
. This is is exactly what it sounds like, a light effect. Like most nodes, you can change the Color, Brightness, Opacity and such. We'll discuss more about editing these nodes in the Particle System Topic.
There are a few types of these. such as Screen Darkening, Radial Blur and what not. They are, in effect, your screen effects, or Spell Effect reshades for their duration of their Start to End times.
This does exactly that, simulates camera shaking to the degree defined in the properties.
These are things like your Gravity Force
, Wind Force
, Radial Force
, and so forth. There are a number of these, and they each do pretty much what you would expect. One important thing to note however, that if a particle's movement properties, such as Initial Velocity
don't roughly match up with the force effect, they will be unaffected by the Force System. There are three important Property
ids within the Force Systems that you'll want to edit if you want your effects to move in a direction of your choice. All 3 Effects work in tandem with each other.
The First is Position
. This of course says where the Force source is. If you want a particle to travel up in relation to, say, gravity, you'll want the Position
to be below the particle.
<node id="Property">
<attribute id="AttributeName" type="FixedString" value="Position" />
<attribute id="FullName" type="FixedString" value="Offset" />
<attribute id="Type" type="uint8" value="8" />
<attribute id="Value" type="fvec3" value="0 0 0" />
</node>
The second is Acceleration
. This affects how quickly the Force affects the EffectComponent
. So, if you have a WindForce
that is really high, your EffectComponent
, if set up properly, will blow in the wind at a fast rate. As you can see in the example, the EffectComponent
would actually move quite slowly.
<node id="Property">
<attribute id="AttributeName" type="FixedString" value="Acceleration" />
<attribute id="FullName" type="FixedString" value="Behavior.Acceleration" />
<attribute id="Type" type="uint8" value="6" />
<children>
<node id="Frames">
<attribute id="FrameType" type="uint8" value="0" />
<children>
<node id="Frame">
<attribute id="Time" type="float" value="0" />
<attribute id="Value" type="float" value="0.05" />
</node>
<node id="Frame">
<attribute id="Time" type="float" value="1" />
<attribute id="Value" type="float" value="0.05" />
</node>
</children>
</node>
</children>
</node>
And the Last one is Direction
. This, paired with the Position
and Acceleration
tells the EffectComponent
what direction the Force applied wants it to go. In the example provided, that direction would be straight up.
<node id="Property">
<attribute id="AttributeName" type="FixedString" value="Direction" />
<attribute id="FullName" type="FixedString" value="Behavior.Direction" />
<attribute id="Type" type="uint8" value="8" />
<attribute id="Value" type="fvec3" value="0 1 0" />
</node>
This affects the gravity of an EffectComponent
. This is usually used if you want a particle to travel up or down from the EffectComponent
spawn point.
This affects the particle by having it spin on a singular axis. For example, if your effect has falling leaves, and you want those leaves to spin as they fall, like in real life, this is the effect you'd use.
This Force system handles two jobs at once. The first, it affects EffectComponents
on whether they move towards or away from their spawn location. The second, on a lighter scale, affects the component spinning around the source.
Similar to Vortex Force's second effect, but to a stronger degree. More often than not, when an effect involves swirling around a source or target, this Force System is what causes that. Combining VortexForce
, RadialForce
and GravityForce
with the right particles and settings, and you can make yourself a fancy tornado.
This affects EffectComponents
similarly to Gravity, only on more of a horizontal axis than vertical. The design is simple, as it's meant to simulate wind.
This Force system affects the vibration or bounciness of a particle in motion.
This is the most common EffectComponent
and the ones you'll probably be messing around with the most. These are your sparks, flames, flashes, lens flares, fog, and so forth. Like other EffectComponents
such as Model
, BillBoard
, and Light
, you can find various properties you can edit to attempt to achieve the most optimal effect you're aiming for.
These are static effects. More often than not, they won't be too affected by changes made just inside the LSFX, and require a different method of model editing, similar to creating new weapons, armor, and custom race appearances.
This functions like a sticker. More often than not, you'll see this used to create temporary effects on the ground, to simulate varying types of impact, such as scorching or a crater impact.
This is an effect that overlays what it is defined in the properties. Aside from the standard properties like Color, Brightness and Alpha, this particular EffectComponent also has Apply properties. These do precisely what they state in the name, such as Apply to Weapon
, Apply to Armor
, Apply to Body
and many more. I encourage you to play around with these true/false values to achieve your desired effects.
This particular Component tends to be a background effect meant to accentuate or enhance the overall effects in the LSFX
.
This does exactly what it says, and uses UUIDs found from the Sound Merged Files.
- Overview
- Sample Projects
- Action Resources
- Spells
- Passives
- Statuses
- Items
- Races
- Classes
- Scripts
- Visual Resources
Setting up a Development Environment (BEING REWRITTEN)
- A Modder's Guide to Git
- Recommended/Required Tools
- Creating Your Folder Structure
- Working with the Repo
- How to Use the Multitool
- Class Descriptions
- Ability Distribution Presets
- Progressions
- Localization
- Abilities, Passives, and Spells
- Passive and Spell Lists
- Custom Equipment
- Class Icons
- Skill Icons (TODO)
- Handling Subclasses (TODO)
- Race Entry
- Root Templates
- Character Visuals
- Character Creation
- Localization
- Racial Feats
- Racial Progressions
- Tags
- Custom Icons