62GB
|
  |
| Joined: 03 Oct 2011 |
| Total Posts: 4157 |
|
|
| 29 Jan 2016 01:16 PM |
I never was able to come up with anything like this before. The higher the value, which can go to a max of 100, the more accurate each shot is. How could I do this? This is what I usually use for setting velocity to a bullet.
bullet.Velocity = (player.Character.Humanoid.TargetPoint - bullet.Position).unit * POWER |
|
|
| Report Abuse |
|
|
|
| 29 Jan 2016 01:17 PM |
Create a table of positions using a circle, and select one at random
The mountain chicken, my favourite frog.
|
|
|
| Report Abuse |
|
|
62GB
|
  |
| Joined: 03 Oct 2011 |
| Total Posts: 4157 |
|
|
| 29 Jan 2016 01:18 PM |
| Thanks for the reply but I think there's a better way. |
|
|
| Report Abuse |
|
|
|
| 29 Jan 2016 01:18 PM |
| u could incorporate : math.Random(player.Accuracy.Value/1,2,player.Accuracy.Value) some how but that kind of logic |
|
|
| Report Abuse |
|
|
62GB
|
  |
| Joined: 03 Oct 2011 |
| Total Posts: 4157 |
|
|
| 29 Jan 2016 01:19 PM |
| Thanks Electo. I'll try something like this. |
|
|
| Report Abuse |
|
|
62GB
|
  |
| Joined: 03 Oct 2011 |
| Total Posts: 4157 |
|
|
| 29 Jan 2016 01:22 PM |
Ugh I'm not good at math. 1/accuracy is good, but even at 50 accuracy it comes up as .02
100 is .01
Any algorithms for this? |
|
|
| Report Abuse |
|
|
|
| 29 Jan 2016 01:22 PM |
Or, get two positions, and lerp between them (X and Y separately)
The mountain chicken, my favourite frog.
|
|
|
| Report Abuse |
|
|
|
| 29 Jan 2016 01:24 PM |
So if you had vector11 as right.Position:lerp(left.X, 0,0,0), and right.Position:lerp(left.X,0,0,0), then take it out and us it in your jazz
The mountain chicken, my favourite frog.
|
|
|
| Report Abuse |
|
|
62GB
|
  |
| Joined: 03 Oct 2011 |
| Total Posts: 4157 |
|
| |
|
| |
|