Minecart and rails šŸ›¤ļø

Super Cool! I gotta try this out : ).

6 Likes

Totally just thinking out loud here:

I wonder if we could somehow clone the hearthling construct and ā€œspawnā€ one as a minecart (with no traits or basic survival needs)? And then the track itself could become a static path that the entity ā€œwalksā€ along whenever you summon the cart at one of the end stops. ā€¦ or something. Also, since hearthlings already have backpacks, the minecart could even use it as its storage.

8 Likes

Making the entity move from A to B, especially on tracks, isnā€™t that difficult. Itā€™s going to be more of a nightmare to have a moving inventory, as that probably messes up with the pathfinder/AI. You would need to remove the cart from the inventory, move it, then re-add it.

1 Like

Wouldnā€™t it be just like moving a hearthling with stuff in their backpack?

1 Like

No. Thereā€™s a difference between a consumer and a producer. Hearthlings are pure consumer and are actively organizing their inventory, or rather, the AI actions are. Chests, on the other hand, are producers - they offer items to third parties. While they might also ā€œseekā€ items, they do so by scheduling tasks that are executed by the hearthlings.

In order to do this properly, you need to remove the inventory from the town, so nobody is trying to fetch items/take items while in transit. Upon arrival, you need to re-enable those possibilities, however. The train Iā€™ve done ages ago is doing exactly that; upon arrival, itā€™s designating stockpile zones on itself, which allows (un-)loading. Once itā€™s departing, the stockpiles are deleted and the items assigned to the waggon again.

Technically itā€™s even going a bit deeper, the items are always available for the AI, but the train holds a lease on the items most of the time. Only when an item may be unloaded, the lease is lifted. I suppose the cart could work in a similar way; that way you canā€™t take items out while moving. Itā€™s still possible to add items though.

7 Likes

Wow. Yeah, that sounds like just the thing to help evolve this mod. :slight_smile:

1 Like

Bruno, i was wondering what program you used to change the angle on the tracks in the model?

It can be done through .json alone. But would require a lot of guess work. What I did was importing the model into blender and use a stonehearth plugin there to generate the animation file, which has only a single frame (as it does not need to move). The animation is required when moving or rotating parts of objects (like an hearthling arm) so it is what I used it to rotate the track.

3 Likes

i suspected it was animationā€¦ thanks for the answer :merry:

So can you actually make this work because it would be amazing if the minecraft actually moved

2 Likes

Sorry. This was one of my ā€œquickā€ mods. I donā€™t have time to implement more complex features.

But! Consider this mod open to everyone that has knowledge and will to do it.

7 Likes

Thanks for saying itā€™s open! I am interested in making a mod/collection mod, and I was thinking of implementing something like this. May I?

Also, I think it makes a little bit more sense for the carts and rails to be crafted by the engineer. So, thatā€™s how itā€™ll be in mine. I presume you made it be done by the blacksmith to make it available a little bit earlier?

Thanks,
Matthias

1 Like

Donā€™t worry, grab what you need, there isnā€™t much though, just the models and a few json files.
I chose the blacksmith because I see it as a simple metal work, like smelting ingots or shaping swords. There is no contraption or complex parts in it. Just hot metal bending.

3 Likes

Thank you! [quote=ā€œBrunoSupremo, post:37, topic:29212ā€]
I chose the blacksmith because I see it as a simple metal work, like smelting ingots or shaping swords. There is no contraption or complex parts in it. Just hot metal bending
[/quote]

Oh! That makes sense, I was thinking Engi because of the wheels.

2 Likes

Great mod, really adds a lot of atmasphere around mines. However, with the current release version, the ramps donā€™t initialize its animation, and thus are just flat, partly floating pieces of rail.

1 Like

Oh, I will take a look, no idea this would happen.
Thanks, I fixed. The updated version is in the first post.
Something have changed in the newer version where non-loopable animations would return to the default pose. I just needed to set it to loop.

8 Likes

This is such a amazing mod i just wish this will eventually move because it be amazing to have a working minecart that moves

2 Likes

Hey, can you update the link? When i download it, the file name is a bunch of random characters.

Love the consept of the mod, just wish i could use it.

I added a new link there. Should work.

1 Like

Could the whole track system count as a storage item allowing the hearthlings to simply deposit at the nearest rail. Then, you could have the end points of your rails be where they could withdraw items from. The animation of a mining cart going back and forth between these two end point could signify the completion of this circuit and though it would not be an active cart per se at least it would alleviate the implementation of how it could work.
I literally know nothing about coding so this might be gibberish but I really love the mod and thought I would offer my 2 cents on how it might work.

1 Like