Compare commits

..

No commits in common. "afc163f3449a115f123e6cb6ffd83a251b674b67" and "bbc40d7c935e4aa64f7150207b8e1494921a20f9" have entirely different histories.

3 changed files with 7 additions and 7 deletions

View file

@ -193,7 +193,7 @@ void Mass::refreshValues() {
return; return;
} }
_account = account_prop->value; _steamId = account_prop->value;
_state = State::Valid; _state = State::Valid;
} }
@ -930,8 +930,8 @@ auto Mass::techs() -> Containers::ArrayView<Int> {
return _tuning.techIds; return _tuning.techIds;
} }
auto Mass::updateAccount(const std::string& new_account) -> bool { auto Mass::updateSteamId(const std::string& steam_id) -> bool {
_account = new_account; _steamId = steam_id;
auto account = _mass->at<StringProperty>("Account"); auto account = _mass->at<StringProperty>("Account");
if(!account) { if(!account) {
@ -939,7 +939,7 @@ auto Mass::updateAccount(const std::string& new_account) -> bool {
return false; return false;
} }
account->value = new_account; account->value = steam_id;
return _mass->saveToFile(); return _mass->saveToFile();
} }

View file

@ -137,8 +137,7 @@ class Mass {
auto architecture() -> Int&; auto architecture() -> Int&;
auto techs() -> Containers::ArrayView<Int>; auto techs() -> Containers::ArrayView<Int>;
auto account() -> std::string const&; auto updateSteamId(const std::string& steam_id) -> bool;
auto updateAccount(const std::string& new_account) -> bool;
private: private:
void getCustomStyles(Containers::ArrayView<CustomStyle> styles, ArrayProperty* style_array); void getCustomStyles(Containers::ArrayView<CustomStyle> styles, ArrayProperty* style_array);
@ -204,5 +203,5 @@ class Mass {
Containers::StaticArray<7, Int> techIds; Containers::StaticArray<7, Int> techIds;
} _tuning; } _tuning;
std::string _account; std::string _steamId;
}; };

View file

@ -49,6 +49,7 @@ enum class DamageType {
}; };
struct Weapon { struct Weapon {
Weapon() = default; Weapon() = default;
Weapon(const Weapon& other); Weapon(const Weapon& other);