mirror of
https://github.com/DarkflameUniverse/DarkflameServer.git
synced 2025-08-07 11:14:11 +00:00
chore: Use string to access SQLite columns (#1535)
* use string to access field name * Update DEVGMCommands.cpp * corrected column name * constexpr array include <array> Revert "constexpr array" This reverts commit 1492e8b1773ed5fbbe767c74466ca263178ecdd4. Revert "include <array>" This reverts commit 2b7a67e89ad673d420f496be97f9bc51fd2d5e59. include <array> constexpr array --------- Co-authored-by: jadebenn <jonahbenn@yahoo.com>
This commit is contained in:
@@ -49,11 +49,11 @@ PropertyManagementComponent::PropertyManagementComponent(Entity* parent) : Compo
|
||||
|
||||
auto result = query.execQuery();
|
||||
|
||||
if (result.eof() || result.fieldIsNull(0)) {
|
||||
if (result.eof() || result.fieldIsNull("id")) {
|
||||
return;
|
||||
}
|
||||
|
||||
templateId = result.getIntField(0);
|
||||
templateId = result.getIntField("id");
|
||||
|
||||
auto propertyInfo = Database::Get()->GetPropertyInfo(zoneId, cloneId);
|
||||
|
||||
@@ -105,7 +105,7 @@ std::vector<NiPoint3> PropertyManagementComponent::GetPaths() const {
|
||||
|
||||
std::vector<float> points;
|
||||
|
||||
std::istringstream stream(result.getStringField(0));
|
||||
std::istringstream stream(result.getStringField("path"));
|
||||
std::string token;
|
||||
|
||||
while (std::getline(stream, token, ' ')) {
|
||||
|
Reference in New Issue
Block a user