Anyway, I can do like a bit of tweaking and I don't mind a little copy pasta in coding, but I have found myself unable to find much on the engine.generator.map.* classes.

Setting the zone's generator's class to Roomer, Forest, Maze, Cavern, Empty, or Static seems to work right off the bat (though I have barely a clue as of yet on how to use them).

This question is concentrating on the classes that I can't find much on:

engine.generator.map.Building

engine.generator.map.GOL

engine.generator.map.Heightmap

engine.generator.map.Octopus

engine.generator.map.Rooms

engine.generator.map.RoomsLoader

engine.generator.map.TileSet

engine.generator.map.Town

What are each of these?How do I use them?Are they supposed to be used, or are they rightfully ignored?

Also, how would I write a generator of my own?I don't mean the the actual map generating code, but everything else after doing that:What would the algorithm return?Where do I put it?Where is it supposed to return to?

For a simple user-defined generator, how do I make a map from a uniform random number generator?

Code:

-- The simplest random map generator possible

local RNG = require("engine.rng") --I assume you need to do this to use the rng module

--- Randomly chooses each tile.-- Each type of tile has an equal chance to appear at every point on the grid.-- @param arguments What does the function get passed to it?-- @return What does it return?function utterly_random_generator(arguments) --insert code hereend

So far it seems I can modify the map generation using the file "\data\zones\dungeon\zone.lua", so if you show examples I would ask you use that (unless I am way off base and it is not applicable):

Joined: Tue Dec 14, 2010 3:23 amPosts: 163Location: Where I need to be

So to see the files and such look at game\engines\default\engine\generator and that will have all the actual generators. For implementing them I suggest taking a look at tome. Generally you just need to add some extra parameters. They are supposed to be used so go a head. If you have a particular one you want to just ask. For writing your own there is one function that you need. its "generate" you pretty just get handed an array or tiles. Then you generate stuff. making anything complicated will be very tricky though. As with any t-engine stuff ask on irc.rizon.net #tome for real time help.

_________________Those who complain are just Volunteering to fix the problem

<yufra> every vault designer should ask themselves exactly that: What Would Grey Do?

engine.generator.map.BuildingIt's used to build a big building by subdividing a big room with horizontal or vertical walls into smaller rooms. It's used in the dreams zone.

engine.generator.map.GOLGame Of Life. It was used in tome2 for the Illusory Castle , but it's not used in the current game afaik.

engine.generator.map.HeightmapAt first a heightmap is generated (each map square is represented by a numeric value, e.g. altitudes), and then these values are compared to the thresholds of a list of tiles (e.g. low values become plains, middle values become hills, high values become mountains). It was used in an old version of Daikara (or the ME equivalent).

engine.generator.map.OctopusHearth of the Gloom - one big cavern with branching smaller caverns

engine.generator.map.TileSetIt uses pre-defined tiles to randomly fill the level, but there are checks for consistency (opening only next to an opening). The tiles can be of different sizes (multiples of a base size). It's used to build maze like levels in Escape from Reknor, Thieves Tunnels, the first level of Ancient Elven Ruins. The second level with the boss shows how to use it with different sized tiles and a starting tile

engine.generator.map.TownBuilds a town with smaller buildings or vaults. See Halfling ruins or orc prides.

There are also some generators for some specific zones in tome/class/generator/map/

I can't seem to find these generators at all, actually. My game\engines directory only has an empty 'Cores' directory and a file called te4-1.0.1.teae. There doesn't seem to be this directory anywhere: game\engines\default\engine\generator. Have I not installed the T-engine correctly or something? Thanks.

Who is online

Users browsing this forum: No registered users and 3 guests

You cannot post new topics in this forumYou cannot reply to topics in this forumYou cannot edit your posts in this forumYou cannot delete your posts in this forumYou cannot post attachments in this forum