Lag-free itemframes sounds really cool, especially important for servers. It's annoying that the items are invisible unless you stand 2 cm in front of the item frame. xD
you mean, that was an issue with other itemframe mods?
Having not tested it so far, does this work with boats, carts, water buckets, lava buckets, wheat seed and cotton seed from Minetest Game? Because other item frames fail for these items.
This mod works with them just fine, but the boats and bed mods for instance do not properly propagate the on_rightclick to the node, so this is a minetest_game bug (which I obviously intend to fix).
/giveme frame:boats_boat
I'm not really happy how the flat items look like on the frame. I actually like the design of items “popping” out of the frame. But I fear that's the price we have to pay. :-/
I could fix this, but it would break 32px texture pack support and come at the cost of a *lot* of triangles (1500 or so for a 16px compatible frame, 12000 triangles for a 32px compatible one!). I'm not willing to do that just yet - maybe later.
On the other hand, is it really a good idea to avoid entities at all costs? Maybe the real fix should be done in the engine, by making entities more efficient, less laggy and less buggy in general.
While making entities more robust, they are always going to consume lua execution time and require globalstep maintenance.
Many items are not supported:
- Stairs
- Slabs
- Fences
- Fence Gates
- Walls
would require me to make another *mesh* to support those shapes. That means more modelling work, and at this time I don't think that it's reasonable. It also means even more registered nodes, I just don't think that's important right now (yet).
BedsSeedsChestsCartBoatKey, Skeleton Key
These work but all need mtg to be fixed (/giveme ..)
Flower pots from [flowerpot]Iron bar and glasspane (xpanes)
Added, these were just forgotten (I'm fairly sure there's more I have not included yet)
Screwdriver (rotates item frame instead)
half of these are bugs. Cart, boat are supported, but minetest_game doesn't pass the on_rightclick through, as I said above (and I will attempt to fix this)
You don't want your itemframe rotated? I thought that was pretty neat that it could. Obviously shift-right click may be something we need to implement on some items.
Bugs:
- The same grass drop bug as in your flowerpot mod
I'll fix that up to stay in the spirit of minetest_game
- Leaves are flat instead of cubic
I can probably fix that
- Placing a water source, lava source or river water source looks very weird. Probably because they're animated?
yes, the current texture selection algorithm doesn't handle it yet, but I think I can actually make it look like an animated water cube, except that the transparency would be an issue, so I'm not sure what I'll do with this.
- The dropped item has a bad appearance (faces missing on the backside when it rotates)
Yes, and an inventory image is trivial, so this will be fixed in a sec.
Fun fact: The furnace is seen from the backside instead of the front. XD
spotted that, sadly the "front" texture is tile number 6, not 3. Yet more complex tile handling code coming.
- I would change the item name (“description” field) to “Item Frame”. This is the name which most players would recognize and understand. “Frame” sounds overly generic. Note: The mod name is OK.
sure
- Add a inventory image. This also fixes the issue with the appearance of the dropped item
done, it's the same as the mesh texture anyway
- Make the node wallmounted/attached (like a sign), so it doesn't float
I Can't make it attached_node, since then it can't hang on a wall. Making it wallmounted would make it not rotatable! I don't like either of these options. I agree it should fall if the node backing it disappears, but I don't see how I can do that without sacrificing something else yet.
- Make the node non-walkable, otherwise the player can use item frames to climb up walls. xD
This... I don't know. This is more of a personal taste thing if you ask me. For 99% of the time, the frames are probably going to be inside peoples houses as decoration, and this won't be a concern.
- Use rightclick to make item pop out, intead of punching. I think this feels more natural. IMO I think rightclick should generally be seen as the “interaction” key by nodes, not punching, as this doesn't conflict with mining.
This... I also don't know about. To me, digging means "getting something out" and right clicking means "putting something out/in". You didn't comment on this with the flowerpot, which also uses left/dig right/place controls, so I'm not convinced.
As usual, thanks for the review, this is really useful and I think I can address most of the comments really quickly.