fixed collision
This commit is contained in:
parent
fc494efa76
commit
dea7f61178
1 changed files with 4 additions and 4 deletions
8
main.cpp
8
main.cpp
|
@ -454,12 +454,12 @@ int main()
|
|||
}
|
||||
uint32_t image_index = image_result.value;
|
||||
vkResetCommandBuffer(command_buffers[0], 0);
|
||||
if (vertices[1].position[0] > 1.0f)
|
||||
move = -0.01;
|
||||
else if (vertices[3].position[0] < -1.0)
|
||||
move = 0.01;
|
||||
for (auto &vert: vertices)
|
||||
{
|
||||
if (vert.position[0] > 1.0f)
|
||||
move = -0.01;
|
||||
else if (vert.position[0] < -1.0)
|
||||
move = 0.01;
|
||||
vert.position[0] += move;
|
||||
vert.position[1] += move;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue