16
How do schools of fish move?
They don't need to know the state of every individual fish in the school at any given moment, nor do they need to know their directions or require complex state machine control.
What each fish in a school needs to do is actually very simple.
According to the Boids model, its core rules are actually only three.
Separation, alignment, and cohesion.
Simply put, a fish needs to constantly adjust its distance, making sure not to get too close to surrounding individuals to prevent crowding together.
But they cannot swim randomly either; their general direction needs to be averaged based on nearby individuals, which is the so-called 'alignment'.
Cohesion, on the other hand, requires staying as close together as possible to prevent the swarm from becoming too scattered.
Under these three rules, a simple flocking behavior is born.
In fact, each individual is merely making the simplest single-layer judgment based on its immediate surroundings.
But when countless individuals group together, an extremely complex flocking behavior can emerge.
In the field of computer science, flocking behavior is nothing new. Boids is one of the most representative examples, proposed back in 1986, and it quickly became an important technical foundation for fields like Computer Graphics, AI, and complex systems research.
It aims to simulate the movement patterns of real-world flocks of birds and schools of fish in computers using simple local rules.
The defining feature of Boids is that its local rules are extremely simple.
Its complex behavior is entirely formed by a vast number of simple actions.
And this...
...was precisely what Jesse Lin and his team needed.
At a glance, tons of infected surge like a tidal wave from the far edge of the screen.
Dense, packed, and endless.
But they aren't actually running any complex AI.
Instead, it's flocking behavior combined with flow field pathfinding.
Stripping away the layers, most of the infected don't even know where the players are.
Algorithms are amazing, aren't they? That might be the most charming thing about computers.
Simulating complex behavior doesn't necessarily require a complex brain.
Sometimes, all that is needed is careful observation of nature.
Boids is like a miracle co-written by bionics and computer science.
Ants, bee swarms, bird flocks, fish schools...
Every swarming creature follows entirely distinct, yet orderly and subtly profound rules of life.
A professional computer scientist can uncover the most fundamental rules from them and turn them into things that computers can simulate.
The AI Director of left 4 dead might not even know what an infected horde is.
Even the infected in the game themselves probably don't know.
They just need to follow the rules set by the program and move along with the main group.
The horde naturally comes into being as a result.
"If that's the case, then we only need to focus on the bot teammates and special infected," Jesse Lin nodded with satisfaction.
This way, the AI overhead plummets off a cliff, and the massive amount of saved resources can be poured directly into the AI design of the special infected.
In a sense, these elite units are the true actors of the game.
While the zombie horde is more like extras, or rather... the mood setters.
Thinking of this, Jesse Lin suddenly felt amused.
It felt great to wrestle with hardware limitations like this.
Having grown accustomed to the surplus performance of later eras, this feeling of outsmarting hardware constraints had turned out to be the most entertaining part of the development process.
Delivering the most exaggerated and gorgeous effects to players using the minimal amount of system resources—
That is the true meaning of optimization!
"That actually reminds me."
As Jesse Lin looked at the growing content on the planning board, the figure of General Motors president Russell suddenly crossed his mind.
Having just concluded their collaboration on gran turismo, Russell immediately signed a multi-year order for production-grade graphics cards. With a big spender like General Motors around, AMENVA didn't need to worry about the market for its graphics cards at all.
However, an automaker ordering graphics cards wasn't doing so to render high-end graphics.
Instead, it was for... fluid simulation.
Calculating the movement of a massive number of particles would work a CPU to death.
But if handed over to a graphics card, it could accomplish the job with thousands of times the efficiency.
This is the graphics card's greatest domain of strength—parallel processing.
Graphics cards excel at executing operations that are vast in quantity yet highly simple.
"We can offload the flocking behavior to the GPU, leaving the CPU to simply inform the swarm of the player's position."
The architecture of AMENVA graphics cards was very modern.
This had always been AMENVA's most vital hardware foundation.
In an era where 3D transition was not yet fully mainstream, not everyone had the capability to design a true 'graphics card'.
This architectural advantage might not seem useful most of the time. After all, clock speeds were fixed; no matter how advanced your architecture was, a generational gap in manufacturing process could not be bridged so easily.
But at certain moments, these architectural advantages could suddenly deliver unexpected surprises.
Just like S3 and its architecture.
Most of the time, that heap of junk was unquestionably useless with zero practical value.
But for developers looking to create interactive movies, that thing was genuinely useful.
Even AMENVA had referenced that architecture multiple times, giving EA a few masterclasses back and forth.
Such is the importance of architecture.
It possesses clear orientation and specific application directions.
Asking the CPU to handle flocking calculations is like asking the last Go master to throw a javelin, or asking heroine Sister Yan to play Go against AlphaGo.
Finding the right job for each piece of hardware can sometimes yield vastly different performance out of identical designs.
Externally, AMENVA had never held a formal architecture product launch.
Every GPU vendor was still groping in the dark to figure out their own architecture. But internally, the GPU division of MicroNova Semiconductor—the team led by Jensen Huang—had long since given it a name.
【CUDA】
Full name: Compute Unified Device Architecture.
Just like the picture Jesse Lin had once painted for Russell.
One genius and one million ordinary workers.
That was the relationship between a CPU and a GPU.
The graphics card only needed to feverishly perform massive amounts of elementary math problems simultaneously.
...
Once the project's tone was set, word spread rapidly throughout the development department.
Before it was even noon, a large crowd of developers from the studio next door surged over.
Are you kidding? How could something so fun happen without us?
So the team was quickly assembled. Will led Activision and Bullfrog to work on flocking AI.
Meanwhile, Carmack was kicked over to the engine department by Jesse Lin to solve the graphics issues with Bethesda and the rest.
Kojima teamed up with Blizzard and the Hans Zimmer Studio team, who had just rushed back from Germany, to begin designing the game's visual concepts and sound effects.
In the end, only Jesse Lin and Sid Meier were left staring at each other in the empty office.
Speaking of which, ever since Gerald retired, Sid Meier had become the oldest person in the development department.
On normal days, this guy always maintained an extremely peaceful elder demeanor, acting practically like a sloth.
But in his heart, he was unquestionably a lunatic just like the rest of them.
A secretly crazy person is even scarier than an openly wild one.
"Sid, as for the AI Director part, I actually think you're a better fit for it than Kojima."
Hideo Kojima's strength lies in cinematic narrative.
Although this module is called the 'AI Director', it actually doesn't have much to do with a traditional director in essence.
Of course, Kojima was still very suitable to serve as the overall game director for the project. Controlling atmosphere, polishing pacing, and setting up scenes were all right in his wheelhouse.
But the AI Director is fundamentally more about the strategic layer.
It's responsible for constantly monitoring player status and delivering dynamic pressure adjustments.
This concept is somewhat similar to the storyteller system in RimWorld.
"Controlling the game tempo?"
Sid looked at the planning board before him, which was already densely covered in notes, his gaze pausing on the 【AI-Director】 line.
When the elites spawn, when the zombie horde surges, when players reach the safe house...
These things that seem to be controlled by the players themselves are actually entirely up to the designers.
And when it came to manipulating player psychology... Sid Meier was an undisputed master.
He could quietly steal away vast amounts of a player's time without them even realizing it.
Even when dawn was almost breaking, players would always want "just one more turn"—even if it was just to finish building a granary that was one turn away from completion.
Even if it was for some meaningless trivial task. And after turn after turn, endless goals would continue to emerge ahead.
Whenever players felt like they could finally catch their breath and relax, the game would deliver new stimuli right on time.
Just hold out for one more wave; the safe house must be right up ahead.
I'll go to sleep once I reach the next safe house!
But once they actually made it to the safe house, the arrival of new weapons or new events would plunge players into conflict once more.
This katana looks so cool... Should I... play one more stage to test it out?
In essence, the AI Director is an engineering-heavy, program-side system rather than a domain truly belonging to an actual director.
As for Hideo Kojima?
He would play a vital role in level design and elite monster placement.
Imagine the squad walking into a deep, dark corridor.
Accompanied by flickering lights, there are only a few weak, common infected in the corridor.
Yet amid their low growls, the mournful weeping of a woman can be faintly heard. Just as the player perks up their ears to verify if they misheard—
Their teammate nearby suddenly utters a blood-curdling scream, pinned to the ground and fiercely mauled by a Hunter pouncing from a dark corner.
At that moment, the AI Director suddenly kicks in, and a zombie horde surges from up ahead.
In panic, the player frantically fires off rounds, completely failing to notice that stray bullets hit a tragic figure in white crouching with her back turned in the corner...
