Add: support filtering content entries for patchpacks

This changes nothing for us, but allows patchpacks to add the
right pieces of code to start filtering content entries on patchpack
only entries.

(cherry picked from commit 77860bb61e61307e4d9cf869ba62be8ca4d9d9b3)
This commit is contained in:
Patric Stout
2021-09-05 13:30:05 +02:00
committed by Jonathan G Rennison
parent 3c55250cd6
commit 84cba1b842
4 changed files with 27 additions and 2 deletions

View File

@@ -207,7 +207,20 @@ void ClientNetworkContentSocketHandler::RequestContentList(ContentType type)
Packet *p = new Packet(PACKET_CONTENT_CLIENT_INFO_LIST);
p->Send_uint8 ((byte)type);
p->Send_uint32(_openttd_newgrf_version);
p->Send_uint32(0xffffffff);
p->Send_uint8 (1);
p->Send_string("vanilla");
p->Send_string(_openttd_content_version);
/* Patchpacks can extend the list with one. In BaNaNaS metadata you can
* add a branch in the 'compatibility' list, to filter on this. If you want
* your patchpack to be mentioned in the BaNaNaS web-interface, create an
* issue on https://github.com/OpenTTD/bananas-api asking for this.
p->Send_string("patchpack"); // Or what-ever the name of your patchpack is.
p->Send_string(_openttd_content_version_patchpack);
*/
this->SendPacket(p);
}