send all player's items to clients
This commit is contained in:
@@ -33,15 +33,10 @@ func (p *Player) StartGroup(rng *RNG, items int) {
|
||||
func (p *Player) DTO() serve.Player {
|
||||
r := serve.Player{
|
||||
HP: p.hp,
|
||||
Items: make([]string, 0, 8),
|
||||
Cuffs: p.cuffs != Uncuffed,
|
||||
}
|
||||
for _, i := range p.items {
|
||||
s := i.String()
|
||||
if s == "" {
|
||||
continue
|
||||
}
|
||||
r.Items = append(r.Items, s)
|
||||
for k, i := range p.items {
|
||||
r.Items[k] = i.String()
|
||||
}
|
||||
return r
|
||||
}
|
||||
|
Reference in New Issue
Block a user