major refactoring: db.Player is now core.Player

- misc. cleanup
- core/db/players.go: works with core.Player types, will also grab inventory table
This commit is contained in:
2023-03-22 00:30:58 -05:00
parent 735bdc5b36
commit 5b2a8b838e
20 changed files with 287 additions and 287 deletions

View File

@@ -0,0 +1,19 @@
package pool
import (
"bytes"
"sync"
)
var allocator = &sync.Pool{
New: func() any { return new(bytes.Buffer) },
}
func Get() *bytes.Buffer {
return allocator.Get().(*bytes.Buffer)
}
func Put(buf *bytes.Buffer) {
buf.Reset()
allocator.Put(buf)
}