From f8ad01ab7c4cf012781bd4caa821544e676c9267 Mon Sep 17 00:00:00 2001 From: Loïc Blot Date: Sun, 19 Mar 2017 08:44:29 +0100 Subject: Update server min protocol version to v24 (#5411) * Update server min protocol version to v24 It's based on @sfan5 stats. See https://kitsunemimi.pw/tmp/serverlist_stats_2017-03-17.txt v24 was bumped 25/08/14 and 0.4.11 was released 25/12/14 * Drop protocol v23 and lesser code --- src/itemdef.cpp | 35 +++++++++++++---------------------- 1 file changed, 13 insertions(+), 22 deletions(-) (limited to 'src/itemdef.cpp') diff --git a/src/itemdef.cpp b/src/itemdef.cpp index 5ba9d8f9a..f43e5c970 100644 --- a/src/itemdef.cpp +++ b/src/itemdef.cpp @@ -123,17 +123,13 @@ void ItemDefinition::reset() void ItemDefinition::serialize(std::ostream &os, u16 protocol_version) const { - if(protocol_version <= 17) - writeU8(os, 1); // version - else if(protocol_version <= 20) - writeU8(os, 2); // version - else - writeU8(os, 3); // version + + writeU8(os, 3); // version (proto > 20) writeU8(os, type); - os<serialize(tmp_os, protocol_version); tool_capabilities_s = tmp_os.str(); } - os<first); writeS16(os, i->second); } - os< 17){ - //serializeSimpleSoundSpec(sound_place, os); - os< 20) { - writeF1000(os, range); - os << serializeString(sound_place_failed.name); - writeF1000(os, sound_place_failed.gain); - } + os << serializeString(node_placement_prediction); + os << serializeString(sound_place.name); + writeF1000(os, sound_place.gain); + writeF1000(os, range); + os << serializeString(sound_place_failed.name); + writeF1000(os, sound_place_failed.gain); } void ItemDefinition::deSerialize(std::istream &is) -- cgit v1.2.3