up build windows

This commit is contained in:
Nikola Petrov
2024-08-12 17:48:52 +02:00
parent 390c81b30b
commit 34e8e7421a
7 changed files with 86 additions and 154 deletions

View File

@@ -60,13 +60,13 @@ void Tree::drawBranch()
for (size_t i = 0; i < branches[arg.dep].numOfBranches; i++)
{
float newAngle = arg.angleDeg - 90 + (degres * (i + 1));
draw_calls.push_back((DrawArgs){next, newAngle, arg.lenghth * next_len, arg.dep + 1});
draw_calls.push_back({ next, newAngle, arg.lenghth * next_len, arg.dep + 1 });
}
}
void Tree::drawTree()
{
draw_calls.push_back((DrawArgs){start, 0, (float)size / 4, 1});
draw_calls.push_back({start, 0, (float)size / 4, 1});
while (!draw_calls.empty())
{
@@ -82,7 +82,7 @@ void Tree::generateBranches()
uint8_t r = GetRandomValue(0, 255);
uint8_t g = GetRandomValue(0, 255);
uint8_t b = GetRandomValue(0, 255);
branches[i].color = (Color){r, g, b, 255};
branches[i].color = {r, g, b, 255};
branches[i].numOfBranches = GetRandomValue(1, 3);