0

Question about shotgun bullet and team damage

mo D 1 month ago in Shooter updated by Dante 1 month ago 2

Shotgun bullet:

How to make a shotgun bullet that spread as a certain angle or shoot more than one bullet when triggered?

Team damage:

I'm using projectile for some ammo, how can I set a team or give tag to ammo so it won't hurt the shooter and friendly object?

Unity version:
2019.4.5f1
Game Creator version:
latest

In detail, I'm trying to do something like this, a gun can shoot more than one bullet in different angles(spread)

I would also like to know the best practice for the shot gun set up, but I do have a solution for the team damage:

1. Create a layer called "team" (or anything you want, just as long as you remember what you called it)

2. Open the bullet prefab and scroll to the shooting section.

3. In the shooting section you should see a option called "Layer Mask" and it should have a drop down next to it.

4. Uncheck the option for "team"

5. Go to any object you want to be marked as friendly, and change its layer to Team.