Uploaded March 2023 | Updated September 2026, 1 hour ago
There are a surprisingly large number of challenges that you run into when trying to get "aiming" right. This week in the Gun Series I'll discuss 3 common implementations for aiming in games, the pros and cons of each one, and we'll even implement them so you can pick which one fits your game the best!
πΆ ALL THINGS LlamAcademy now available at: https://llamacademy.dev/support including latest tutorials, courses, ways to support, and more! Check it out π
π¨βπ» Get the FULL FREE PROJECT on GitHub: github.com/llamacademy/scriptable-object-based-guns
π·οΈSave 25% on the ultimate C# IDE: JetBrains Rider with code LLAMACADEMY: jetbrains.com/store/?section=personal&billing=yearly
π Resources:
π Visualization of the problem with Raycast from Camera: forums.unrealengine.com/t/third-person-shooter-aiming-at-crosshair/129180
Some links may be affiliate links, which at no additional cost to you, gives me a small portion of the purchase.
Chapters:
00:00 Summary of Solutions
01:00 Option 1 Pros and Cons
02:43 Option 2 Pros and Cons
03:46 Option 3 Pros and Cons
05:27 Define ShootType.cs
05:38 Support ShootType on ShootConfigScriptableObject.cs
05:46 Shoot from Camera in GunScriptableObject.cs
09:14 Give Camera to GunSO in PlayerGunSelector.cs
09:22 Hook up References & Demo
10:30 Show Accurate Crosshair in PlayerAction.cs for FromGun ShootType
12:55 Demo 2 with Accurate Crosshair with ShootType.FromGun
13:48 Closing & Support LlamAcademy
There are a surprisingly large number of challenges that you run into when trying to get "aiming" right. This week in the Gun Series I'll discuss 3 common implementations for aiming in games, the pros and cons of each one, and we'll even implement them so you can pick which one fits your game the best!
πΆ ALL THINGS LlamAcademy now available at: https://llamacademy.dev/support including latest tutorials, courses, ways to support, and more! Check it out π
π¨βπ» Get the FULL FREE PROJECT on GitHub: github.com/llamacademy/scriptable-object-based-guns
π·οΈSave 25% on the ultimate C# IDE: JetBrains Rider with code LLAMACADEMY: jetbrains.com/store/?section=personal&billing=yearly
π Resources:
π Visualization of the problem with Raycast from Camera: forums.unrealengine.com/t/third-person-shooter-aiming-at-crosshair/129180
Some links may be affiliate links, which at no additional cost to you, gives me a small portion of the purchase.
Chapters:
00:00 Summary of Solutions
01:00 Option 1 Pros and Cons
02:43 Option 2 Pros and Cons
03:46 Option 3 Pros and Cons
05:27 Define ShootType.cs
05:38 Support ShootType on ShootConfigScriptableObject.cs
05:46 Shoot from Camera in GunScriptableObject.cs
09:14 Give Camera to GunSO in PlayerGunSelector.cs
09:22 Hook up References & Demo
10:30 Show Accurate Crosshair in PlayerAction.cs for FromGun ShootType
12:55 Demo 2 with Accurate Crosshair with ShootType.FromGun
13:48 Closing & Support LlamAcademy




