Forum > Scripts >

Phantom Forces Custom Trajectory Function

Posts: 21

Threads: 11

Joined: May, 2021

Reputation: 4

Posted

idk if its better then the default one, probably not lol

function trajectory(origin, acceleration, target, bulletspeed)
    local time = (target - origin).Magnitude / bulletspeed
    return -acceleration * time / 2 + (target - origin) / time, time
end

no credit required if you're gonna use it (idk why you would)

(made this out of boredom btw)

  • 0

mickey#3373

Users viewing this thread:

( Members: 0, Guests: 1, Total: 1 )