GAME DEV ยท DEC 2025

Smol Theft Auto: Lag-On

Third-person mini-sandbox GTA parody where every cop in the city is out to get you. Built as a team of five with distributed tasks.

  • Unity
  • C#
  • GTA Parody
  • Third Person
  • Open World
Smol Theft Auto: Lag-On screenshot

At a glance

ROLE
Player character, weapons, grenades and HUD connections
TEAM
5 people
CONTEXT
School project at Forsbergs Skola

What I built

  • Player character and player movement.
  • Weapon system with 6 weapons and weapon swap.
  • Grenade system with a slow-motion aiming mode: time drops to 20% and an arc previews the throw.
  • Dramatic player slowdown while aiming a grenade.
  • HUD connections for health, ammo and grenades.

Technical decision

Slow motion that keeps the physics steady

Aiming a grenade slows the whole game to 20%. The fixed time step is scaled with the time scale, so physics keeps stepping at the same pace relative to game time. The grenade count is checked before the mode starts, so a player with no grenades never gets the slowdown, and leaving the mode puts both values back.

GrenadeThrower.cs
private void EnterAimingMode()
{
    // Check grenade availability BEFORE entering aiming mode
    if (ammoSystem != null && ammoSystem.GetGrenadeCount() <= 0)
        return;

    aimingMode = true;

    if (Grenade != null)
    {
        // preview instance (kinematic)
        var preview = Instantiate(Grenade.gameObject, ReleasePosition);
        Destroy(preview.GetComponent<Rigidbody>()); // keep just model; simpler preview
    }

    Time.timeScale = 0.2f;
    Time.fixedDeltaTime = 0.02f * Time.timeScale;
    LineRenderer.enabled = true;
}

private void ExitAimingMode()
{
    aimingMode = false;
    Time.timeScale = 1f;
    Time.fixedDeltaTime = 0.02f;
    LineRenderer.enabled = false;
}
Private group repo, source available on request. Snippet from the first version of the file.