From: Keith F. <ven...@us...> - 2007-02-24 03:56:14
|
Update of /cvsroot/planeshift/planeshift/src/common/net In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv3574/src/common/net Modified Files: messages.h Log Message: - I think dropping items in world and picking them up again now save properly, but this critical feature needs more testing. The big difference now is that the system allows character ownership of items on the ground, so now the loc_sector_id is used to decide if the item is "in world" or not. - Also, now when you drop an item, it appears in the map at the location of your mouse instead of at your feet. - Added yet more printf's (sorry) Index: messages.h =================================================================== RCS file: /cvsroot/planeshift/planeshift/src/common/net/messages.h,v retrieving revision 1.414 retrieving revision 1.415 diff -C2 -d -r1.414 -r1.415 *** messages.h 23 Feb 2007 21:06:04 -0000 1.414 --- messages.h 24 Feb 2007 03:56:07 -0000 1.415 *************** *** 3223,3229 **** int toSlotID, int toParentContainerID, ! int stackCount ) { ! msg = new MsgEntry( sizeof( int32_t ) * 7 ); msg->SetType(MSGTYPE_SLOT_MOVEMENT); --- 3223,3230 ---- int toSlotID, int toParentContainerID, ! int stackCount, ! csVector3 *pt3d=NULL) { ! msg = new MsgEntry( sizeof( int32_t ) * 7 + 3 * sizeof(float) ); msg->SetType(MSGTYPE_SLOT_MOVEMENT); *************** *** 3237,3240 **** --- 3238,3248 ---- msg->Add( (int32_t) toParentContainerID ); msg->Add( (int32_t) stackCount ); + if (pt3d != NULL) + msg->Add( *pt3d ); + else + { + csVector3 v = 0; + msg->Add(v); // add dummy zeroes if not specified. + } } *************** *** 3248,3251 **** --- 3256,3260 ---- toParentContainer = me->GetInt32(); stackCount = me->GetInt32(); + posWorld = me->GetVector(); } *************** *** 3267,3270 **** --- 3276,3280 ---- int toParentContainer; int stackCount; + csVector3 posWorld; }; |