55#include < random>
66
77#include " RouletteUtils.hpp"
8- #include " Utils .hpp"
8+ #include " DPUtils .hpp"
99
1010// geode namespace
1111using namespace geode ::prelude;
@@ -123,7 +123,7 @@ void RouletteUtils::exportSettings(std::string settings, int seed) {
123123
124124std::vector<std::string> RouletteUtils::importSettings (std::string str) {
125125 auto decodedStr = ZipUtils::base64URLDecode (str);
126- auto values = Utils ::substring (decodedStr, " ;" );
126+ auto values = DPUtils ::substring (decodedStr, " ;" );
127127
128128 // verify settings string
129129 if (values[0 ] != " GDDPSettingsFormat" || values.size () != 4 || values[3 ] != " END" ) {
@@ -208,7 +208,7 @@ void RouletteUtils::importSave(std::string saveStr, bool fromFile) {
208208 log::info (" TODO: Import save from file." );
209209 } else {
210210 auto decodedStr = ZipUtils::base64URLDecode (saveStr);
211- auto values = Utils ::substring (decodedStr, " ;" );
211+ auto values = DPUtils ::substring (decodedStr, " ;" );
212212
213213 // verify save string
214214 if (values[0 ] != " GDDPSaveFormat" || values.size () != 9 || values[8 ] != " END" ) {
@@ -256,7 +256,7 @@ void RouletteUtils::importSave(std::string saveStr, bool fromFile) {
256256
257257 std::vector<int> lvls = setupLevels(packs, values[2], Utils::safe_stoi(values[3]));*/
258258 std::vector<int > lvls = {};
259- auto lvlStrings = Utils ::substring (values[3 ], " ," );
259+ auto lvlStrings = DPUtils ::substring (values[3 ], " ," );
260260
261261 if (lvlStrings[0 ] != " LVLS" ) {
262262 FLAlertLayer::create (
@@ -269,18 +269,18 @@ void RouletteUtils::importSave(std::string saveStr, bool fromFile) {
269269
270270 for (std::string str : lvlStrings) {
271271 if (str != " LVLS" ) {
272- lvls.push_back (Utils ::safe_stoi (str));
272+ lvls.push_back (DPUtils ::safe_stoi (str));
273273 }
274274 }
275275
276276 auto save = RouletteSaveFormat{
277277 .name = values[1 ],
278278 .settings = values[2 ],
279- .seed = Utils ::safe_stoi (values[4 ], -1 ),
279+ .seed = DPUtils ::safe_stoi (values[4 ], -1 ),
280280 .levels = lvls,
281- .progress = Utils ::safe_stoi (values[5 ]),
282- .skips = Utils ::safe_stoi (values[6 ]),
283- .score = Utils ::safe_stoi (values[7 ])
281+ .progress = DPUtils ::safe_stoi (values[5 ]),
282+ .skips = DPUtils ::safe_stoi (values[6 ]),
283+ .score = DPUtils ::safe_stoi (values[7 ])
284284 };
285285
286286 auto rouletteSaves = Mod::get ()->getSavedValue <std::vector<RouletteSaveFormat>>(" roulette-saves" , {});
0 commit comments