Closed EntenKoeniq-OLD closed 2 years ago
With "std::string" you create a copy of the string, but we don't need it.
Here is an example that it works:
class Sound { private: std::string set; public: Sound(const std::string& set) { this->set = set; } void PlayFrontend() { std::cout << this->set; } }; int main() { Sound* testSound = new Sound("test 123"); testSound->PlayFrontend(); delete testSound; return 0; }
Hey, sorry for the late answer but I ended up moving the C++ version to it's own repo. Please check the LemonUI_CPP repository.
With "std::string" you create a copy of the string, but we don't need it.
Here is an example that it works: