MezornoIV
|
  |
| Joined: 20 Jul 2010 |
| Total Posts: 2276 |
|
|
| 06 Jun 2016 10:10 AM |
| Is there a way to define where a bullet from a gun comes from? For example, right now it comes from the handle, is there a way to design a chamber for it to come out of? How would I do this? |
|
|
| Report Abuse |
|
|
Aethex
|
  |
| Joined: 16 Oct 2011 |
| Total Posts: 2193 |
|
|
| 06 Jun 2016 10:20 AM |
| Literally just build a chamber, weld it to your gun, and then edit your script so that the start position of the projectile is relative to the chamber it comes out of. |
|
|
| Report Abuse |
|
|
|
| 06 Jun 2016 11:14 AM |
You can make the bullet named "Gun's name Bullet"
|
|
|
| Report Abuse |
|
|
MezornoIV
|
  |
| Joined: 20 Jul 2010 |
| Total Posts: 2276 |
|
|
| 06 Jun 2016 11:21 AM |
| Sorry for not responding, I just changed the fire location from the handle to the newly named chamber. I feel stupid |
|
|
| Report Abuse |
|
|
|
| 06 Jun 2016 11:23 AM |
| Be careful of that, if it can go through walls then they can shoot through walls (which is a problem in a lot of Roblox games, every FPS game I've played so far). |
|
|
| Report Abuse |
|
|
|
| 06 Jun 2016 11:49 AM |
@Flux
couldn't you just use 2 raycasts?
one from torso and one from chamber pointing to mouse, chamber being the magnitude between bullet and mouse.Hit and torso being the length between the Torso and the Chamber.
to make sure your not colliding with a wall and if not then shoot full length. |
|
|
| Report Abuse |
|
|
| |
|