From 4ccc99b291d7aa9ccb3e3c56f9d63bf30e02b0b9 Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Sat, 30 Jul 2011 21:16:36 +0300 Subject: [PATCH 01/24] updated version to rc2, rolling out new windows test binary --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 860bbba00..dc6f45a59 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -9,7 +9,7 @@ project(minetest) set(VERSION_MAJOR 0) set(VERSION_MINOR 2) -set(VERSION_PATCH 20110730_rc1) +set(VERSION_PATCH 20110730_rc2) set(VERSION_STRING "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}") # Configuration options From 8e1eacf3a87a0cee39c8c27c3846828c12e73f9d Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Sat, 30 Jul 2011 23:33:57 +0300 Subject: [PATCH 02/24] Fixed handling of inventory in creative mode (normal inventory is not trashed anymore), fixed mese pick speed, added some forgotten stuff --- data/cooked_rat.png | Bin 0 -> 239 bytes data/nc_back.png | Bin 0 -> 303 bytes data/nc_front.png | Bin 0 -> 410 bytes data/nc_rb.png | Bin 0 -> 203 bytes data/nc_side.png | Bin 0 -> 260 bytes data/scorched_stuff.png | Bin 0 -> 233 bytes src/content_mapnode.cpp | 19 ++++++++++++++++- src/content_mapnode.h | 2 ++ src/mapgen.cpp | 45 ++++++++++++++++++++++++++++++++++++++++ src/mapnode.h | 3 +++ src/player.cpp | 11 ++++++++-- src/player.h | 2 ++ src/server.cpp | 10 +++++++++ 13 files changed, 89 insertions(+), 3 deletions(-) create mode 100644 data/cooked_rat.png create mode 100644 data/nc_back.png create mode 100644 data/nc_front.png create mode 100644 data/nc_rb.png create mode 100644 data/nc_side.png create mode 100644 data/scorched_stuff.png diff --git a/data/cooked_rat.png b/data/cooked_rat.png new file mode 100644 index 0000000000000000000000000000000000000000..daad3be0d19a741831bd9e1123846c19b580ca78 GIT binary patch literal 239 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`EX7WqAsj$Z!;#Vf4nJ z@ErkR#;MwT(m=t9o-U3d7QJVKqInM}2xzBh2{bVBBry0_96G?0kifLzpxuewC&!W% zBRADeeR3;XpJ9LFHJ!I)wt|enSA|Z?Hqo?4;cQcy?k98J gQ(9m5^L+tRu)W@od+PaZK*uq7y85}Sb4q9e0K#%s{r~^~ literal 0 HcmV?d00001 diff --git a/data/nc_back.png b/data/nc_back.png new file mode 100644 index 0000000000000000000000000000000000000000..f09f41658330f559dddc804e0f48fe94637d7e11 GIT binary patch literal 303 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`EX7WqAsj$Z!;#Vf4nJ z@ErkR#;MwT(m=tBo-U3d7QJ(W5Aq%|5csS*S0l)L!D5F5W-Crx3C_+=g=db9*^?cv zPX2V_r1f{y)b^Kl=HN8~pz$77t0;M3wzKW|Wr%E;|&*U|nBar-OEsOsDbx$6x@7?&$ z?}5vti`G{zF7el5nsn%j+cr(14V6B1T^lX>Od1MPR!9X`iz wIJjx|Wc7H=9e0#pEpvADlR;9$FbqZCx66gvE6|Iu zu)_`LMTiy7R8G`dEaHTibQlKBcw^~*Ju4BMFAn_goG&iG@1GO#IDjhm>%?ynj|qTT zlQ=AwWg4MI;xXao55>xnQVNn*qp&7DAUS4+vL1+q*@)EV4qcH%trasPWZ|oSWtt}3 z_hg6NO^ad%RHP@MJ`}g6ax3rP0T;OY4)Z4^%yl_ug1dtvwbACB8HVAZIHg2NslyKt zIy^}`+{JL)-QBqb&GlpXATx^$0ReIA1Y6_O{552PJR&M>0A0uBor^f<{7u))#Vl=8 z?~!qDpR%qwv$4(U_1ob7IT23-R>lrhR8Z_^q9=y*!fpF21Kh8L!)b#^K-3v;J5$Yj zz*@BlcgJjGvJp||E)HgfwI}YE?fGrLriy=BXFXs13k7}4h*nSCQ~&?~07*qoM6N<$ Ef`X^5s{jB1 literal 0 HcmV?d00001 diff --git a/data/nc_rb.png b/data/nc_rb.png new file mode 100644 index 0000000000000000000000000000000000000000..7ebc9930d42866f70bba6e07a6f7c4affd0bc3da GIT binary patch literal 203 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`EX7WqAsj$Z!;#Vf4nJ z@ErkR#;MwT(m=snPZ!4!i{7P|14SDY1Y9mknobN`&^4oxsqBJJnqgCRbFIAf{sXBG z8t%HS5U3C0I+J^a;nXAT`2y?=TbOena6EV4@i~!A;hxg|Bkt=MZ#aZ6IdE+uBjb$) u>n#foTRSjFUr4`oe=}RavQtT(zZf4Ts++F4S*!-Mn8DN4&t;ucLK6U8heQhi literal 0 HcmV?d00001 diff --git a/data/nc_side.png b/data/nc_side.png new file mode 100644 index 0000000000000000000000000000000000000000..f954045fbd9ce5fbc95a8da665575ed0574d4eb5 GIT binary patch literal 260 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`EX7WqAsj$Z!;#Vf4nJ z@ErkR#;MwT(m=swo-U3d7QJ(WZ}T2D;IJuBTXltZQs6I%h4)l)-MX%HN?o2Gw$x0` z&u>$Uz;os!jLsqqzwZgOGMxBSlfZxIVUM4Bg`KJ3<-%WuF`sHpl4DPwSm-%@wXF6O z`4BE&Mg||3*&I6=x;y-ftX?r}Fg^N8LVnMT11=}S)|D=q$l@b(ZEC4qeA1zy_ZNfC zO@A>-=BfU_JsZAG;nsg4o$p?+o$Iym?A)%;4$j=d#Wzp$P!f C^4nJ z@ErkR#;MwT(m=s(PZ!4!i{7(Aw|N^Bc=kx8CrU3%m7ccJUaVj2!iQ90r^Y+Y%n!~l zom|)Ll3BBU4pYMIlOi=fAyZ{}=IGoMZIBXd{JTfxa{^CC8{e+VMfdi0Tv)gvX{GPZ z)z$Y4E=g@Wwjk*7F5x9tOqZ+M98qYlWvJS;YO{IJ(;$YV{|-G*blK-~%Cl78x&8Ie aRy{$3__d~{M>YYS#o+1c=d#Wzp$Py!<5X<` literal 0 HcmV?d00001 diff --git a/src/content_mapnode.cpp b/src/content_mapnode.cpp index db036ebd9..b6b7a6e53 100644 --- a/src/content_mapnode.cpp +++ b/src/content_mapnode.cpp @@ -474,13 +474,30 @@ void content_mapnode_init() f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; setStoneLikeDiggingProperties(f->digging_properties, 5.0); + i = CONTENT_NC; + f = &content_features(i); + f->param_type = CPT_FACEDIR_SIMPLE; + f->setAllTextures("nc_side.png"); + f->setTexture(5, "nc_front.png"); // Z- + f->setTexture(4, "nc_back.png"); // Z+ + f->setInventoryTexture("nc_front.png"); + f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + setStoneLikeDiggingProperties(f->digging_properties, 3.0); + + i = CONTENT_NC_RB; + f = &content_features(i); + f->setAllTextures("nc_rb.png"); + f->setInventoryTexture("nc_rb.png"); + f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + setStoneLikeDiggingProperties(f->digging_properties, 3.0); + // NOTE: Remember to add frequently used stuff to the texture atlas in tile.cpp /* Add MesePick to everything */ - for(u16 i=0; i<256; i++) + for(u16 i=0; i<=MAX_CONTENT; i++) { content_features(i).digging_properties.set("MesePick", DiggingProperties(true, 0.0, 65535./1337)); diff --git a/src/content_mapnode.h b/src/content_mapnode.h index 5fdbf45f3..7be26518f 100644 --- a/src/content_mapnode.h +++ b/src/content_mapnode.h @@ -70,6 +70,8 @@ MapNode mapnode_translate_to_internal(MapNode n_from, u8 version); #define CONTENT_BOOKSHELF 0x814 //29 #define CONTENT_JUNGLETREE 0x815 #define CONTENT_JUNGLEGRASS 0x816 +#define CONTENT_NC 0x817 +#define CONTENT_NC_RB 0x818 #endif diff --git a/src/mapgen.cpp b/src/mapgen.cpp index 0ba7f91ab..5dec7d843 100644 --- a/src/mapgen.cpp +++ b/src/mapgen.cpp @@ -976,6 +976,40 @@ static void make_dungeon1(VoxelManipulator &vmanip, PseudoRandom &random) } } +static void make_nc(VoxelManipulator &vmanip, PseudoRandom &random) +{ + v3s16 dir; + u8 facedir_i = 0; + s32 r = random.range(0, 3); + if(r == 0){ + dir = v3s16( 1, 0, 0); + facedir_i = 3; + } + if(r == 1){ + dir = v3s16(-1, 0, 0); + facedir_i = 1; + } + if(r == 2){ + dir = v3s16( 0, 0, 1); + facedir_i = 2; + } + if(r == 3){ + dir = v3s16( 0, 0,-1); + facedir_i = 0; + } + v3s16 p = vmanip.m_area.MinEdge + v3s16( + 16+random.range(0,15), + 16+random.range(0,15), + 16+random.range(0,15)); + vmanip.m_data[vmanip.m_area.index(p)] = MapNode(CONTENT_NC, facedir_i); + u32 length = random.range(3,15); + for(u32 j=0; jserialize(os); + else + inventory.serialize(os); } void Player::deSerialize(std::istream &is) diff --git a/src/player.h b/src/player.h index a7a2433ce..29460e1e1 100644 --- a/src/player.h +++ b/src/player.h @@ -121,6 +121,8 @@ public: bool swimming_up; Inventory inventory; + // Actual inventory is backed up here when creative mode is used + Inventory *inventory_backup; bool craftresult_is_preview; diff --git a/src/server.cpp b/src/server.cpp index 07f9875c4..503d60b84 100644 --- a/src/server.cpp +++ b/src/server.cpp @@ -4130,6 +4130,11 @@ Player *Server::emergePlayer(const char *name, const char *password, u16 peer_id // Reset inventory to creative if in creative mode if(g_settings.getBool("creative_mode")) { + // Warning: double code below + // Backup actual inventory + player->inventory_backup = new Inventory(); + *(player->inventory_backup) = player->inventory; + // Set creative inventory craft_set_creative_inventory(player); } @@ -4183,6 +4188,11 @@ Player *Server::emergePlayer(const char *name, const char *password, u16 peer_id if(g_settings.getBool("creative_mode")) { + // Warning: double code above + // Backup actual inventory + player->inventory_backup = new Inventory(); + *(player->inventory_backup) = player->inventory; + // Set creative inventory craft_set_creative_inventory(player); } else if(g_settings.getBool("give_initial_stuff")) From bb9650aed989b917a745eac39871c09caf5aaa5b Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Sat, 30 Jul 2011 23:34:16 +0300 Subject: [PATCH 03/24] updated example config --- minetest.conf.example | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/minetest.conf.example b/minetest.conf.example index b81cc5fc6..4b1600609 100644 --- a/minetest.conf.example +++ b/minetest.conf.example @@ -108,9 +108,8 @@ screenH# = 600 # Map directory (everything in the world is stored here) #map-#dir = /custom/map -# Set to true to enable experimental features or stuff that is tested -# (varies from version to version, usually not useful at all) -#enable_experimental = false +# Message of the Day +#motd = Welcome to this awesome Minetest server! # Set to true to enable creative mode (unlimited inventory) #creative_mode = false #enable_damage = false @@ -119,10 +118,13 @@ screenH# = 600 #default_password = # Available privileges: build, teleport, settime, privs, shout #default_privs = build, shout + +# Set to true to enable experimental features or stuff that is tested +# (varies from version to version, usually not useful at all) +#enable_experimental = false # Profiler data print interval. #0 = disable. #profiler_print_interval = 0 #enable_mapgen_debug_info = false - # Player and object positions are sent at intervals specified by this #objectdata_interval = 0.2 #active_object_range = 2 From 17a85b947cee830709be05a702b38d89fc6d6901 Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Sat, 30 Jul 2011 23:54:16 +0300 Subject: [PATCH 04/24] added sword textures --- data/tool_steelsword.png | Bin 0 -> 291 bytes data/tool_stonesword.png | Bin 0 -> 301 bytes data/tool_woodsword.png | Bin 0 -> 255 bytes 3 files changed, 0 insertions(+), 0 deletions(-) create mode 100644 data/tool_steelsword.png create mode 100644 data/tool_stonesword.png create mode 100644 data/tool_woodsword.png diff --git a/data/tool_steelsword.png b/data/tool_steelsword.png new file mode 100644 index 0000000000000000000000000000000000000000..a74581238cad9a6f90e319a980b4c83eda9e8e2e GIT binary patch literal 291 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`EX7WqAsj$Z!;#Vf4nJ z@ErkR#;MwT(m=tZo-U3d7QIU+EAkz35ODo3XOs$>?^fg~>&w^z4~5A+G0@d`ek1r4GE+ z@AubS<%pdz^WYgb(GUD`JQ7XyOs{y2H(xx!VDMHdavEa;*E?CoUS&&}^D9n zw|mmrB)w}Z3>2AkEHL79#@tQC ieBZBI|JdpFn)%q8QW-YJTvnim7(8A5T-G@yGywn4nJ z@ErkR#;MwT(m=uUo-U3d7QIU^EAkyO5Mg_;zooEgW~$KPBX3yPHA3$&^{08-)|o%x z64u|m!_%$l;Dk=8yatUd-)*MZ(`~QrdGdSm_ghTd-Dg>yIPT8v>{$Ekka4)EV_Tk%?I{rmiH&!b}M*B&k?-1RTuCeUjPp00i_>zopr05S$~;Q#;t literal 0 HcmV?d00001 diff --git a/data/tool_woodsword.png b/data/tool_woodsword.png new file mode 100644 index 0000000000000000000000000000000000000000..d6c6be3254274acdd5a95665a580ad68dcfcb50e GIT binary patch literal 255 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`EX7WqAsj$Z!;#Vf4nJ z@ErkR#;MwT(m=t5o-U3d7QM*{3(PNwB>s(mu>9kF&(6>G%s?Q#a@O6oQzZ3bD>=lK zZ!wgdJ#YUvF#!Zr!asjC-!Iu|#4tatiA~^APh!I|j@R{UY;0|>^XrU-7SC*C^j6pv zttp&p?596rk>ql2peZL7ELZjqFm7XHt&{q%59BN8>YgoldCGZ5`3K2{M Date: Sat, 30 Jul 2011 23:54:34 +0300 Subject: [PATCH 05/24] added one temporary directory to .hgignore --- .hgignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.hgignore b/.hgignore index 964b22bd9..e4e0caada 100644 --- a/.hgignore +++ b/.hgignore @@ -22,3 +22,4 @@ CPackSourceConfig.cmake Makefile cmake_install.cmake src/jthread/libjthread.a +data_temp/* From 05d0eaf5fc4947081ae743a58e8675991e3f2422 Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Sun, 31 Jul 2011 00:39:43 +0300 Subject: [PATCH 06/24] added windows icon --- minetest-icon.ico | Bin 0 -> 9662 bytes src/CMakeLists.txt | 5 +++++ src/winresource.rc | 6 ++++++ 3 files changed, 11 insertions(+) create mode 100644 minetest-icon.ico create mode 100644 src/winresource.rc diff --git a/minetest-icon.ico b/minetest-icon.ico new file mode 100644 index 0000000000000000000000000000000000000000..82af67bf918ad7683dfc7b63da97757d8b37d23c GIT binary patch literal 9662 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 literal 0 HcmV?d00001 diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 8ce69b2ad..9bb266784 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -128,6 +128,11 @@ set(common_SRCS base64.cpp ) +# This gives us the icon +if(WIN32 AND MSVC) + set(common_SRCS ${common_SRCS} winresource.rc) +endif() + # Client sources set(minetest_SRCS ${common_SRCS} diff --git a/src/winresource.rc b/src/winresource.rc new file mode 100644 index 000000000..24ec445aa --- /dev/null +++ b/src/winresource.rc @@ -0,0 +1,6 @@ +#include +#include +#include +LANGUAGE 0, SUBLANG_NEUTRAL +130 ICON "..\\minetest-icon.ico" +//131 BITMAP "..\\minetest-icon.bmp" From 149875607ca926e99bdc6c855e56aba8569bb1a9 Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Sun, 31 Jul 2011 00:51:18 +0300 Subject: [PATCH 07/24] updated CMakeList.txts a bit --- CMakeLists.txt | 7 ++++++- src/CMakeLists.txt | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index dc6f45a59..514175e9e 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -21,7 +21,11 @@ else() endif() set(BUILD_CLIENT 1 CACHE BOOL "Build client") -set(BUILD_SERVER 1 CACHE BOOL "Build server") +if(WIN32) + set(BUILD_SERVER 0 CACHE BOOL "Build server") +else() + set(BUILD_SERVER 1 CACHE BOOL "Build server") +endif() set(WARN_ALL 1 CACHE BOOL "Enable -Wall for Release build") @@ -60,6 +64,7 @@ elseif(UNIX) # Linux, BSD etc endif() install(FILES "doc/README.txt" DESTINATION "${DOCDIR}") +install(FILES "doc/changelog.txt" DESTINATION "${DOCDIR}") install(FILES "minetest.conf.example" DESTINATION "${DOCDIR}") # diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 9bb266784..4d51f7104 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -130,7 +130,7 @@ set(common_SRCS # This gives us the icon if(WIN32 AND MSVC) - set(common_SRCS ${common_SRCS} winresource.rc) + set(common_SRCS ${common_SRCS} winresource.rc) endif() # Client sources From 88a266db127ee84070dca5bf270fd811fef5bff3 Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Sun, 31 Jul 2011 01:07:31 +0300 Subject: [PATCH 08/24] Updated CMakeLists, changelog and example config for release --- CMakeLists.txt | 2 +- doc/changelog.txt | 14 ++++++++++++++ minetest.conf.example | 2 ++ 3 files changed, 17 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 514175e9e..b0bc4796c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -9,7 +9,7 @@ project(minetest) set(VERSION_MAJOR 0) set(VERSION_MINOR 2) -set(VERSION_PATCH 20110730_rc2) +set(VERSION_PATCH 20110731_0) set(VERSION_STRING "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}") # Configuration options diff --git a/doc/changelog.txt b/doc/changelog.txt index 58d28d236..a7ab817b7 100644 --- a/doc/changelog.txt +++ b/doc/changelog.txt @@ -3,6 +3,20 @@ Minetest-c55 changelog This should contain all the major changes. For minor stuff, refer to the commit log of the repository. +2011-07-31: +- A number of small fixes, build system stuff and such (refer to version control log) +- Map generator no longer crashes at generation limit +- Fixed mapgen producing lots of cut-down trees +- Some minor tweaks in map generator (some contributed) +- Volumetric clouds (contributed) +- Icon added (graphic contributed) +- Key configuration menu (contributed) +- Decorative blocks and items: bookshelf, sandstone, cactus, clay, brick, papyrus, rail, paper, book (contributed) +- Jungles! +- Hotbar is a bit smaller +- Health is now enabled by default; You can now eat cooked rats to heal yourself. +- Finally added sword textures, altough sword is still of no use + 2011-07-04: - Many small fixes - Code reorganizing to aid further development diff --git a/minetest.conf.example b/minetest.conf.example index 4b1600609..c47ac77ce 100644 --- a/minetest.conf.example +++ b/minetest.conf.example @@ -95,6 +95,8 @@ screenH# = 600 #invert_mouse = false # FarMesh thingy #enable_farmesh = false +#farmesh_trees = true +#farmesh_distance = 40 # Enable/disable clouds #enable_clouds = true # Don't draw stone (for testing) From d7a5eea862ffa0602b848d3e70ae07cd50184bbd Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Sun, 31 Jul 2011 01:14:56 +0300 Subject: [PATCH 09/24] changelog update and disable motd by default --- doc/changelog.txt | 1 + src/defaultsettings.cpp | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/doc/changelog.txt b/doc/changelog.txt index a7ab817b7..4c77fe1f8 100644 --- a/doc/changelog.txt +++ b/doc/changelog.txt @@ -16,6 +16,7 @@ For minor stuff, refer to the commit log of the repository. - Hotbar is a bit smaller - Health is now enabled by default; You can now eat cooked rats to heal yourself. - Finally added sword textures, altough sword is still of no use +- Creative mode now preserves normal mode inventory 2011-07-04: - Many small fixes diff --git a/src/defaultsettings.cpp b/src/defaultsettings.cpp index c1104eff0..91524a6de 100644 --- a/src/defaultsettings.cpp +++ b/src/defaultsettings.cpp @@ -77,7 +77,7 @@ void set_default_settings() g_settings.setDefault("screenshot_path", "."); // Server stuff - g_settings.setDefault("motd", ""); + g_settings.setDefault("motd", ""); g_settings.setDefault("enable_experimental", "false"); g_settings.setDefault("creative_mode", "false"); g_settings.setDefault("enable_damage", "true"); From 306bb667908bae69d2c68ede64ef9007fd25fb78 Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Sun, 31 Jul 2011 01:16:18 +0300 Subject: [PATCH 10/24] Added tag 0.2.20110731_0 for changeset 06c62112b503 --- .hgtags | 1 + 1 file changed, 1 insertion(+) diff --git a/.hgtags b/.hgtags index 2911487cf..17ef94f5c 100644 --- a/.hgtags +++ b/.hgtags @@ -16,3 +16,4 @@ dd08a9b5cb84d55b7576bb3fde3068dd263bc3bc 0.2.20110618_0_dev 0000000000000000000000000000000000000000 0.2.20110704_0 0000000000000000000000000000000000000000 0.2.20110704_0 65263ec55caf526e3f3e0bdc6657ce42daee46bc 0.2.20110704_0 +06c62112b503e746d5d8cc40f951974447d590b7 0.2.20110731_0 From d6a9bec8430e39b380d3fc7b1f92683d4d02c33e Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Sun, 31 Jul 2011 02:20:40 +0300 Subject: [PATCH 11/24] Added MaterialItem conversion from old content type namespace to new --- CMakeLists.txt | 2 +- src/content_mapnode.cpp | 62 ++++++++++++++++++++--------------------- src/content_mapnode.h | 2 ++ src/inventory.cpp | 27 ++++++++++++++++++ src/inventory.h | 2 +- src/mapnode.cpp | 2 +- 6 files changed, 63 insertions(+), 34 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index b0bc4796c..dad072fd7 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -9,7 +9,7 @@ project(minetest) set(VERSION_MAJOR 0) set(VERSION_MINOR 2) -set(VERSION_PATCH 20110731_0) +set(VERSION_PATCH 20110731_1) set(VERSION_STRING "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}") # Configuration options diff --git a/src/content_mapnode.cpp b/src/content_mapnode.cpp index b6b7a6e53..7589f06ed 100644 --- a/src/content_mapnode.cpp +++ b/src/content_mapnode.cpp @@ -31,7 +31,7 @@ void setStoneLikeDiggingProperties(DiggingPropertiesList &list, float toughness) void setDirtLikeDiggingProperties(DiggingPropertiesList &list, float toughness); void setWoodLikeDiggingProperties(DiggingPropertiesList &list, float toughness); -content_t trans_table_19[][2] = { +content_t trans_table_19[21][2] = { {CONTENT_GRASS, 1}, {CONTENT_TREE, 4}, {CONTENT_LEAVES, 5}, @@ -106,7 +106,7 @@ void content_mapnode_init() f->setInventoryTextureCube("stone.png", "stone.png", "stone.png"); f->param_type = CPT_MINERAL; f->is_ground_content = true; - f->dug_item = std::string("MaterialItem ")+itos(CONTENT_COBBLE)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(CONTENT_COBBLE)+" 1"; setStoneLikeDiggingProperties(f->digging_properties, 1.0); if(invisible_stone) f->solidness = 0; // For debugging, hides regular stone @@ -118,7 +118,7 @@ void content_mapnode_init() f->setTexture(1, "mud.png"); f->param_type = CPT_MINERAL; f->is_ground_content = true; - f->dug_item = std::string("MaterialItem ")+itos(CONTENT_MUD)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(CONTENT_MUD)+" 1"; setDirtLikeDiggingProperties(f->digging_properties, 1.0); i = CONTENT_GRASS_FOOTSTEPS; @@ -128,7 +128,7 @@ void content_mapnode_init() f->setTexture(1, "mud.png"); f->param_type = CPT_MINERAL; f->is_ground_content = true; - f->dug_item = std::string("MaterialItem ")+itos(CONTENT_MUD)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(CONTENT_MUD)+" 1"; setDirtLikeDiggingProperties(f->digging_properties, 1.0); i = CONTENT_MUD; @@ -137,7 +137,7 @@ void content_mapnode_init() f->setInventoryTextureCube("mud.png", "mud.png", "mud.png"); f->param_type = CPT_MINERAL; f->is_ground_content = true; - f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; setDirtLikeDiggingProperties(f->digging_properties, 1.0); i = CONTENT_SAND; @@ -146,7 +146,7 @@ void content_mapnode_init() f->setInventoryTextureCube("sand.png", "sand.png", "sand.png"); f->param_type = CPT_MINERAL; f->is_ground_content = true; - f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; setDirtLikeDiggingProperties(f->digging_properties, 1.0); i = CONTENT_GRAVEL; @@ -155,7 +155,7 @@ void content_mapnode_init() f->setInventoryTextureCube("gravel.png", "gravel.png", "gravel.png"); f->param_type = CPT_MINERAL; f->is_ground_content = true; - f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; setDirtLikeDiggingProperties(f->digging_properties, 1.75); i = CONTENT_SANDSTONE; @@ -164,7 +164,7 @@ void content_mapnode_init() f->setInventoryTextureCube("sandstone.png", "sandstone.png", "sandstone.png"); f->param_type = CPT_MINERAL; f->is_ground_content = true; - f->dug_item = std::string("MaterialItem ")+itos(CONTENT_SAND)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(CONTENT_SAND)+" 1"; setDirtLikeDiggingProperties(f->digging_properties, 1.0); i = CONTENT_CLAY; @@ -192,7 +192,7 @@ void content_mapnode_init() f->setTexture(1, "tree_top.png"); f->param_type = CPT_MINERAL; f->is_ground_content = true; - f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; setWoodLikeDiggingProperties(f->digging_properties, 1.0); i = CONTENT_JUNGLETREE; @@ -202,7 +202,7 @@ void content_mapnode_init() f->setTexture(1, "jungletree_top.png"); f->param_type = CPT_MINERAL; //f->is_ground_content = true; - f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; setWoodLikeDiggingProperties(f->digging_properties, 1.0); i = CONTENT_JUNGLEGRASS; @@ -212,7 +212,7 @@ void content_mapnode_init() f->param_type = CPT_LIGHT; //f->is_ground_content = true; f->air_equivalent = false; // grass grows underneath - f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; f->solidness = 0; // drawn separately, makes no faces f->walkable = false; setWoodLikeDiggingProperties(f->digging_properties, 0.10); @@ -232,7 +232,7 @@ void content_mapnode_init() { f->setAllTextures("[noalpha:leaves.png"); } - f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; setWoodLikeDiggingProperties(f->digging_properties, 0.15); i = CONTENT_CACTUS; @@ -243,7 +243,7 @@ void content_mapnode_init() f->setInventoryTextureCube("cactus_top.png", "cactus_side.png", "cactus_side.png"); f->param_type = CPT_MINERAL; f->is_ground_content = true; - f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; setWoodLikeDiggingProperties(f->digging_properties, 0.75); i = CONTENT_PAPYRUS; @@ -252,7 +252,7 @@ void content_mapnode_init() f->light_propagates = true; f->param_type = CPT_LIGHT; f->is_ground_content = true; - f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; f->solidness = 0; // drawn separately, makes no faces f->walkable = false; setWoodLikeDiggingProperties(f->digging_properties, 0.25); @@ -275,7 +275,7 @@ void content_mapnode_init() f->sunlight_propagates = true; f->param_type = CPT_LIGHT; f->is_ground_content = true; - f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; f->solidness = 0; // drawn separately, makes no faces f->setInventoryTextureCube("glass.png", "glass.png", "glass.png"); setWoodLikeDiggingProperties(f->digging_properties, 0.15); @@ -285,7 +285,7 @@ void content_mapnode_init() f->light_propagates = true; f->param_type = CPT_LIGHT; f->is_ground_content = true; - f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; f->solidness = 0; // drawn separately, makes no faces f->air_equivalent = true; // grass grows underneath f->setInventoryTexture("item_fence.png"); @@ -297,7 +297,7 @@ void content_mapnode_init() f->light_propagates = true; f->param_type = CPT_LIGHT; f->is_ground_content = true; - f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; f->solidness = 0; // drawn separately, makes no faces f->air_equivalent = true; // grass grows underneath f->walkable = false; @@ -315,7 +315,7 @@ void content_mapnode_init() f->setAllTextures("wood.png"); f->setInventoryTextureCube("wood.png", "wood.png", "wood.png"); f->is_ground_content = true; - f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; setWoodLikeDiggingProperties(f->digging_properties, 0.75); i = CONTENT_MESE; @@ -323,7 +323,7 @@ void content_mapnode_init() f->setAllTextures("mese.png"); f->setInventoryTextureCube("mese.png", "mese.png", "mese.png"); f->is_ground_content = true; - f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; setStoneLikeDiggingProperties(f->digging_properties, 0.5); i = CONTENT_CLOUD; @@ -331,7 +331,7 @@ void content_mapnode_init() f->setAllTextures("cloud.png"); f->setInventoryTextureCube("cloud.png", "cloud.png", "cloud.png"); f->is_ground_content = true; - f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; i = CONTENT_AIR; f = &content_features(i); @@ -387,7 +387,7 @@ void content_mapnode_init() f->diggable = false; f->buildable_to = true; f->liquid_type = LIQUID_SOURCE; - f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; f->liquid_alternative_flowing = CONTENT_WATER; f->liquid_alternative_source = CONTENT_WATERSOURCE; @@ -401,7 +401,7 @@ void content_mapnode_init() f->walkable = false; f->wall_mounted = true; f->air_equivalent = true; - f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; f->light_source = LIGHT_MAX-1; f->digging_properties.set("", DiggingProperties(true, 0.0, 0)); @@ -415,7 +415,7 @@ void content_mapnode_init() f->walkable = false; f->wall_mounted = true; f->air_equivalent = true; - f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; if(f->initial_metadata == NULL) f->initial_metadata = new SignNodeMetadata("Some sign"); f->digging_properties.set("", DiggingProperties(true, 0.5, 0)); @@ -429,7 +429,7 @@ void content_mapnode_init() f->setTexture(5, "chest_front.png"); // Z- f->setInventoryTexture("chest_top.png"); //f->setInventoryTextureCube("chest_top.png", "chest_side.png", "chest_side.png"); - f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; if(f->initial_metadata == NULL) f->initial_metadata = new ChestNodeMetadata(); setWoodLikeDiggingProperties(f->digging_properties, 1.0); @@ -440,8 +440,8 @@ void content_mapnode_init() f->setAllTextures("furnace_side.png"); f->setTexture(5, "furnace_front.png"); // Z- f->setInventoryTexture("furnace_front.png"); - //f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; - f->dug_item = std::string("MaterialItem ")+itos(CONTENT_COBBLE)+" 6"; + //f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(CONTENT_COBBLE)+" 6"; if(f->initial_metadata == NULL) f->initial_metadata = new FurnaceNodeMetadata(); setStoneLikeDiggingProperties(f->digging_properties, 3.0); @@ -452,7 +452,7 @@ void content_mapnode_init() f->setInventoryTextureCube("cobble.png", "cobble.png", "cobble.png"); f->param_type = CPT_NONE; f->is_ground_content = true; - f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; setStoneLikeDiggingProperties(f->digging_properties, 0.9); i = CONTENT_MOSSYCOBBLE; @@ -461,7 +461,7 @@ void content_mapnode_init() f->setInventoryTextureCube("mossycobble.png", "mossycobble.png", "mossycobble.png"); f->param_type = CPT_NONE; f->is_ground_content = true; - f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; setStoneLikeDiggingProperties(f->digging_properties, 0.8); i = CONTENT_STEEL; @@ -471,7 +471,7 @@ void content_mapnode_init() "steel_block.png"); f->param_type = CPT_NONE; f->is_ground_content = true; - f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; setStoneLikeDiggingProperties(f->digging_properties, 5.0); i = CONTENT_NC; @@ -481,14 +481,14 @@ void content_mapnode_init() f->setTexture(5, "nc_front.png"); // Z- f->setTexture(4, "nc_back.png"); // Z+ f->setInventoryTexture("nc_front.png"); - f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; setStoneLikeDiggingProperties(f->digging_properties, 3.0); i = CONTENT_NC_RB; f = &content_features(i); f->setAllTextures("nc_rb.png"); f->setInventoryTexture("nc_rb.png"); - f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; setStoneLikeDiggingProperties(f->digging_properties, 3.0); // NOTE: Remember to add frequently used stuff to the texture atlas in tile.cpp diff --git a/src/content_mapnode.h b/src/content_mapnode.h index 7be26518f..609df0a95 100644 --- a/src/content_mapnode.h +++ b/src/content_mapnode.h @@ -24,6 +24,8 @@ with this program; if not, write to the Free Software Foundation, Inc., void content_mapnode_init(); +extern content_t trans_table_19[21][2]; + MapNode mapnode_translate_from_internal(MapNode n_from, u8 version); MapNode mapnode_translate_to_internal(MapNode n_from, u8 version); diff --git a/src/inventory.cpp b/src/inventory.cpp index ca050614f..30a43e37f 100644 --- a/src/inventory.cpp +++ b/src/inventory.cpp @@ -46,6 +46,18 @@ InventoryItem::~InventoryItem() { } +content_t content_translate_from_19_to_internal(content_t c_from) +{ + for(u32 i=0; i>material; + u16 count; + is>>count; + // Convert old materials + if(material <= 0xff) + { + material = content_translate_from_19_to_internal(material); + } + if(material > MAX_CONTENT) + throw SerializationError("Too large material number"); + return new MaterialItem(material, count); + } + else if(name == "MaterialItem2") + { u16 material; is>>material; u16 count; diff --git a/src/inventory.h b/src/inventory.h index 66b1cd1f0..53495c6e5 100644 --- a/src/inventory.h +++ b/src/inventory.h @@ -136,7 +136,7 @@ public: virtual void serialize(std::ostream &os) { //os.imbue(std::locale("C")); - os<setAllTextures("unknown_block.png"); - f->dug_item = std::string("MaterialItem ")+itos(i)+" 1"; + f->dug_item = std::string("MaterialItem2 ")+itos(i)+" 1"; } /* From 756f8f88d4c127917cc9ea77e2e44606c199beed Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Sun, 31 Jul 2011 02:27:26 +0300 Subject: [PATCH 12/24] Made stricter handling for old clients because now they are not compatible at all. --- src/server.cpp | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/src/server.cpp b/src/server.cpp index 503d60b84..ba40ec627 100644 --- a/src/server.cpp +++ b/src/server.cpp @@ -1972,20 +1972,23 @@ void Server::ProcessData(u8 *data, u32 datasize, u16 peer_id) } /* - Check network protocol version + Read and check network protocol version */ + u16 net_proto_version = 0; if(datasize >= 2+1+PLAYERNAME_SIZE+PASSWORD_SIZE+2) { net_proto_version = readU16(&data[2+1+PLAYERNAME_SIZE+PASSWORD_SIZE]); } + getClient(peer->id)->net_proto_version = net_proto_version; - /*if(net_proto_version == 0) + + if(net_proto_version == 0) { SendAccessDenied(m_con, peer_id, - L"Your client is too old (network protocol)"); + L"Your client is too old. Please upgrade."); return; - }*/ + } /* Set up player @@ -2181,11 +2184,12 @@ void Server::ProcessData(u8 *data, u32 datasize, u16 peer_id) message += L" joined game"; BroadcastChatMessage(message); } - - if(getClient(peer->id)->net_proto_version == 0) + + // Warnings about protocol version can be issued here + /*if(getClient(peer->id)->net_proto_version == 0) { SendChatMessage(peer_id, L"# Server: NOTE: YOUR CLIENT IS OLD AND DOES NOT WORK PROPERLY WITH THIS SERVER"); - } + }*/ return; } From bb77b1c0affa43b203f2e9a46fbfb31a062b6ec6 Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Sun, 31 Jul 2011 02:35:15 +0300 Subject: [PATCH 13/24] Added tag 0.2.20110731_1 for changeset 705a7e95b871 --- .hgtags | 1 + 1 file changed, 1 insertion(+) diff --git a/.hgtags b/.hgtags index 17ef94f5c..b0bf1eb49 100644 --- a/.hgtags +++ b/.hgtags @@ -17,3 +17,4 @@ dd08a9b5cb84d55b7576bb3fde3068dd263bc3bc 0.2.20110618_0_dev 0000000000000000000000000000000000000000 0.2.20110704_0 65263ec55caf526e3f3e0bdc6657ce42daee46bc 0.2.20110704_0 06c62112b503e746d5d8cc40f951974447d590b7 0.2.20110731_0 +705a7e95b8710c8cada5524d8c7bb658f4b710d9 0.2.20110731_1 From e0b8e66540d2724379d6278f83bbbf0f6d5e2aac Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Sun, 31 Jul 2011 15:32:45 +0300 Subject: [PATCH 14/24] Fixed problem of server always receiving an empty password from the client --- src/client.cpp | 2 +- src/main.cpp | 2 ++ src/server.cpp | 12 +++++++++--- 3 files changed, 12 insertions(+), 4 deletions(-) diff --git a/src/client.cpp b/src/client.cpp index 5f299890a..55f0af6dc 100644 --- a/src/client.cpp +++ b/src/client.cpp @@ -424,7 +424,7 @@ void Client::step(float dtime) memset((char*)&data[3], 0, PLAYERNAME_SIZE); snprintf((char*)&data[3], PLAYERNAME_SIZE, "%s", myplayer->getName()); - /*dstream<<"Client: password hash is \""<= 2+1+PLAYERNAME_SIZE) + if(datasize < 2+1+PLAYERNAME_SIZE+PASSWORD_SIZE) { // old version - assume blank password password[0] = 0; @@ -2044,7 +2044,10 @@ void Server::ProcessData(u8 *data, u32 datasize, u16 peer_id) checkpwd = g_settings.get("default_password"); } - if(password != checkpwd && checkpwd != "") + /*dstream<<"Server: Client gave password '"<getName(); if(m_authmanager.exists(playername) == false) @@ -3361,7 +3367,7 @@ void Server::ProcessData(u8 *data, u32 datasize, u16 peer_id) } std::string checkpwd = m_authmanager.getPassword(playername); - + if(oldpwd != checkpwd) { dstream<<"Server: invalid old password"< Date: Sun, 31 Jul 2011 15:33:13 +0300 Subject: [PATCH 15/24] updated version --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index dad072fd7..941578096 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -9,7 +9,7 @@ project(minetest) set(VERSION_MAJOR 0) set(VERSION_MINOR 2) -set(VERSION_PATCH 20110731_1) +set(VERSION_PATCH 20110731_2) set(VERSION_STRING "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}") # Configuration options From f25c3fc072c05de839182c986c648c6d0803e519 Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Sun, 31 Jul 2011 15:33:22 +0300 Subject: [PATCH 16/24] Added tag 0.2.20110731_2 for changeset 4a6cf9491306 --- .hgtags | 1 + 1 file changed, 1 insertion(+) diff --git a/.hgtags b/.hgtags index b0bf1eb49..2d31ae76f 100644 --- a/.hgtags +++ b/.hgtags @@ -18,3 +18,4 @@ dd08a9b5cb84d55b7576bb3fde3068dd263bc3bc 0.2.20110618_0_dev 65263ec55caf526e3f3e0bdc6657ce42daee46bc 0.2.20110704_0 06c62112b503e746d5d8cc40f951974447d590b7 0.2.20110731_0 705a7e95b8710c8cada5524d8c7bb658f4b710d9 0.2.20110731_1 +4a6cf9491306988b24c79438ee6398885c432fce 0.2.20110731_2 From 1274bf74f67ea3dd115ebc7878baff918cc89d21 Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Sun, 31 Jul 2011 15:41:26 +0300 Subject: [PATCH 17/24] Removed tag 0.2.20110731_2 --- .hgtags | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.hgtags b/.hgtags index 2d31ae76f..cf5246c74 100644 --- a/.hgtags +++ b/.hgtags @@ -19,3 +19,5 @@ dd08a9b5cb84d55b7576bb3fde3068dd263bc3bc 0.2.20110618_0_dev 06c62112b503e746d5d8cc40f951974447d590b7 0.2.20110731_0 705a7e95b8710c8cada5524d8c7bb658f4b710d9 0.2.20110731_1 4a6cf9491306988b24c79438ee6398885c432fce 0.2.20110731_2 +4a6cf9491306988b24c79438ee6398885c432fce 0.2.20110731_2 +0000000000000000000000000000000000000000 0.2.20110731_2 From d4b4246174f3de33ad08c921e927dffd2afeeb40 Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Sun, 31 Jul 2011 15:41:34 +0300 Subject: [PATCH 18/24] updated changelog --- doc/changelog.txt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/doc/changelog.txt b/doc/changelog.txt index 4c77fe1f8..3ae571dca 100644 --- a/doc/changelog.txt +++ b/doc/changelog.txt @@ -3,6 +3,9 @@ Minetest-c55 changelog This should contain all the major changes. For minor stuff, refer to the commit log of the repository. +2011-07-31_2: +- Fixes a bug that caused the server to always read an empty password from the client when a client connected. + 2011-07-31: - A number of small fixes, build system stuff and such (refer to version control log) - Map generator no longer crashes at generation limit From a27200a7a10ef9129f8aabe88383f238dac6cca6 Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Sun, 31 Jul 2011 15:41:39 +0300 Subject: [PATCH 19/24] Added tag 0.2.20110731_2 for changeset 8ad16fbce9a4 --- .hgtags | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.hgtags b/.hgtags index cf5246c74..2311b1aa4 100644 --- a/.hgtags +++ b/.hgtags @@ -21,3 +21,5 @@ dd08a9b5cb84d55b7576bb3fde3068dd263bc3bc 0.2.20110618_0_dev 4a6cf9491306988b24c79438ee6398885c432fce 0.2.20110731_2 4a6cf9491306988b24c79438ee6398885c432fce 0.2.20110731_2 0000000000000000000000000000000000000000 0.2.20110731_2 +0000000000000000000000000000000000000000 0.2.20110731_2 +8ad16fbce9a4da45b2552ad8b400a5a127722acc 0.2.20110731_2 From 19ea901cf21685a53c279f24e04eaa37a3193aa6 Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Sun, 31 Jul 2011 15:51:24 +0300 Subject: [PATCH 20/24] Fixes a bug that made the server to deny non-empty passwords from players connecting the first time. --- doc/changelog.txt | 3 +++ src/server.cpp | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/doc/changelog.txt b/doc/changelog.txt index 3ae571dca..2c577b421 100644 --- a/doc/changelog.txt +++ b/doc/changelog.txt @@ -3,6 +3,9 @@ Minetest-c55 changelog This should contain all the major changes. For minor stuff, refer to the commit log of the repository. +2011-07-31_3: +- Fixes a bug that made the server to deny non-empty passwords from players connecting the first time + 2011-07-31_2: - Fixes a bug that caused the server to always read an empty password from the client when a client connected. diff --git a/src/server.cpp b/src/server.cpp index 35c186b5d..8a19306a9 100644 --- a/src/server.cpp +++ b/src/server.cpp @@ -2047,7 +2047,7 @@ void Server::ProcessData(u8 *data, u32 datasize, u16 peer_id) /*dstream<<"Server: Client gave password '"< Date: Sun, 31 Jul 2011 15:51:33 +0300 Subject: [PATCH 21/24] Added tag 0.2.20110731_3 for changeset c87e28deaabf --- .hgtags | 1 + 1 file changed, 1 insertion(+) diff --git a/.hgtags b/.hgtags index 2311b1aa4..4589d1893 100644 --- a/.hgtags +++ b/.hgtags @@ -23,3 +23,4 @@ dd08a9b5cb84d55b7576bb3fde3068dd263bc3bc 0.2.20110618_0_dev 0000000000000000000000000000000000000000 0.2.20110731_2 0000000000000000000000000000000000000000 0.2.20110731_2 8ad16fbce9a4da45b2552ad8b400a5a127722acc 0.2.20110731_2 +c87e28deaabf4a776c261b3a09b6bf5ea3e04abf 0.2.20110731_3 From 5af9ef054e915056658dc44892cf8dc85b4b4935 Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Sun, 31 Jul 2011 15:54:47 +0300 Subject: [PATCH 22/24] Removed tag 0.2.20110731_3 --- .hgtags | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.hgtags b/.hgtags index 4589d1893..f42b9af89 100644 --- a/.hgtags +++ b/.hgtags @@ -24,3 +24,5 @@ dd08a9b5cb84d55b7576bb3fde3068dd263bc3bc 0.2.20110618_0_dev 0000000000000000000000000000000000000000 0.2.20110731_2 8ad16fbce9a4da45b2552ad8b400a5a127722acc 0.2.20110731_2 c87e28deaabf4a776c261b3a09b6bf5ea3e04abf 0.2.20110731_3 +c87e28deaabf4a776c261b3a09b6bf5ea3e04abf 0.2.20110731_3 +0000000000000000000000000000000000000000 0.2.20110731_3 From ff1471ba6d266597c7a4379605547b6c1201db34 Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Sun, 31 Jul 2011 15:54:54 +0300 Subject: [PATCH 23/24] updated version in CMakeLists --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 941578096..bf430a0df 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -9,7 +9,7 @@ project(minetest) set(VERSION_MAJOR 0) set(VERSION_MINOR 2) -set(VERSION_PATCH 20110731_2) +set(VERSION_PATCH 20110731_3) set(VERSION_STRING "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}") # Configuration options From 303351de6d2cb54af27198207ba6c8cef49ecf1a Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Sun, 31 Jul 2011 15:55:00 +0300 Subject: [PATCH 24/24] Added tag 0.2.20110731_3 for changeset b277d01700f6 --- .hgtags | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.hgtags b/.hgtags index f42b9af89..5244e8c98 100644 --- a/.hgtags +++ b/.hgtags @@ -26,3 +26,5 @@ dd08a9b5cb84d55b7576bb3fde3068dd263bc3bc 0.2.20110618_0_dev c87e28deaabf4a776c261b3a09b6bf5ea3e04abf 0.2.20110731_3 c87e28deaabf4a776c261b3a09b6bf5ea3e04abf 0.2.20110731_3 0000000000000000000000000000000000000000 0.2.20110731_3 +0000000000000000000000000000000000000000 0.2.20110731_3 +b277d01700f640b0ba2684a8ead3b7169a4a8175 0.2.20110731_3