SHOOTING with BULLETS + CUSTOM PROJECTILES || Unity 3D Tutorial (#1)

preview_player
Показать описание
➤SHOOTING with BULLETS + CUSTOM PROJECTILES || Unity 3D Tutorial:
I've already made a tutorial about shooting with ray casts, but a lot of people wanted to know how to shoot with bullets. So in this series, I'll show you everything you need to know to start shooting bullets/custom projectiles in Unity 3d! :D

I forgot to mention the DOWNLOADS in the video (sorry :D)

For now, I planned this to be a 2 part series but if you enjoy it make sure to like, if enough people want it, I'll make this series longer :D

The second part will come out in a couple of days! :D

Links:

🏹 Get Access to my RANGED COMBAT LAB! 🏹

➡️ Get Access to my full MOVEMENT LAB! ➡️

Other videos to check out :D

Music used:

Support me on Patreon:

Some tags (ignore :D):
Dave / Gamedevelopment,unity,unity3d,unity 3d,unity engine,unity gameengine,indie game,indie game developement,indie gamedev,indie gamedev,indie games,dave,gamedevelopement,dave gamedevelopement, unity gamedev, unity gamedevelopement,indie game devlog,indie game devlog,devlog,indie game devlog,unity,unity3d,Unity,Unity 3d,unity 3d,gameengine,Dave,/,Gamedevelopment,indie,game,devlog,dev,log,dev,blog,indie gamedev,game,dev,unity,unity3d,unity 3d,Dave / Gamedevelopment,Unity,unity tutorial,unity projectile,unity 3d tutorial,unity fps,unity weapon system,unity shooting,unity shooting projectiles 3d,unity shooting projectiles,unity shooting bullets,shooting,projectiles,bullets,tutorial,unity shooting bullets tutorial,unity shooting projectiles tutorial,unity shooting tutorial,unity shooting physics,unity fps tutorial,unity first person shooter,unity 3d fps tutorial,fps tutorial,shooting with bullets + custom projectiles

#UnityTutorial #UnityShooting #ShootingTutorial

You really scrolled all the way down here? :D
Рекомендации по теме
Комментарии
Автор

I just start making my first game and watched so many tutorials to solve my issues but none of them helped, then I see your channel and it have every single video I need, love you work sir

GodBeast_FireOnHell
Автор

I know it's been a while since this video came out so apologies if you've already fixed/moved on from this in the time since, but I noticed some problems with the way your spread is calculated and have personally fixed them to share with you and anyone passing by.

1. Your spread calculates purely based on the target point's position, it doesn't get bigger the further away it is, meaning stuff like shotguns would be super OP and accurate at very far distances (which is fine if this was intended, but it didn't work for my project). I fixed this by always setting the target point to a constant position in front of the gun muzzle (5 in my case).

Use this:
Vector3 targetPoint = ray.GetPoint(5f);
Instead of the raycast if else block to determine the hit point.

2. Your spread also calculates in only the x and y directions, meaning if I face the x direction there is no horizontal bullet movement because there's no z spread.

Just add another Random.Range for the z direction in directionWithSpread for this to be solved:

float x = Random.Range(-spread, spread);
float y = Random.Range(-spread, spread);
float z = Random.Range(-spread, spread);

directionWithSpread = directionWithoutSpread + new Vector3(x, y, z);

Hope this helps someone!

non-shockingtopics
Автор

Haha Just at the perfect time...I am making an fps game and really wanted a nice easy custom projectile shooting tutorial and their we go.Dave your game development and tutorials are awesome.I am sure that you will hit 1 million really fast(Like really fast)

divyanshpathak
Автор

You are the Future Barckeys He left :(

crazycraftcreations
Автор

your vids are great, thanks for always uploading quality tutorials and content! always to the point, and the foundation you provide in your vids is super easy to expand upon. thank you!

GlasTaibhse
Автор

Although the video was fast I paused it at times to read up on what each bit of code did and why it needs such parameters. Overall it's been really useful to start off with and I thank you a lot for making this video!

ArranAsh
Автор

Great video! Can't wait for the rest of the series!

stevenjuana
Автор

Wow this gives me such amazing Brackeys vibes :)

I never knew that you could simply state a bool or a !bool inside an if query, I always thought you had write bool = true or bool = false.

burgerfanman
Автор

Great tutorial mate and you solved my greatest issue, which is to make the projectile travel towards the center of the screen. Much appreciated!

MrHerrJonsson
Автор

Searched a lot for moving a prefab in the raycast direction, nothing solved my went through a lot of blogs and and finally I found this a lot for this. This is the best way I've come through to solve my shooting issues.

nikhilchhetri
Автор

I forgot to mention the DOWNLOAD LINKS in the video :D


If you need help with any of the code shown, just visit the "coding-help" channel on my discord server :D
Also you can find many more movement tutorials on my channel in the "Tutorials!" playlist - I really hope they help you on your further GameDev journey!

And in case you're interested in getting access to my full RANGED COMBAT LAB, with which you can create pretty much any ranged ability/weapon you can think of, check out the trailer:

Thanks so much for watching, hope this tutorial has helped you!

Thank you so much for watching! If you have any questions just write a comment, I'll answer as many as I can! :D

davegamedevelopment
Автор

awesome! thank you! a bit tricky at spots but just because i haven't tried to do it before. i still followed it and understand it well enough to try it myself now.

stevethepirate
Автор

thanks for your work. you're vids are a great resource for those learning Unity!

adadventure
Автор

your tutorials make me go






Y E S

ghaco
Автор

Great video! i really liked how you showed us how to set the gun up! thanks!

bumba
Автор

Awesome video, but one little thing. A shotgun does not shoot multiple bullets per trigger press, it shoots a shotgun shell which spreads little tiny balls all over the place. I think you don't need to keep multiplying and dividing the number, but just spawn that many each time you shoot.

SacWebDeveloper
Автор

why are you only at 14k you deserve more

youton_gaming
Автор

Sticky bullets would be cool😎
Like the plasma grenades in HALO😁👍

IntroLove
Автор

If your making a FPS game, he also has a video on first person player movement which helped me alot

ebrahimmomin
Автор

You are gods gift to noobs and professionals.

ScoutsStudios