summaryrefslogtreecommitdiff
path: root/melon.lua
diff options
context:
space:
mode:
authorAuke Kok <auke-jan.h.kok@intel.com>2015-04-13 21:01:45 -0700
committerAuke Kok <auke-jan.h.kok@intel.com>2015-04-13 21:01:45 -0700
commit318f3815d372ed680cab4c45aec7eca8b54a4116 (patch)
treea3f52866f81957aca31459e17bbb7a0c122ecdf8 /melon.lua
parent5f9a5d783528fe712ffe6ab96d95cbe893f37398 (diff)
Interval/chance update.
- Globally use the same across all veggies - use a shorter ABM, with lower chance I don't like the fact that if you have 100 plants, then half of them will ALL change phase every 90 seconds. It's just very unnatural. By changing the rate/chance proportionally, plants still grow about as fast (~1200secs for 90% growth rate to 5 phases), but there will be less abrupt changes and no massive block updates, just small amounts at a time. Yes, more ABM's will fire, but that's unlikely a load that it won't be able to handle.
Diffstat (limited to 'melon.lua')
-rw-r--r--melon.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/melon.lua b/melon.lua
index 3f01fe8..27522de 100644
--- a/melon.lua
+++ b/melon.lua
@@ -17,8 +17,8 @@ local faces = {
[4] = { x = 0, z = 1, r = 0, o = 2, m = 11 }
}
-local interval = 90
-local chance = 2
+local interval = crops_interval
+local chance = crops_chance
minetest.register_node("crops:melon_seed", {
description = "melon seed",