File tree Expand file tree Collapse file tree 2 files changed +27
-0
lines changed
GeneralsMD/Code/GameEngine Expand file tree Collapse file tree 2 files changed +27
-0
lines changed Original file line number Diff line number Diff line change @@ -260,6 +260,9 @@ class LANAPI : public LANAPIInterface
260260 void addGame (LANGameInfo *game);
261261 AsciiString createSlotString ( void );
262262
263+ void setProductInfoFromLocalData (GameSlot *slot);
264+ void setProductInfoFromMessage (LANMessage *msg, GameSlot *slot);
265+
263266 // Functions to handle incoming messages -----------------------------------
264267 void handleRequestLocations ( LANMessage *msg, UnsignedInt senderIP );
265268 void handleGameAnnounce ( LANMessage *msg, UnsignedInt senderIP );
Original file line number Diff line number Diff line change 4141#include " GameNetwork/LANAPICallbacks.h"
4242#include " GameClient/MapUtil.h"
4343
44+ void LANAPI::setProductInfoFromLocalData (GameSlot *slot)
45+ {
46+ GameSlot::ProductInfo productInfo;
47+ productInfo.exeCRC = TheGlobalData->m_exeCRC ;
48+ productInfo.iniCRC = TheGlobalData->m_iniCRC ;
49+ productInfo.productVersion = TheVersion->getVersionNumber ();
50+ productInfo.gitTagOrHash = TheVersion->getAsciiGitTagOrHash ();
51+ productInfo.productName = TheVersion->getUnicodeProductString ();
52+
53+ slot->setProductInfo (productInfo);
54+ }
55+
56+ void LANAPI::setProductInfoFromMessage (LANMessage *msg, GameSlot *slot)
57+ {
58+ GameSlot::ProductInfo productInfo;
59+ productInfo.exeCRC = msg->ProductInfo .exeCRC ;
60+ productInfo.iniCRC = msg->ProductInfo .iniCRC ;
61+ productInfo.productVersion = msg->ProductInfo .productVersion ;
62+ productInfo.gitTagOrHash = msg->ProductInfo .gitTagOrHash ;
63+ productInfo.productName = msg->ProductInfo .productName ;
64+
65+ slot->setProductInfo (productInfo);
66+ }
67+
4468void LANAPI::sendProductInfoMessage (Int messageType, UnsignedInt senderIP)
4569{
4670 LANMessage msg;
You can’t perform that action at this time.
0 commit comments