FS25 Lightning Shock V1.2.1.5






FS25 Lightning Shock V1.2.1.5
What if the storm were no longer just a visual effect?
Lightning tears across the sky and thunder shakes the countryside—but this time, something else is happening. This mod goes beyond lights and sounds: the storm actively interferes with the gameplay, forcing you to adapt.
GIANTS once rejected one of my ideas simply because I dared to create something unusual. This time, I’m not going to explain myself.
I’ll let the storm answer for me.
Read readme from file…
I created this mod for my own enjoyment and according to my personal vision. I aim to recreate realistic situations.
Regular updates are planned, as I still have plenty of ideas. Let’s push the limits of the GIANTS Engine…
Overview
BXR Lightning Shock adds a map-independent, weather-driven lightning and power
outage system to Farming Simulator 25. Lightning selects targets and creates
branching channels, impact particles, cloud and environmental illumination,
thunder, and local power outages.
Weather And Automatic Lightning
– Active from early March through the end of October during rain, storms and hail.
– During active precipitation, distant events normally occur every 55–65 seconds.
– 80% of distant lightning is generated inside the player’s field of view.
– Every rolling 10-minute storm window includes at least 2–3 separated close
impacts within 100 metres of the player.
– Distant strikes have a higher probability of creating a separately impacting
wandering channel.
– Precipitation weather settings use denser, more continuous cloud cover.
Lightning And Cloud Effects
– The main channel begins at an approximate cloud height of 185 metres and follows
an irregular, unpredictable path with frequent direction changes.
– Main and wandering channels taper towards the ground. Side branches follow their
parent direction with a small outward angle and may grow additional child branches.
– Branch count is unchanged, but branches now originate at actual turns of the parent
channel. Their first section continues the pre-turn direction downward without a lateral kick.
– Horizontal branch drift is strongly limited and downward fall is steeper. Child and
descendant branches also follow the parent downward instead of forming near-horizontal spikes.
– Fading downward branches now contain several pronounced direction breaks. One or two
shorter offspring branches may grow from first-level turns under the same downward rules.
– Channel formation is progressive. The light envelope, cloud flash and visible
channel use the same timing.
– Six large upper cloud flashes remain inside the cloud layer and use GIANTS cloud
textures.
– The unsuccessful local fog-emitter experiment was removed. The bluish exit-point
environmental light and the six original upper cloud flashes remain unchanged.
– Seven non-emitter static shader layers form an irregular 80–100 metre spray field
below the main-channel start. Its top begins 5 metres below the start point, its
edges fade continuously to transparency, and its visibility range is 10 km.
– The spray uses a dedicated shader variation without distance fading and a stronger
base density so that it remains clearly visible from long range.
– The spray core now uses high alpha density, so the lower flash reads as light
reflected by a dense underside instead of passing straight through it. The edge
still fades fully transparent. The spray vanishes immediately when the flash ends.
– Dust-style normal-mapped two-sided lighting is used. A 110-degree upward-facing,
100-metre spotlight below the start is now primary, making reflection strongest
around the centre and smoothly attenuated towards the perimeter.
– Because camera-facing billboards override a 180-degree node rotation, the flip is
performed in the shader: only light arriving from below is accepted. Sky lighting
from above and the separate emissive boost are disabled for the spray.
– Reflected spray light now uses a dedicated radial mask centred on the exit point:
it is strongest at the centre and fades completely through a long outward transition.
– The channel is fully transparent at its start and smoothly reaches full visibility
over the first 80 metres measured along its downward path.
– Because the GIANTS line renderer has no alpha channel, a real visibility mask performs
the transition: omitted or fully bright layers and segments replace darkened lines.
– Main and wandering channel bodies now use 20 inner and 12 outer parallel layers,
doubling the previous layer counts.
– Every side-branch increment moves downward and forward. Its deviation from the
parent direction is limited to 78 degrees, preventing backward growth.
– Main and wandering channels grow simultaneously. Side branches and descendants
are longer while continuing to follow their parent direction.
– The wandering channel can no longer leave a black channel trace after its flash ends.
– Both channels use one flash envelope and the same propagation speed; their
different lengths mean that they do not need to reach the ground together.
– Previously very short spikes, side branches and descendants have a greater
minimum length.
– Close environmental illumination is restrained, while distant lightning
illuminates a wider area.
Thunder
– The mod uses 10 renamed and normalized original mono OGG samples and 10 normalized
muffled counterparts.
– Thunder uses reliable non-positional 2D sample playback instead of 3D audio sources.
– Normal samples play outdoors, in external camera view and in an open cab.
– Muffled samples play in a closed cab and in detected enclosed houses, garages,
workshops or other roofed spaces bounded by walls.
– Indoor detection checks for a roof and enclosing walls in multiple directions.
– Distant thunder arrives later and quieter, but the waiting time is shortened to
half of the real-world sound travel time.
– Every impact owns a separate thunder queue. Sounds may overlap; double impacts
retain a 90–220 ms separation.
Target Selection
– The system prefers tall and electrically plausible targets: streetlights, power
poles, water towers, silos, storage and production buildings, factories and
taller structures.
– Trees, vehicles and ground points are fallback targets.
– Previous impact locations are tracked and repeated hits are avoided when possible.
– The active player vehicle has a lower strike chance, while AI-driven vehicles use
a separate strike probability.
Vehicles And AI
– When a vehicle is struck, the complete consist is handled together.
– The mod preserves the current GIANTS AI, Courseplay or AutoDrive controller where
possible and attempts to resume the same controller after the outage.
– Engine, lights and safely restorable work return with delays. Uncertain work states
are never started automatically.
Power Outages
– An impact within 100 metres of the player creates a 200-metre local outage.
– A distant impact creates a 150-metre local outage around its own impact point.
– Affected lights, gates, barriers, railway crossings, LED and information panels,
productions, buying stations and selling stations may stop operating.
– Affected buying or selling cannot start and an active transaction is interrupted.
– Lights and equipment may return at different times with a flashing recovery sequence.
Multiplayer And Dedicated Servers — Test Branch
– The authoritative server selects the target, event identifier, start time and
random seed, then distributes the same event to every connected client.
– Gameplay consequences — vehicle shutdown, production blocking, buying/selling
restrictions and power outages — execute only on the server. Clients do not
independently mutate these states.
– Power outages use a separate network event and unique identifier. Clients use
this state to reproduce local darkness and related visual changes.
– A late joiner requests the current state. If lightning or an outage is active,
the server also sends its remaining state and timing.
– Automatic targeting rotates among active players instead of remaining centred
exclusively on the host.
– A dedicated server creates no local audio sources, lights, particles or visual
caches; rendering clients handle those resources.
– Closely arriving network strikes are kept as separate queued events so a newer
event cannot silently overwrite a process already in progress.
– During saving, the server restores temporarily disabled outage states and then
resumes an outage that still has time remaining.
– This multiplayer branch is a test version. Visual, audio, timing, late-join or
state synchronization defects may still occur. Feedback should include `log.txt`,
hosted/dedicated server type, player count, map name and in-game time of failure.
Performance And Compatibility
– The mod builds world, placeable and light caches while the map loads, then scans
only the required target area during an impact.
– Cache data is stored per map under modSettings/FS25_BXRLightningShock.
– The mod is map-independent and declared as multiplayer-supported in modDesc.
– Rain-based vehicle cleaning is provided separately by BXRVehicleCleaning.
V1.2.1.5
Multiplayer and dedicated servers
The complete lightning process is server-authoritative.
The server determines:
strike target;
event identifier;
start time;
synchronized random seed;
outage location, radius and duration.
Every client receives the same lightning event and generation parameters.
Gameplay consequences are applied exclusively by the server:
vehicle shutdown;
GIANTS AI, Courseplay and AutoDrive handling;
production shutdown;
buying and selling station blocking;
gate, barrier and railway-crossing shutdown;
local power-outage creation.
Clients reproduce only synchronized visual and audio states.
Every outage receives a separate network event and unique identifier.
Main and wandering-channel impacts can no longer suppress one another by sharing an outage identifier.
Late joiners send a dedicated state request.
The server transfers the remaining active state, including:
lightning development progress;
timing;
target position;
synchronized random seed;
remaining outage state and duration.
Automatic targeting rotates among active players instead of remaining centred exclusively on the host.
Closely arriving network strikes remain separate queued events, preventing a newer event from overwriting an active strike.
Main-channel and wandering-channel timing values are generated from the same synchronized seed.
Screen-space separation between the main and wandering channels now uses segment-based projection checks.
Short hysteresis prevents the wandering channel from flickering on and off between frames.
During saving, temporarily disabled outage states are restored. An outage that still has remaining time resumes after the save operation.
Dedicated servers avoid creating unnecessary:
light sources;
audio sources;
particle effects;
local rendering caches.
Test-version notice
The multiplayer branch is currently a test version. Possible remaining issues include:
visual or lightning-development differences;
thunder and audio timing errors;
late-join synchronization defects;
power-outage state mismatches;
behavioural differences between hosted and dedicated servers.
Please include the following with feedback:
log.txt;
hosted or dedicated server type;
number of connected players;
map name;
in-game time of the incident;
a short description of what each affected player saw or heard.
B O X E R
