Compare commits

..

1 Commits

Author SHA1 Message Date
3cd0a1f8ae lua_api: accept velocity as a vector 2026-03-21 09:36:00 -05:00

View File

@ -48,7 +48,7 @@ void draw_quad(int x1, int y1, int x2, int y2,
void set_sphere(float x, float y, float vx, float vy) void set_sphere(float x, float y, float vx, float vy)
{ {
XMVECTOR unit = XMVectorSet(1, 0, 0, 0); // the angle==0 unit vector XMVECTOR unit = XMVectorSet(1, 0, 0, 0); // the angle==0 unit vector
view::state.forward = XMVectorSet(vx, vy, 0, 0); view::state.forward = XMVector3Normalize(XMVectorSet(vx, vy, 0, 0));
view::state.normal = view::get_normal(); view::state.normal = view::get_normal();
view::state.direction = view::get_direction(); view::state.direction = view::get_direction();