So
std::vector<std::string> spectators;
and
// this is calling multiple times
g_Visuals.spectators.push_back(format("LocalPlayer index %i", g_Local.iIndex).c_str());
g_Visuals.spectators.push_back(format("ent index %i", ent->index).c_str());
g_Visuals.spectators.push_back(format("User1 obs mode %i", g_Store.g_iUser1).c_str());
g_Visuals.spectators.push_back(format("User2 index %i", g_Store.g_iUser2).c_str());
g_Visuals.spectators.push_back(format("User3 index %i", g_Store.g_iUser3).c_str());
Here is how I draw every element in "spectators" I want to draw it after 5th element to side so i "w += 100"
int w = g_Screen.iWidth / 10;
int newline = 180;
for (auto v : spectators) {
g_Drawing.DrawString(ESP, (g_Screen.iWidth / 10) + w, (g_Screen.iHeight / 100) + newline, 240, 240, 240, cvar.esp_alpha, FONT_LEFT, "%s", v.c_str());
newline += 15;
// if its 5th element, set newline to 180 again
}
I tried this but im dumb
for (int i = 0; i < spectators.size(); i += 5) // i tried this, but im dumb, this is for is number power of
if (pow(5, (int)(log(i) / log(5))) == i) { w += 100; if (i == spectators.size()) i = 0; };
How it looks now img
and what I want img