Tier 4
Series 304
304G: The Hive Exam
Capstone Exam
"The drone swarm is crashing. The logic is rigid, the CPU is melting from collision checks, and the sensors are causing lag spikes. Identify the three critical architectural failures to synchronize the fleet."
Target Asset for Audit
FRAGILE_CODE_DETECTED
using UnityEngine;
using System.Collections.Generic;
public class DroneSwarm : MonoBehaviour {
public List<Drone> allDrones;
void Update() {
// Audit Requirement: Lesson 304D (Spatial Grid)
// Error 1: N-Squared Collision Check
foreach(var d1 in allDrones) {
foreach(var d2 in allDrones) {
if(Vector3.Distance(d1.pos, d2.pos) < 1) Avoid();
}
}
// Audit Requirement: Lesson 304A (Behavior Tree)
// Error 2: Rigid If-Else Logic
if (health < 10) Flee();
else if (dist < 5) Attack();
else Patrol();
// Audit Requirement: Lesson 304F (Sensors)
// Error 3: Synchronized Raycasting
if (Physics.Raycast(transform.position, fwd)) { ... }
}
}