… | |
… | |
425 | head = tmp; |
425 | head = tmp; |
426 | |
426 | |
427 | add_object_to_socklist (*pl->ns, sl, head); |
427 | add_object_to_socklist (*pl->ns, sl, head); |
428 | got_one++; |
428 | got_one++; |
429 | |
429 | |
430 | if (sl.length () >= (MAXSOCKBUF - MAXITEMLEN)) |
430 | if (sl.length () > MAXSOCKBUF - MAXITEMLEN) |
431 | { |
431 | { |
432 | pl->ns->send_packet (sl); |
432 | pl->ns->send_packet (sl); |
433 | |
433 | |
434 | sl.reset (); |
434 | sl.reset (); |
435 | sl.printf ("item%d ", pl->ns->itemcmd); |
435 | sl.printf ("item%d ", pl->ns->itemcmd); |
… | |
… | |
479 | |
479 | |
480 | /* IT is possible for players to accumulate a huge amount of |
480 | /* IT is possible for players to accumulate a huge amount of |
481 | * items (especially with some of the bags out there) to |
481 | * items (especially with some of the bags out there) to |
482 | * overflow the buffer. IF so, send multiple item commands. |
482 | * overflow the buffer. IF so, send multiple item commands. |
483 | */ |
483 | */ |
484 | if (sl.length () >= (MAXSOCKBUF - MAXITEMLEN)) |
484 | if (sl.length () > MAXSOCKBUF - MAXITEMLEN) |
485 | { |
485 | { |
486 | pl->contr->ns->send_packet (sl); |
486 | pl->contr->ns->send_packet (sl); |
487 | |
487 | |
488 | sl.reset (); |
488 | sl.reset (); |
489 | sl.printf ("item%d ", pl->contr->ns->itemcmd); |
489 | sl.printf ("item%d ", pl->contr->ns->itemcmd); |