Nyancats are independent in the default mod. Nothing else uses them or
their code. Separating it into a separate mod makes it easier for
subgames to remove them. It also makes it easier for a mod to depend
on nyancats, as lots of subgames don't have them.
Default/mapgen.lua: Register biomes, ores and decorations in
singlenode mapgen. These were never disabled anyway because
singlenode was removed from the world creation menu.
* Unused variables
* Unused values (assigned to variables, but overwritten before use)
* Defining already defined variables instead of reassigning to them.
No longer require night to be skipped for resawn position to be saved
Remove constant beds.read_spawns() calls when a player joins as this
is only required once
Preserve overlapping registrations of large and small clusters
below y = -64 but now extend the small clusters up to y = 0 (the
previous highest iron ore level) in a similar to way to coal
Re-order registrations
Add and improve comments
Change sand blob ymax to 0 as sand does not always rise above 0
Remove dirt blobs from sandstone as it is unsuitable for
many sandstone biomes and ugly in stony sandstone desert
Change ymax of first iron region to 0
- Placing liquid inside a protected area no longer returns an empty bucket
- Remove on_place function, tidy up code, return proper itemstack
- Shorten code (changes from HybridDog/patch-35)
- Global functions sethome.set(name, pos) , sethome.get(name) and sethome.go(name)
- Tidy: trim coords to one decimal place and write to table and output table in one go.
- Add error checking
- Add t4im's homepos loader
Allow many crafted nodes to be rotated in any way possible.
These blocks all have slab and stair versions, which can create awkward
patterns if placed together. By allowing these to be rotated players
can create new patterns and appearances that were not before possible.
Since this wasn't possible before, there won't be any effect
to existing builds, as param2 should always be '0'. The current
screwdriver mod also refuses to rotate and alter param2, so this is
safe to enable from now on.
Personally, since these are all *crafted* nodes to begin with, it
should be apparent that they can be rotated to begin with, but I can
see people may disagree from a simplicity perspective. It also may
affect param2 usage that other mods rely on, although I'm not aware
of any mods that do this.
Lowering the top surface to be level with the boat top somehow
causes the boat to fall through world if underwater. Revert to
previous position that is needed for correct behaviour
Allow water to turn cobble slab and stairs to turn into mossy versions.
There is no crafting recipe for mossy stairs and mossy slabs, the
stair/slab API has been modified to allow for a recipeitem that
is `nil`, which will omit adding a crafting recipe for these two
items. The API documentation is updated.
The slabs and stairs will turn mossy when water is adjacent, just like
cobblestone. You can either farm mossy versions by placing them in
water for a while, then collecting them, or run water over your craft.
Enable ignition of tnt, gunpowder and permanent
flame above coalblock using flint and steel
Override coalblock to remove flame above when dug
Add depends.txt for default mod
Mese texture is a classic-mese-yellow version
of celeron55's texture used in MTv0.4.0
Add missing texture credits for mese crystal
and mese crystal fragment
Because the fire nodes are not removed 100% when there are
no more burnable nodes nearby, they can potentially stay around
for very, very long times, leading to ABM trains every 5 seconds
for no good reason (only 1 in 16 will be removed every interval).
A much better method to remove fire nodes is to remove them by
timer, and give removal a 100% chance if no flammable nodes are
adjacent. This makes fire cleanup a lot faster and more natural,
and will reduce the amount of ABM hits making fire overall more
responsive.
We also remove the 1 in 4 chance and fold the removal of flammable
nodes into the ABM chance.
There's some low hanging fruit cleanups in here as well.
Each sapling is given a single node timer that is between
2 and 4 days of game play time (40-80 minutes). If you walk out
of the zone, and come back later, the tree will always grow
to full if the timer has elapsed.
Because trees.lua is all functions, it needs to be parsed before
nodes.lua, since that references some of its functions. Hence,
change the order of parsing here. Otherwise saplings would not
grow to full.
This PR requires @minetest/minetest#3677
Farming and plant growth has traditionally in minetest been
implemented using ABM's. These ABM's periodically tick and cause
plants to grow. The way these ABM's work has several side effects
that can be considered harmful.
Not to mention a comprehensive list of downsides here, but ABM's
are chance-dependent. That results in the chance that some nodes
potentially never get processed by the ABM action, and others get
processed always. One can easily find this effect by planting a large
field of crops, and seeing that some nodes are fully grown really
fast, and some just won't make it to fully grown status even after
hours or play time.
One could solve the problem by making the ABM's slower, and giving them
a 100% of action, but this would cause the entire field to grow a step
instantly at ABM intervals, and is both ugly, and a large number of
node updates that needs to be sent out to each client. Very un-ideal.
With NodeTimers though, each node will see a separate node timer event,
and they will likely not coalesce. This means that we can stop relying
on chance to distribute plant growth, and assign a single timer event
to grow the plant to the next phase. Due to the timer implementation,
we won't ever miss a growth event, and we can re-scehdule them until
the plant has reached full size.
Previously, plants would attempt to grow every 9 seconds, with a
chance of 1/20. This means typically, a plant would need 9*20 seconds
to grow 1 phase, and since there are 8 steps, a typical plant growth
would require 9*20*8 ABM node events. (spread out over 9*8 ABM actual
underlying events per block, roughly).
because plants are likely not growing to full for a very long time
due to statistics working against it (5% of the crops take 20x longer
than the median to grow to full, we'd be seeing ABMs fire possibly
up to 9*20*8*20 with a 95% confidence interval (the actual math
is likely off, but the scale should be correct). That's incredibly
wasteful. We'd reach those conditions easily with 20 plant nodes.
Now, after we convert to NodeTimers, each plant node will see exactly
8 NodeTimer events, and no more. This scales lineairly per plant.
I've tuned the growth rate of crops to be mature in just under 3
whole days. That's about 1hr of game time. Previously, about half
the crops would grow to full in under 2 days, but many plants would
still not be mature by the end of day 3. This is more consistent.
An additional problem in the farming mod was that the final fully-grown
plant was also included in the ABM, causing infinite more ABM's even
after the entire field had grown to completion.
Now, we're left with the problem that none of the pre-existing plants
have actual node timers started on them, and we do not want a new ABM
to fix this issue, since that would be wasteful. Fortunately, there
is now an LBM concept, and we can use it to assure that NodeTimers
on crop nodes are properly started, and only have to do the actual
conversion once per block, ever.
We want to provide a fairly similar growth rate after this conversion
and as such I've resorted to modelling some statistical data. For this
I created a virtual 32x32 crop field with 9 steps (8 transitions)
as is the default wheat crop. We then apply a step where 1 in 20
plants in the field grows a step (randomly chosen) and count the
number of steps needed to get to 25%, 50, 75% and 95% grown.
The resulting data looks as follows:
25% - ~120 steps * 9 sec / abm = 1080s
50% - ~152 steps = 1368s
75% - ~194 steps = 1746s
95% - ~255 steps = 2295s
Next, we want to create a model where the chance that a crop grows
is 100% every node timer. Since there will only be 8 steps ever,
we want the slowest crops to grow in intervals of ~ 2300 / 8 seconds
and the fastest 1/4 of crops to grow 1080 / 8 seconds intervals.
We can roughly compare this to a normal distribution with a median
of 1400 with a stddev of ~350 (thick fingering this one here).
The rest is a bit of thick-fingering to get similar growth rates,
taking into account that ABM's fire regularly so if they're missed
it's fairly painless, but our timers are going to be 1-2 minutes
apart at minimum. I calculate the timer should be around 150s
median, and experimented with several jitter ranges.
Eventually I settled for now on [80,200] with a redo of [40,80],
meaning that each growth step at minimum takes (80 to 200) seconds,
and if a negative growth condition was found (darkness, soil not
wet, etc), then the growth step is retried every (40 to 80) seconds.
The end result is a growth period from seed to full in ~ 2.25
minetest days. This is a little bit shorter than the current
growth rate but the chances you'll miss timer ticks is a bit
larger, so in normal gameplay it should be fairly comparable.
A side effect is that fields grow to full yield fairly quickly
after crops make it to mature growth, and no crops are mature
a very long time before the majority grows to full. The spread
and view over a growing field is also fairly even, there's no
large updates with plenty of nodes. Just a node here or there
every second or so in large fields.
Ultimately, we get rid of ABM rollercoasters that cause tens of
node updates every 9 seconds. This will help multiplayer servers
likely a lot.
Standing on a boat makes you appear to "hover" over it since this
collision box is way too high. Lower it so that it's low enough
to look normal when walking on top of a boat
Removed unnecessary inventory textures
The drinking glass inventory texture now differs from
the node texture to be more clearly a drinking glass
Smaller textures to reduce size as nodes
This pull adds a new global variable called creative.formspec_add
that will allow mods to add to the creative inventory screen
without the need to fork the mod altogether. Simple solution
that works already for inventory_plus' BACK button
This uses a vmanip to count adjacent tnt nodes and explodes them
all at once, using an inverse square law to recalculate the radius.
The maximum explosion becomes 125 nodes of tnt yielding a radius of
15 nodes, which does not break my machine and makes it return
in under a second.
This makes both bigger explosions and less stability issues.
The drop code has been simplified and now drops at all times a
reasonable amount of drops, never blanketing the area with drops,
even at the larges explosion level.
Particles are scaled up according to explosion size as well - a
bigger explosion will show bigger particles.
To scale the tnt:boom particle, we move it to the _effects() function.
Introduces an `on_blast(luaobj, damage)` callback that mods can attach
to an entity def. The function will get called with the damage that
TNT would make.
The function should return three values:
bool do_damage, bool do_knockback, table drops
do_damage allows the mod to tell the TNT code to perform damage on
the entity for the mod. The mod code should not do anything with
the entity HP. The entity should not be immortal. If false, then
the entity will not be damaged by the TNT mod.
do_knockback allows the mod to tell the TNT mod to perform an
entity knockback effect. If false, no knockback effect is applied
to the entity.
the drops table is a list of items to drop. It may be nil. E.g. {
"wool:red" }.
I've documented both on_blast() API methods in game_api.txt. It is
a better place than lua_api.txt.
Any second explosion near a first TNT explosion will punch all
entities found nearby, including item drops. This causes the
item pickup code to think the item was picked up, but by
a `nil` player, thus removing the item.
We query for the immortal entity group, and if the item is in
the immortal group, do not punch the item.
We reuse the tnt:boom texture for a particle that is added by the
on_construct() of tnt:boom, and has a short expiry time (0.2sec).
It is 3 nodes larged, centered on the explosion.
We then make tnt:boom airlike so it doesn't have a texture, and it's
the thing that emits lots of light (we could even make it exist a
bit longer).
The nice thing about particles is that the client is less susceptible
to lag and will always remove them as fast as possible, so this makes
the visual more constant and responsive.
The effect is similar, and the reduction in particles is a small
boost in responsiveness.
To compensate, I've lowered the spawner time and expiration length
as well.
We add a +/- 0.5 random value to the velocity vector of
ejecting nodes.
I've spotted a lot of nodes going exactly straight up if blowing
up sand above TNT. The extra variation looks less artificial.
We apply punch damage to mobs caught in the blast radius, as
this code previously only hurt players.
We "move" players back 1 node if they're caught in the blast, and
slightly up. We can't "eject" players due to missing API code to
support that, unfortunately.
Adds a minor helper function that allows efficient retrieval of
several inventories from a node inventory. We use this helper to
quickly retrieve the items in chests, vessel shelves, book shelves
and furnaces, and return these with the nodes itself to the TNT caller.
The TNT caller then performs the entity physics, and we don't need
to do anything else.
We disable TNT doing anything with bones.
We expose a bug in the code that drops the items - metadata was lost
entirely. This patch corrects that by properly copying the metadata
and creating the drops list inclusive metadata.
This changes how dirt blocks turn to dirt_with -grass, -dry_grass
or -snow.
Previously, dirt that was sunlit would turn to dirt_with_grass no
matter what, but this happened without any context, so you could
get green patches of dirt_with_grass in the middle of a savannah or
even desert.
Dirt no longer turns to covered dirt unless it's within 1 node from
another dirt_with_grass or dirt_with_dry_grass or dirt_with_snow.
This makes dirt_with_grass "growback" a lot slower, since it now only
happens on the edges, but it retains the context nicely now.
If there is any dirt with a grass or dry grass plant, or snow on top,
and enough light, we'll convert it sporadically to dirt_with_grass
or dirt_with_dry_grass or dirt_with_snow.
This allows us to plant grass of our choice in a large dirt patch,
or in a region where otherwise that type of grass is not present.
This used to be done by 2 abms, but I've combined them in to a single
ABM that is ordered to run with maximum efficiency, solving for the
most common outcome first before attempting more complex checks.
This is technically "dirt with grass" that's just under a snow
cover, so in darkness the grass on these nodes will also die,
turning it into dirt.
This doesn't convert dirt_with_snow under snow.
We add on_create() handlers for both burning TNT and burning
gunpowder. Because gunpowder will explode TNT in 1 second,
and not 4, we need to modify the 4 second timer after we
make the TNT burning. Other mods can now place burning TNT
that will by default explode after 4 seconds.
I spotted two places where under stress (many explosions) luajit would
end up passing nil to these functions. I'm not entirely sure how,
but it seems good form to guard against it, which does make it
more robust. After this patch, I'm not able to crash the server. With
many explosions, it may still lag significantly, but always returns
in the end.
We define the blast intensity as the square of the tnt_radius, divided
by the square of the distance to the explosion center, where distance
is limited to 1 at the lower end.
When destroying nodes, we calculate the intensity for each node, and
only destroy the nodes when the intensity is 1.0 or larger. To avoid
perfectly spherical explosions, we make sure to retain a randomness
factor of 20%. This will make explosion edges jagged and not smooth,
but not too much.
We pass the calculated intensity to on_blast() functions as well,
except we take the jitter here out and make sure it's always 1.0
or larger.
We apply a log scale to the size of the stacks ejected, so that
in larger explosions we are getting larger stacks. For normal r=3
explosions, this gives stack sizes ~6-7 or so, but for r=10 explosions
it could end up giving stacks of 25+.V
The drops list already has quantities, so let's just select the one
with the highest quantity from it, and use that as tile. Fallback
tile will therefore only be used if explosion happens in air. Oh well.
We add a dirt-like particle (drawn from scratch, uses some
colors from default_dirt's palette) to spawn many particles
that have collision enabled around the center of the blast.
This has the effect of obscuring the center of the blast, as
that is a painfully visible empty area when the explosion happens,
as there's only a little spark.
The dirt particles bounce around the walls and floor a bit,
and disappear rapidly, well before the smoke particles disappear.
This is a nice visual distraction that obscures the sudden
appearance of the gaping hole, and makes it a whole lot more
believable.
But not too much.
TNT is a bit underwhelming at the moment. We can make it a bit
more interesting by ejecting not just one or two itemstacks,
but a bunch of them. This code splits up the drops into
separate itemstacks that are 2-5 items together, which
results in generally roughly 10 itemstacks being ejected.
Since now we have multiple ejecta, it makes sense to tune
the ejecta velocities a bit better to get the appearance of
an actual explosion better. The items will not all start
with the same vertical velocity, since that would look
like fireworks. Instead we give them all a different vertical
speed.
If the node is special and has an on_blast() handler, we need
to call it instead of getting node drops manually. However, we
do want to know if drops should be added for the special nodes,
so we modify the on_blast() handler code to allow the nodedef
handlers to pass back itemstacks. This could be used by e.g.
the doors mod to drop door items after a blast.
Since this API is documented in lua_api.txt, a separate PR will
be incoming to update the on_blast() documentation.
Some people borrowed the creative code for their sub-games with an exclusive attribution to celeron55.
This is frustrating since I've largely rewritten, redesigned and carefully maintained this mod for the last months.
I expect to be credited.
Currently any doors viewed from underwater will disappear but removing the line 'use_texture_alpha = true,' seems to fix this. Thanks to Thomas-S for finding this glitch.
The boat model had over 1700 tris (!) before this redo. I've reduced
the amount of tris to ~150, which is very reasonable given that there
are almost 45 faces to this model.
I've also spent a good hour re-UV unwrapping the entire model which
has a huuuge impact on the boats' appearance. As much as possible,
the boat now looks like it's made out of actual blocks of wood,
and I've even attempted to make the grains connect around edges,
appear in the same pattern and spacing, and generally make it look
like it's just a nice crafted thing out of several pieces of wood.
I've had to tweak the rudder part to make the texture actually have
square texture pixels. I did that by varying the vertical position of
the botton of the rudder handle and the top of the rudder bottom, which
worked well. I also had to 'slice' the rear face of the boat to prevent
a strange texture tear, probably due to non-flat surface somewhere,
but I couldn't spot the issue there anymore after adding 2 extra edges.
This looks totally like a new boat now.
- http://i.imgur.com/stiVzsa.jpg
If LVM or some other nonmetadata method is used to place a door,
then metadata is missing that tells us whether the door is left
or right-hinged.
However, we can detect that nodemeta is missing and see if the node
name is _a or _b. In the case of _a, nothing needs to be done and we
can just open the door. In the case of _b we assume the door is right
hinged, and tune the state nodemeta value so that the door opens the
right way. This all of course assumes that the schematic method places
the doors *closed* by default, which is reasonable.
- disallow placing beds in protected areas
- fix rotation of beds(broken after 41c2b2ae)
- allow using others' beds, but don't change spawn location
Fixes#953. #943 isn't something I think was ever implemented, and
this does a fair job of addressing the main concern (spawning in
others' houses)
We were cleverly attempting to use an airlike node as the
top half of the doors, but as airlike nodes are not walkable,
falling nodes would not stop falling and thus remain an entity
stuck on top of a door.
After inspecting the builtin/game/falling.lua code, I considered
the remaining options: (a) revert doors such that the top part is
actually the door, (b) play with nodedef fields and see if other
flags may work, or (c) modify the hidden door part to another
drawtype that properly prevents this issue.
(a) seemed way over the top for now, although it would solve the
issue, it would cause a rewrite of most of the code including the
old-door-conversion.
(b) turned up nothing.
(c) turned out to be relatively simple.
So, here's the implementation where I turn the hidden door top
into a tiny, non-targetable but walkable nodebox that is entirely
inside the door hinge. It's entirely transparent, so you still
can't see it, can't hit it, nor can you place anything in it or
make liquids flow through it. The top part is placed in the right
position on placement and not touched further.
Falling nodes will properly stop on top of these doors. I've
adjusted the door conversion code to properly account for the
issue as well, so the only thing remaining is people who have
been running a git branch - those can upgrade by re-placing the
door.
the ```group:cracky``` group contains all sorts of odds and ends
nodes that we shouldn't connect to. There are a few nodes that
walls now no longer connect to, that probably should get
```group:stone``` added, or something similar, though.
I've created a modified B3Dexport.py version that automatically strips
the embedded texture link to external texture files. These links were
causing the engine to spew "can't find character.png" messages on the
console, but were harmless due to texture loading being done by the
client side and not through irrlicht.
I previously moved character.png to /textures/, which is wrong. I now
understand that character.png was in the same folder as character.blend
simply to make blender load the texture from the embedded linkage
automatically. Nothing more, nothing less.
Subsequently the character.png file should just sit in convenience
in the /models/ folder with the blend file, and not in the textures
file. This patch moves it back. And yes, minetest does load the
character.png from this path.
Tested with nodebreaker, fire.
If called from lua, minetest.remove_node() calls on_destruct() callbacks
before the map is actually updated. This means that we can't look at the
map data to determine if we're done cleaning up adjacent nodes, and we
have to stop recursing some other way.
There's no data we can pass around through functions that would survive
scope to a secondary on_destruct() callback, so we have to maintain
local state somewhere in the mod namespace.
In this case, we keep a bitflag. The bitflag is set to "true" by
default. On the first half removal, the flag is flipped and afterwards
we remove the other half node. When the on_destruct for the other half
is running, it's value is false and we flip it back to true without
removing the other half node.
This thus prevents recursing.
To facilitate easier finding of the bed partner, we tell our on_destruct
whether we're a top or bottom half node through a passed flag.
Now that the top is diggable, we just need to assure that it drops a
bottom bed part.
I've found a favorable steel door sound from a parking garage
door that isn't abrupt or scary, just sounds like a nice solid
metal door. The sample had both opening and closing sounds, and
so they match nicely. Amplified and mixed several samples together
to reduce ambient noise, and get the right level compared to
wood doors. Attribution was added as well. CC-BY-3.0 sounds.
We raise the height of the fencegate node by 0.0001 to make the
fencegate post stop fighting with node blocks. This makes the
gate pole appear to be cut through the node, and doesn't leave
a gap when stacking fencegates, which would look odd.
Fixes#909. Door tops are never flammable.
This doesn't guard yet against a voxelmanip removing the top node,
but that is less of an issue since if a voxelmanip removes the top,
then the bottom part remains functional and visibly intact. If the
voxelmanip removes the bottom part, but not the top, then this patch
makes it clean up the top just fine.
The access privilege allows players that have it to bypass protection
on locked doors/trapdoors, chests and bones.
The priv also allows bypassing any minetest.is_protected() check,
including digging nodes and placing them. It is meant for world
moderators to clean up and fix map issues.
Original patch by red-001. Split up and rebased/rewritten by sofar.
This patch requires https://github.com/minetest/minetest/pull/3800
These basic connected wall nodes automatically connect
to neigboring stone blocks, other wall blocks and anything
that's "cracky". The do not connect to wood (fences will do
that).
The walls are generated using a new walls.register() API.
Documentation on the API is included in game_api.txt.
This change requires minetest/minetest#3503.
Walls are added for all cobble stone materials. They generally
look best and are the natural use cases for these materials.
This fence gate builds on NDT_CONNECTED by assuming fence nodes will
automatically connect to it's sides properly. The fence gate will
open and close just like doors, with sounds, but it only opens one
way. The gate sticks out quite a bit and can be bumped into, so the
fence may be used as some sort of path switch.
The fence gate offers no form of protection and can be opened and
closed by anyone. This is done on purpose - the fencegate isn't
meant to provide protection from players, as fences can be
trivially jumped over. Instead, these fences should be used for
protecting crops from hungry sheep, or keeping rabbits in their
pen, or just decoration. Mods can also modify the mod to add
protection, of course.
A recipe is added to make these. It's 4 sticks and 2 wood (any)
as follows:
stick wood stick
stick wood stick
The collision box of the open gate is such that if two gates are
connected but mirrored (making an M shape) then you can walk a large
entity that's larger than 1.0 wide through the opening. The gate of
an opened fence can also be stood upon or bumped into.
I've mixed together some sounds to provide a somewhat light sound
experience, one that one would expect from a small gate latching open
and close.
This change requires #873, otherwise it doesn't connect to fences.
This changes the drawtype of fences to NDT_CONNECTED nodebox drawtype.
These nodes are drawn by the client with the needed connections on
the fly as the scene is drawn. There is no logic needed by mods to
modify the nodes.
These fences connect to (1) other fences, (2) planks and (3) tree
trunks, but nothing else. They do not connect to stone, dirt, wool,
etc. This is done by the "connects_to" parameter, which takes groups
and node names.
Due to the way textures are wrapped, we can make these nodes look a
lot better by giving them a special tile.
This change requires minetest/minetest#3503.
Books still don't wrap long lines of text properly so until this has been sorted out I suggest reverting back to a previous working formspec which lets players read books properly until a fix is found (and maybe scrollbars added to texarea's). Also adding a recipe to blank written books.
This is an adapted version of #861 - by oleastre
Most mods had been calling `doors.register_door() with a door
name that included the "modname:" prefix, and we should continue
to allow mods to do so, without registering the nodenames created
in the "doors:" namespace.
The default case is to use the "modname:" prefix verbatim. If
mods or code calls this function without a prefix, then "doors:"
is automatically used.
Now that the namespace is corrected, the copy replacement ABM is
no longer needed.
This function maps doors.register_door to the new API as far as
reasonable. We can't map the texture, so we fall back to a default
texture. An error message is printed if mod writers did not provide the
needed new tiles field for the door. The created doors are functional
and a full replacement. Old doors are replaced with the new ones
through an ABM.
These sounds were perceived to be too loud in the
game. I've lowered them significantly but they remain
plenty audible. The dig sounds were very loud as well
so I toned them down as well.
Other mods may depend on knowing whether doors are placed
to setup additional attributes or perform node manipulations.
This is something e.g. mesecons does to connect circuits
to doors. This was tested with mesecons. Placing a door next
to a mesecon wire will make the wire automatically
connect, which was otherwise not happening.
And similarly, if we wield a door and right click any node
that has an on_rightclick() handler, call the handler
instead.
Just to be on the safe side, assure that none of this
code runs when right-clicking an entity or player, which
would likely crash the server.
Fold in PR #831 as well - prevent server crash on door
place on unknown blocks, by @tenplus1.
This code never allowed placing a door on e.g. a grass
plant. The code to handle this isn't that complex. With
this code, doors can be placed on flowers and on normal
node surfaces without issues.
Issue #811 - new gravel texture needed.
This texture was Gambits' PixelBOX gravel light texture. Gambit
posted that his texture pack is WTFPL:
- https://forum.minetest.net/viewtopic.php?f=4&t=4990&start=50#p141196
I've made significant modifications to this texture:
- slightly rotated and rolled some sections of pixels
- minor burn/dodge some pixels to keep high contrast
- removed lineair repeating effects
- etc.
Attribution is added back to Gambit. Thanks.
Both the standing and sitting animations had misplaced curve
cusps that caused the end part of the animation to wiggle the
feet slightly back and forward.
I've fixed both animations parts and re-exported. Verified in-game
with multiplayer that everything was indeed fixed.
By adding the timer to the tnt:tnt_burning node it will help mods add the block and cause an explosion after 4 seconds instead of doing nothing like in it's current state.
Spread ABM intervals evenly across 1 to 16 seconds
16s ensures no nodes are missed when player walks past
Adjust chance values to compensate, for identical action rates
Combine lavacooling ABMs into one, return to chance = 1
Grass growth: add 'neighbors = "air"' to avoid
processing the thousands of underground dirt nodes
Grass death: Reduce action rate to that of grass growth
Fire: Use chance = 1 for flame extinguishing
and flame removal when mod is disabled
Node timers are higher precision and a better guarantee
of happening at regular intervals, whereas ABM's may be
postponed, cancelled or missed if a player is too far.
The largest benefit is that once the furnace is done
cooking, no more ABM's are fired - the timer is stopped
instead and no more events are created until items
are put in the furnace.
This patch is larger due to the migration of the timer
function and indentation change as a result of the somewhat
reduced complexity. I've tested with several furnaces and
this works correctly and behavior is not affected, although
people may find that their furnaces now work more
regularly.
If you place several furnaces next to eachother, you will
still find all furnace timers firing exactly at the same
time. This is a bug in core that should not coalesce node
timers at second intervals.
This patch replaces the default door nodes with a new mesh model
and nodes.
Two new models were added that are 2 blocks high. One for left-hinge
and one for right-hinge doors. This allows us to make a single texture
fit on both models. The alternative would have been 1 model and 2
unmapped textures, which is more work for mod developers.
Doors work exactly like the old doors, including ownership, breaking
doors, opening and closing.
Under the hood, we can prevent the top part of the door from being
obstructed by placing an invisible node. This prevents liquids from
flowing through doors or people placing sand or other blocks in the
top half. The door code automatically places and removes these as
needed.
Metadata is used to store door state, just like the old version.
A doors API is added, it allows mods to use the API to open/close or
toggle door states without worrying about sounds, permissions and
other details. This is intended for e.g. mesecons. This API allows
mods to manipulate or inspect doors for players or for themselves.
In-game old door nodes are automatically converted using an ABM and
preserve ownership and orientation and state.
TNT blows up all doors and trapdoors except for the steel ones,
who can survive a blast. We return an itemstack in on_blast(),
which requires a TNT API patch which is also pending.
We enable backface culling for most of these doors, as this gives
the identical visual appearance that the old doors had. In the case
of the glass door, there's a slight twist.
The texture files used by the new doors have new names that do
not conflict with previous texture file names to avoid texture
pack conflicts.
Thanks to red-001 <red-001@users.noreply.github.com> for some
of the conversion code, cleanups, and extra textures.
This converts the call to minetest.register() for the default
fence node, so it can be called by other mods to quickly
setup other fences.
Since this creates an API, insert it into the game_api.txt.
The api looks like minetest.register(name, {def}), and has two
uncommon fields: "texture" and "material". Any normal nodedef
property can be passed through, except "drawtype". The "fence"
group will always be added.
The default fence recipe is modified to be as follows:
wood, stick, wood
wood, stick, wood
This recipe yields 4 fence nodes.
This allows us to create according recipes for acacia, pine,
aspen, and junglewood fences without adding new stick types:
pine wood, stick, pine wood
pine wood, stick, pine wood
This is a from-scratch implementation, written by heart but inspired
by (#665 - Add many wooden fences).
Stick and fences nodes are named in a consistent way.
Organizing these in groups will allow mods to do several things
easier:
- create craft recipes using them as ingredients
- manipulate map nodes based on group properties
There are quite a few slab and stair blocks already, so automatically
add these groups at registration time for all of those. Since most
mods I've seen use the registration code in this submod, they will
also benefit.
We're using a normal wooden side texture to draw the sides
of trapdoors. But the side textures have only 2 edges that
have a nice texture for the 2px wide trapdoor. We can
either repaint the textures, or just rotate the texture
properly for the two sides that need it.
Because the side texture for wooden doors was just a default:wood
texture, it clashes with the colors in the trapdoor, and so
we add a wooden trapdoor-matching tile side texture as well.
This also improves the steel trapdoor side, but without a
texture change there since that was already a specially
drawn texture for that node.
We also increase the thickness of the trapdoor to 2px. Right
now the model is 0.4 large, but this causes the side textures
to look odd as there's a mismatch in pixel size. By scaling the
trapdoor side up to exactly 2px, the sides look natural.
Thanks to @kilbith for the suggestion.
There really is no reason to prevent rotation in trapdoors, I
expect this to be an oversight.
Trapdoors work perfectly well sideways, upside down and can
work like fences, gates and more. Most commonly, people will
want to put them in the top half of the node so they remain
flush with a floor.
Adds a birch-like tree to the default_game. Aspen was chosen on
purpose instead of birch, as several birch tree mods already exist
and choosing a different name avoids any conflicts.
Schematics were made for both normal and sapling version, assuring
saplings will not be able to grief. The shape of the Aspen is "fanning
out at the top" and provides an easy tree to walk under, but still a
somewhat thick cover. The Aspen trunk is 4 to 6 blocks tall, with up
to three layers of leaves on top, making it slightly taller than an
Apple tree, but shorter than a Pine tree, which provides a good blend.
Textures were painted from scratch, except tree_top and _wood
variants, which are color modified versions of the pine_wood
variants. Appropriate licenses have been chosen for the new textures.
The leaf texture is light enough to contrast other trees, but dark
enough to offset against our light default grass color. The leaves
are drawn in the typical minetest default fashion with plenty of
transparancy, but enough definition to suggest that you're seeing
something that looks like leaves. The placement of leaves in the
schematic also suggests the top of the tree is sparse and you can
see the sky through the leaves.
Sapling texture is both traditional and different, with lush green
leaves and a well-defined stem, but slightly stick-like and skinny,
as these plants tend to grow up first, then out.
Add fallen Aspen logs. We make these logs a minimum of 2 blocks long,
and up to 3. This allows us to make these logs a place where both
red and brown mushrooms can be found, to these may be attractive to
players. However, the spawn rate for these has been reduced a lot
compared to the other logs, to account for the scarcity of Aspen.
Add stairs, slabs for these wood types as well.
Mapgen will place these trees in deciduous forests only, but in
a way that the biome is a range between entirely Apple trees, and
mostly entirely Aspen trees, with a bias to Apple trees. To make
fallen logs somewhat correlated with trees, we modify the planting
of Apple trees and logs to use perlin noise and not fill ratio,
otherwise you'd always end up with Apple logs in Aspen tree areas,
which would be suspicious. There still is a bit of a mix.
In oversight, I added this recipe not verifying that it was already
taken.
We change this to a 2x2 iron bar recipe. The shape and amount are
reasonable (reduced to output 1 steel trapdoor), and I verified that
it wasn't in use.
Fixes#779
We can vary the landscape a bit more by placing "fallen logs"
around the various forests. These decorations are quite fast
and will provide some gameplay value but are still more rare
than the corresponding trees, so they don't provide free
materials.
I've manually put the schematic as lua tables since these log
schematics are only 8 blocks. We vary the log lengths between
1 and 3 blocks by making the end blocks have a lower chance
of appearing.
Amount is varied by fill_ratio, except for acacia trees where
we reduce the scale, so that acacia logs show up near places with
acacia trees consistently.
Mushrooms are placed optionally on each log. We can't place
two different mushrooms on a log, so instead we opt to place
brown mushrooms on oak/appletree logs, brown mushrooms on
jungletree logs, and red mushrooms on pine logs. No mushrooms
are placed on acacia logs, as they occur in a dry biome,
savannah, and this adds a bit of biome diversity.
Combine any written book with an empty book to copy it. The
copy is in player hands when using, and the original is put
back on the crafting grid and can be directly copied again.
All ownership and metadata is retained, so the copy of the book
is as writable as the original is, or isn't.
Adds a steel trapdoor. Textures were painted from scratch, and
inspired by the current Steel Door. Ownership on the trapdoor
works as expected, and so does the crafting recipe.
Playing stereo sounds positionally in OpenAL causes it to play
the sounds unattenuated - same volume for all distances. This
shouldn't happen, and makes door sounds unneccesarily loud from
very far away.
Convert all door samples to mono, 22kHz 64kbit.
Trimmed all door samples to remove lead, trail silence.
These have almost no value gameplay wise. Mushrooms spread
by their very nature into appropriate soil nearby, and
harvesting spores is something only scientists do. Actual
mushroom farmers leave a few mushrooms and put on more
manure, and keep the light off.
Modify the growth ABM to test for light levels and attempt
to plant a similar mushroom nearby (+/- 2 x,z, +/- y). Light
at both source and destination needs to be low enough. I've
tuned it to be 3-4 spaces from a torch.
Mushrooms will die in full sunlight, but they can survive under
trees and may grow out at night anywhere.
Removed obsolete textures.
Remove unused nodes and provide aliases for them.
Aliased obsolete nodes so no unknown item nodes appear.
Mushrooms die only in full sunlight (light level 15).
This prevents nodes that are not of the "facedir" paramtype2,
as these are generally not expected to be able to rotate. Mods
and other methods may still manipulate param2 of these nodes
as expected.
Addresses #712
Since written books are quite different from empty books, the
visual clue that they are different items is really needed in-game.
I've added a "clasp" or "belt-with-buckle" like element to the
png from default_book, keeping them very similar but also
immediately recgnizably different.
I added the new texture to blockmen's license list since it's
obviously derivative of his work.
The PNG was run through a minimizer/optimizer to save space.
The fixing of low density decorations allows returning to
sidelen 16 for acacia trees and cacti, previously sidelen
80 was required for low density decorations to appear
Also use sidelen 16 instead of 8 for mgv6 papyrus
Bring humidity points closer to reduce distortion of voronoi cells
Slightly reduce size of hot and frozen biomes
Improve location of glacier biomes
Remove unnecessary snow nodeboxes from tundra to improve FPS
Add missing dirt_with_snow to taiga
Dirt waters are more suitable for waterlilies
Add dedicated dunes biome in coniferous forest
Papyrus: use dirt base again
Force-place roots on mapgen tree schematics
Tune some humidity points to improve voronoi cells
Add random rotation to jungle trees
Rename in game.conf and documentation
Update game_api.txt documentation for bucket API and tree functions
Fix tab, space and comment formatting in game_api.txt
Rename in mod READMEs
- beds/Changelog.txt probably won't be updated because http://dev.minetest.net/Changelog is used instead
- The information in farming/API.txt is already documented in game_api.txt
Add extinguish sounds (from default mod lavacooling)
'disable fire' setting extinguishes fire quickly using a dedicated ABM
'disable fire' also disables all other ABMs
Simplify flammable node removal ABM
Speed up node ignition, it was too slow
Add 'sunlight propagates = true' and 'paramtype = "light" to flame
Balance fire sounds' gain