Page history
From Melvor Idle
1 April 2024
Add tostring metafunction
m+68
Created page with "local StringBuilder = {} StringBuilder.__index = StringBuilder -- Constructor function StringBuilder.new() local self = setmetatable({}, StringBuilder) self.buffer = {} return self end -- Append method function StringBuilder:append(value) if value then table.insert(self.buffer, tostring(value)) end return self end function StringBuilder:appendLine(value) if value then table.insert(self.buffer, tostring(value)) end table.insert(self.buffer,..."
+721