For the Chapter 3 Battle Pass, I had the incredible opportunity to bring the "Trojan" assault rifle skin to life by developing its signature animated screen shader. The core concept was to create a living digital virus corrupting the weapon's systems, with layers of dynamic effects all running in real-time.
The shader creates a constantly shifting matrix of ASCII-like symbols that serves as a backdrop:
- Haunting Visuals: A ghostly skull and the "Aramid" / "Meridian" brand logos are permanently burned into the display, appearing as if they are part of the glitching matrix.
- Scrolling Marquee: The "Meridian" logo actively scrolls back and forth along the fore-end screen, adding a layer of constant motion.
- Invasive Pop-Ups: "VIRUS DETECTED" error messages appear, shift, and multiply across the screens.
- Procedural Pixelation: All visual elements, from the logos to the pop-ups, are pixelated in real-time by the shader. This effect is fully adjustable, allowing for fine-tuning of the grid's granularity from detailed to chunky.
= Behind the Scenes: The Technical Challenge =
The main challenge was to layer all these dynamic elements—the scrolling background, the static masks, and the procedural pop-ups—into a single, optimized shader.
An early approach using vertex paint on a high-density mesh was quickly abandoned due to poor performance and workflow limitations.
The final, successful solution was a highly flexible shader built around a mask-packing approach:
- Efficient Texturing: Key static elements (the skull, logos) were packed into the individual RGB channels of one texture. The components for the error windows were packed into a second. Third texture is a grid of symbols and grid-like random tiles for the UV shifting. This allowed for multiple unique masks with minimal texture memory.
- Smart UV Layout: The weapon's UVs were laid out to strategically separate each screen area. This allowed me to use a single material to drive different effects on different parts of the gun (e.g., the skull on the clip, the scrolling text on the front) while maintaining a consistent pixelation scale.
- Custom HLSL for Pop-Ups: To create the endlessly scrolling error messages, I wrote a custom HLSL node. This code procedurally generates duplicates of the error message texture, masks them, and shifts them at a configurable speed, giving the illusion of an infinite stream of warnings.
This approach resulted in a visually striking and highly customizable effect that was also performant, bringing the "Trojan" concept to life in a dynamic way.
Credits:
My work focused exclusively on technical approach creating the shader for the weapon's screens. The stunning weapon model and original concept were created by my talented colleagues.
Huge shoutout to the 1047 Games weapon art and concept teams for creating such an awesome foundation to build upon
Ilya Surikov / Base Weapon
https://www.artstation.com/surikovilya
Valerio De Carolis / Production
https://www.artstation.com/odec3d
Mattis Heisler / Concept
https://www.artstation.com/mattisheisler