Page 1 of 1

Premade Structures

PostPosted: Thu Sep 27, 2012 13:37
by scorch
Well, I want to write some mods, and one of them depends on the fact that the map should be changed when it is being created. By this I mean, when someone creates a new map, the mod places the buildings on the map, as if it was the player placing them.
I really don't find it very complicated in theory, but I don't know if it iw possible with the current Minetest's modding API. :)

PostPosted: Thu Sep 27, 2012 13:44
by cornernote
i have collected a bunch of pre-made structures in deploy_building mod (part of deploy_nodes modpack)

you can spawn the buildings after an area has been generated (see mods like moreores to see how to tap into the map generation)

the problem is that buildings are larger than chunks (or overlap chunks), so you will probably end up with a building loaded, and then mapgen ontop of that, which will result in half a building.

a better idea might be "delayed building"... for example use an ABM to create the building over time instead of loading it all at once on mapgen. Then you can add a few NPC's in and make it look like they are doing the building. =)

PostPosted: Fri Sep 28, 2012 20:11
by scorch
I must admit that I don't know a lot about the inner works of the Minetest engine, since I found it only a few days ago. And also, it's true, I've already played Minecraft a lot. So, I'll assume that Minetest uses alse a seed for map generation (or something similar). Would it be possible for me to make the generator create always the same map, whenever the user created a new world with my game (Minetest subgame), and then place specific blocks in specific places that I already knew?

My goal is to create a story-driven yet free (kind of Assassin's Creed style, where you have a mission, but you can wait and do things between missions), in a predefined map.

Is there any way to achieve this with minetest?

PostPosted: Fri Sep 28, 2012 20:19
by Mito551
scorch wrote:My goal is to create a story-driven yet free (kind of Assassin's Creed style, where you have a mission, but you can wait and do things between missions), in a predefined map.

Is there any way to achieve this with minetest?


i don't believe you can. at this point at least. but you can do it as all mc mapmakers do - build a map, place signs and upload it.

PostPosted: Fri Sep 28, 2012 20:39
by scorch
Do you mean, because of the modding API? Isn't it good enough to make it? It's true that I havent's seen it all, in fact, I must admit that I haven't seen any way to interact with the world more than adding blocks, removing, etc...

Will this be possible in the future, then? Basically, I would need, besides creating that premade map, have some way to control the camera and the player, during cutscenes, for example, and controls like new GUI's, talking to NPC's, Following an objective.

PostPosted: Fri Sep 28, 2012 21:08
by Mito551
scorch wrote:Do you mean, because of the modding API? Isn't it good enough to make it? It's true that I havent's seen it all, in fact, I must admit that I haven't seen any way to interact with the world more than adding blocks, removing, etc...

Will this be possible in the future, then? Basically, I would need, besides creating that premade map, have some way to control the camera and the player, during cutscenes, for example, and controls like new GUI's, talking to NPC's, Following an objective.


wow. the goal is huge. easier would be creating a mod for a game with cutscenes and npcs and gui, etc. or writing your own game. anyway, good luck with whatever your scenario is.

PostPosted: Fri Sep 28, 2012 21:52
by Menche
scorch wrote:Do you mean, because of the modding API? Isn't it good enough to make it? It's true that I havent's seen it all, in fact, I must admit that I haven't seen any way to interact with the world more than adding blocks, removing, etc...

Will this be possible in the future, then? Basically, I would need, besides creating that premade map, have some way to control the camera and the player, during cutscenes, for example, and controls like new GUI's, talking to NPC's, Following an objective.

You can use mods to make GUIs for some things, teleport the player, send chat messages to the player, play sounds, with some work you could make NPCs. You can also bundle the mods with a map, or create a new game mode. Playing cutscenes isn't possible, and moving the player around can be a bit glitchy, but your idea is mostly possible.

PostPosted: Fri Sep 28, 2012 22:46
by scorch
Hi Menche and thanks for the answer. By cutscenes, I mean handling the camera direction, the player, and other NPC's as well as some events that might happen in the world, like a door opening, etc... If it isn't possible, will it ever be in the future, or there isn't any information about it?

PostPosted: Sat Sep 29, 2012 08:08
by PilzAdam
The premade strucutures can be bigger than one map block. You just have to use the blockseed. I dont know how to code this but maybe someone else. The mapgenerator in the engine also creates the world in map blocks and there arent any cliffs or something else at the borders of map blocks.