mirror of
https://github.com/Mezeporta/Erupe.git
synced 2025-12-13 15:34:38 +01:00
Merge pull request #88 from legayacruise/legayacruise-patch-1
Correct leftover instances of "gook" to goocoo
This commit is contained in:
@@ -789,20 +789,20 @@ func getGookData(s *Session, cid uint32) (uint16, []byte) {
|
|||||||
var count uint16
|
var count uint16
|
||||||
bf := byteframe.NewByteFrame()
|
bf := byteframe.NewByteFrame()
|
||||||
for i := 0; i < 5; i++ {
|
for i := 0; i < 5; i++ {
|
||||||
err := s.server.db.QueryRow(fmt.Sprintf("SELECT gook%d FROM gook WHERE id=$1", i), cid).Scan(&data)
|
err := s.server.db.QueryRow(fmt.Sprintf("SELECT goocoo%d FROM goocoo WHERE id=$1", i), cid).Scan(&data)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
s.server.db.Exec("INSERT INTO gook (id) VALUES ($1)", s.charID)
|
s.server.db.Exec("INSERT INTO goocoo (id) VALUES ($1)", s.charID)
|
||||||
return 0, bf.Data()
|
return 0, bf.Data()
|
||||||
}
|
}
|
||||||
if err == nil && data != nil {
|
if err == nil && data != nil {
|
||||||
count++
|
count++
|
||||||
if s.charID == cid && count == 1 {
|
if s.charID == cid && count == 1 {
|
||||||
gook := byteframe.NewByteFrameFromBytes(data)
|
goocoo := byteframe.NewByteFrameFromBytes(data)
|
||||||
bf.WriteBytes(gook.ReadBytes(4))
|
bf.WriteBytes(goocoo.ReadBytes(4))
|
||||||
d := gook.ReadBytes(2)
|
d := goocoo.ReadBytes(2)
|
||||||
bf.WriteBytes(d)
|
bf.WriteBytes(d)
|
||||||
bf.WriteBytes(d)
|
bf.WriteBytes(d)
|
||||||
bf.WriteBytes(gook.DataFromCurrent())
|
bf.WriteBytes(goocoo.DataFromCurrent())
|
||||||
} else {
|
} else {
|
||||||
bf.WriteBytes(data)
|
bf.WriteBytes(data)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user