ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/server/socket/request.C
(Generate patch)

Comparing deliantra/server/socket/request.C (file contents):
Revision 1.76 by root, Wed Mar 14 13:05:30 2007 UTC vs.
Revision 1.78 by root, Thu Mar 15 14:59:43 2007 UTC

562 * This is what takes care of it. We tell the client how things worked out. 562 * This is what takes care of it. We tell the client how things worked out.
563 * I am not sure if this file is the best place for this function. however, 563 * I am not sure if this file is the best place for this function. however,
564 * it either has to be here or init_sockets needs to be exported. 564 * it either has to be here or init_sockets needs to be exported.
565 */ 565 */
566void 566void
567AddMeCmd (char *buf, int len, client * ns) 567AddMeCmd (char *buf, int len, client *ns)
568{ 568{
569 // face caching is mandatory
570 if (!ns->facecache)
571 {
572 ns->send_drawinfo (
573 "\n"
574 "\n"
575 "***\n"
576 "*** WARNING:\n"
577 "*** Your client does not support face/image caching,\n"
578 "*** or it has been disabled. Face caching is mandatory\n"
579 "*** so please enable it or use a newer client.\n"
580 "***\n"
581 "*** Look at your client preferences:\n"
582 "***\n"
583 "*** CFPlus: all known versions automatically enable the facecache.\n"
584 "*** cfclient: use the -cache commandline option.\n"
585 "*** cfclient: map will not redraw automatically (bug).\n"
586 "*** gcfclient: use -cache commandline option, or enable\n"
587 "*** gcfclient: Client=>Configure=>Map & Image=>Cache Images.\n"
588 "*** jcrossclient: your client is broken, use CFPlus or gcfclient.\n"
589 "***\n"
590 "***\n",
591 NDI_RED
592 );
593
594 if (strstr (ns->version, "jcrossclient"))
595 /* let them, for now*/;
596 else
597 {
598 ns->flush ();
599 //ns->destroy ();
600 }
601 //ns->facecache = true;
602 }
603
569 INVOKE_CLIENT (ADDME, ns, ARG_DATA (buf, len)); 604 INVOKE_CLIENT (ADDME, ns, ARG_DATA (buf, len));
570} 605}
571 606
572/** Reply to ExtendedInfos command */ 607/** Reply to ExtendedInfos command */
573void 608void
681 snprintf (temp, sizeof (temp), "%d", i); 716 snprintf (temp, sizeof (temp), "%d", i);
682 strcat (cmdback, temp); 717 strcat (cmdback, temp);
683 } 718 }
684 719
685 ns->send_packet (cmdback); 720 ns->send_packet (cmdback);
721}
722
723/**
724 * client requested an image. send it rate-limited
725 * before flushing.
726 */
727void
728AskFaceCmd (char *buf, int len, client *ns)
729{
730 ns->askface.push_back (atoi (buf));
686} 731}
687 732
688/** 733/**
689 * Tells client the picture it has to use 734 * Tells client the picture it has to use
690 * to smooth a picture number given as argument. 735 * to smooth a picture number given as argument.
1251 << uint8 (extendedinfos) 1296 << uint8 (extendedinfos)
1252 << uint8 (eentrysize); 1297 << uint8 (eentrysize);
1253 1298
1254 estartlen = esl.length (); 1299 estartlen = esl.length ();
1255 } 1300 }
1256 else
1257 {
1258 /* suppress compiler warnings */
1259 ewhatstart = 0;
1260 ewhatflag = 0;
1261 estartlen = 0;
1262 }
1263 1301
1264 /* x,y are the real map locations. ax, ay are viewport relative 1302 /* x,y are the real map locations. ax, ay are viewport relative
1265 * locations. 1303 * locations.
1266 */ 1304 */
1267 ay = 0; 1305 ay = 0;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines