summaryrefslogtreecommitdiffstats
path: root/game/shared/world/dimension.cc
diff options
context:
space:
mode:
authoruntodesu <kirill@untode.su>2025-09-11 13:48:31 +0500
committeruntodesu <kirill@untode.su>2025-09-11 13:48:31 +0500
commitaaed751bf4430bf4b9b30cef532b8753b9f639ce (patch)
tree16bc751c272ba27ad53ec48dbdd3a6d9e6a8d4c2 /game/shared/world/dimension.cc
parent96bd73ae020ecca1f94698744c77498a89ad19f7 (diff)
downloadvoxelius-aaed751bf4430bf4b9b30cef532b8753b9f639ce.tar.bz2
voxelius-aaed751bf4430bf4b9b30cef532b8753b9f639ce.zip
Replace most of C strings with string_view
Diffstat (limited to 'game/shared/world/dimension.cc')
-rw-r--r--game/shared/world/dimension.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/game/shared/world/dimension.cc b/game/shared/world/dimension.cc
index 3389917..2d193fc 100644
--- a/game/shared/world/dimension.cc
+++ b/game/shared/world/dimension.cc
@@ -7,7 +7,7 @@
#include "shared/coord.hh"
#include "shared/globals.hh"
-world::Dimension::Dimension(const char* name, float gravity)
+world::Dimension::Dimension(std::string_view name, float gravity)
{
m_name = name;
m_gravity = gravity;
@@ -21,9 +21,9 @@ world::Dimension::~Dimension(void)
chunks.clear();
}
-const char* world::Dimension::get_name(void) const
+std::string_view world::Dimension::get_name(void) const
{
- return m_name.c_str();
+ return m_name;
}
float world::Dimension::get_gravity(void) const