From fa22a855c701fa4d5eb66bcb0d4d86a14233298d Mon Sep 17 00:00:00 2001 From: paramat Date: Mon, 12 Aug 2013 07:10:07 +0100 Subject: [PATCH] Version 0.1.2 more snow, 4 designs --- README.txt | 16 ++++++++++------ init.lua | 26 +++++++++++++++++++++++--- textures/snowdrift_snowflake3.png | Bin 0 -> 197 bytes textures/snowdrift_snowflake4.png | Bin 0 -> 192 bytes 4 files changed, 33 insertions(+), 9 deletions(-) create mode 100644 textures/snowdrift_snowflake3.png create mode 100644 textures/snowdrift_snowflake4.png diff --git a/README.txt b/README.txt index 0e91fe2..6b6308c 100644 --- a/README.txt +++ b/README.txt @@ -1,9 +1,9 @@ -Snowdrift 0.1.1 by paramat -For latest stable Minetest and back to 0.4.6 -Depends default -Licenses: Code WTFPL. Textures CC BY-SA. -This is intended to be used as alternative snowfall for the snow mod by Splizard. -The code is partly derived from weather mod by Jeija and snow mod version 1.8 by Splizard. +-- Snowdrift 0.1.2 by paramat +-- For latest stable Minetest and back to 0.4.6 +-- Depends default +-- Licenses: Code WTFPL. Textures CC BY-SA. +-- This is intended to be used as alternative snowfall for the snow mod by Splizard. +-- The code is partly derived from weather mod by Jeija and snow mod version 1.8 by Splizard. Version 0.1.0 --------------- @@ -21,3 +21,7 @@ Version 0.1.1 ------------- * Mod is too light, doubled maximum snow density, added second snowflake design with a square symmetry. * Snow density is now smoothly varied by how deep into a snow biome a player is. + +Version 0.1.2 +------------- +* Maximum snowfall doubled, 4 snowflake designs. diff --git a/init.lua b/init.lua index c34cbdd..c5479a7 100644 --- a/init.lua +++ b/init.lua @@ -1,4 +1,4 @@ --- Snowdrift 0.1.1 by paramat +-- Snowdrift 0.1.2 by paramat -- For latest stable Minetest and back to 0.4.6 -- Depends default -- Licenses: Code WTFPL. Textures CC BY-SA. @@ -12,8 +12,8 @@ local MAXCHA = 0.5 -- (0 to 1) Maximum per globalstep chance of processing a pla local SEED1 = 112 -- 112 -- These 5 parameters should match the values you use in snow mod. local OCTA1 = 3 -- 3 local PERS1 = 0.5 -- 0.5 -local SCAL1 = 150 -- 150 -- Large scale size of snow biomes. -local SNOTHR = 0.53 -- 0.53 -- Perlin noise > SNOTHR for snow biome. +local SCAL1 = 256 -- 150 -- Large scale size of snow biomes. +local SNOTHR = 0.4 -- 0.53 -- Perlin noise > SNOTHR for snow biome. -- Stuff @@ -56,5 +56,25 @@ minetest.register_globalstep(function(dtime) 32, 2.8, false, "snowdrift_snowflake2.png", player:get_player_name()) + local posi = {x = ppos.x - 64 + math.random(0, 128), y= ppos.y + 16, z= ppos.z - 48 + math.random(0, 128)} + local velo = {x = math.random() / 5 - 0.1, y = math.random() / 5 - 1.1, z = math.random() / 5 - 1.1} + local acce = {x = math.random() / 50 - 0.01, y = math.random() / 50 - 0.01, z = math.random() / 50 - 0.01} + minetest.add_particle( + posi, + velo, + acce, + 32, + 2.8, + false, "snowdrift_snowflake3.png", player:get_player_name()) + local posi = {x = ppos.x - 64 + math.random(0, 128), y= ppos.y + 16, z= ppos.z - 48 + math.random(0, 128)} + local velo = {x = math.random() / 5 - 0.1, y = math.random() / 5 - 1.1, z = math.random() / 5 - 1.1} + local acce = {x = math.random() / 50 - 0.01, y = math.random() / 50 - 0.01, z = math.random() / 50 - 0.01} + minetest.add_particle( + posi, + velo, + acce, + 32, + 2.8, + false, "snowdrift_snowflake4.png", player:get_player_name()) end end) diff --git a/textures/snowdrift_snowflake3.png b/textures/snowdrift_snowflake3.png new file mode 100644 index 0000000000000000000000000000000000000000..1e961820ec34ecee1b907914c3790b24e8f5d26f GIT binary patch literal 197 zcmeAS@N?(olHy`uVBq!ia0vp^>>$j+1|*LJgQL70(Y)*K0-AbW|YuPggq4o-F!Ry)@=5ulK(r;B3<$MxLq zgPaEpc$oc{HBWhGKl!8DD`mYMD!)9MtZ%XzXwS0#)ltu4@$1Kxi&NS@Ze8d2KJ8i> kg9dlX>@}`-=CgjY?wu~#uJ~N|InY1`Pgg&ebxsLQ0IT^usQ>@~ literal 0 HcmV?d00001 diff --git a/textures/snowdrift_snowflake4.png b/textures/snowdrift_snowflake4.png new file mode 100644 index 0000000000000000000000000000000000000000..5fe122c3b8d0c6159e803f1708528ec8630a6d2b GIT binary patch literal 192 zcmeAS@N?(olHy`uVBq!ia0vp^>>$j+1|*LJgQL70(Y)*K0-AbW|YuPggq4o)@;@%?9?OaTfxc)B=-a9mIA zbL3)B;9zn8|NrQj`8n-gOIRe!6C5WWnQ6tq{2|=r(b|s}H#LR-gI0)z4*}Q$iB}o9a5Y literal 0 HcmV?d00001