• Bad argument #2 to '_sub' vector expected, got number
    1 replies, posted
Hello, the error is on this line: [CODE] local hullxymax = math.Round(math.Max(ent:OBBMaxs() - ent:OBBMaxs().x * ((ent:GetAngles().y % 90)/90), ent:OBBMaxs().y + ent:OBBMaxs().x * ent:OBBMaxs().y * ((ent:GetAngles().y % 90)/90)), 1) [/CODE]
The error is in [CODE]ent:OBBMaxs() - ent:OBBMaxs().x[/CODE] ent:OBBMaxs() is a vector and ent:OBBMaxs().x is a number. You can't subtract vectors from numbers or vice versa. Also you shouldn't write everything in one line and use more variables, so you will find your error faster next time.
Sorry, you need to Log In to post a reply to this thread.