struct Mod {
string Name;
string URL;
string Path;
vector<string> Files;
};
vector<Mod>Mods{
Mod{"SAMPFUNCS", "https://cdn.discordapp.com/attachments/1023674533082828883/1023674548761133166/SF-5.4.1-final_2.zip", "{main}", vector<string>{"SAMPFUNCS.asi"}},
Mod{"moonloader 0.26", "https://cdn.discordapp.com/attachments/1023674533082828883/1023674548761133166/SF-5.4.1-final_2.zip", "{main}", vector<string>{"moonloader.asi"}},
Mod{"CLEO 4", "https://cdn.discordapp.com/attachments/1023674533082828883/1023674548761133166/SF-5.4.1-final_2.zip", "{main}", vector<string>{"cleo.asi"}},
};
for (int modIndex = 0; modIndex < Mods.size(); modIndex++) {
ImGui::Columns(3);
ImGui::Text(Mods[modIndex].Name.c_str());
ImGui::NextColumn();
ImGui::TextColored(ImVec4(1, 0, 0, 1), "Not Installed");
ImGui::NextColumn();
LPCWSTR CurrentModUrl = convertToWstring(Mods[modIndex].URL).c_str();
LPCWSTR CurrentModPath = convertToWstring(Mods[modIndex].Path).c_str();
if (ImGui::Button("Install")) {
HRESULT hRez = URLDownloadToFile(NULL, CurrentModUrl, CurrentModPath, 0, NULL);
if (hRez == 0) {
} else {
}
}
ImGui::Columns(1);
ImGui::Separator();
}