Open Terrain Generator (OTG)

Open Terrain Generator (OTG)

10M Downloads

[1.12 Forge] [Request] AR compat - Predictable biome ids

aaronhowser1 opened this issue ยท 16 comments

commented

Is your feature request related to a problem? Please describe.

Related to #469, I want to make a planet in AR that is entirely made out of the biome "Webbed Forest" from Biome Bundle. However, with dimension ids being per world (and also per world generator), I can't set a specific biome id in the AR config and have it always be Webbed Forest.

Describe the solution you'd like

String biome ids instead of integer? In the AR planetDefs.xml, you would set this to make a planet only able to generate ocean and beach biomes:

<planet DIMID="28" customIcon="marslike" name="Calidissimus">
            <seaLevel>32</seaLevel>
            <biomeIds>minecraft:beaches,minecraft:ocean</biomeIds>
            <oceanBlock>minecraft:lava</oceanBlock>
            <fillerBlock>advancedrocketry:hotturf</fillerBlock>

If OTG used string biome ids (and /otg biome does show the biome name, and it could just assign it the biome id biomebundle:webbedforest instead of just adding using the first non-taken numerical id)

commented

This is already a thing, webbed forest already has a predictable id name

commented

Oh? When I ran /otg biome, it said it's using You are in the Webbed Forest biome, with id 3 or something similar. Like how minecraft:dark_forest is the same as 32, what's the string naming scheme? preset:biome_snake_case? So, biomebundle:webbed_forest? Would it be bbop:webbed_forest in a BBOP world?

commented
		<planet name="Dark Bramble" DIMID="31" customIcon="marslike">
			<isKnown>true</isKnown>
			<gravitationalMultiplier>32</gravitationalMultiplier>
			<orbitalDistance>1000</orbitalDistance>
			<orbitalTheta>45</orbitalTheta>
			<orbitalPhi>0</orbitalPhi>
			<rotationalPeriod>8000</rotationalPeriod>
			<atmosphereDensity>75</atmosphereDensity>
			<biomeIds>openterraingenerator:overworld_webbed_forest</biomeIds>
			<oreGen>
				<ore block="contenttweaker:arbitrarium_ore" minHeight="20" maxHeight="80" clumpSize="3" chancePerChunk="64" />
				<ore block="minecraft:cobweb" minHeight="1" maxHeight="80" clumpSize="30" chancePerChunk="10"/>
			</oreGen>
		</planet>

On non-OTG worlds, it just generated regular biomes. On a Biome Bundle world, it generated this:

I suppose I sort of understand non-OTG worlds not being able to use OTG biomes, but I don't see why a Biome Bundle world made it generate as an infinite ocean.

commented

image
on AR discord (link to message)

commented

Try it without the underscores? Ik if u wanna tp to the biomes you have to actually use the spaces and advanced rocketry's alien biome shows this exact same behavior in a biome id so it isn't a stretch to think that it needs spaces instead of underscores.

commented

I grabbed that biome id from a biome dump command. I teleported to the dimension using /advRocketry goto 31, since 31 is the dimension id for that planet. Also, I don't think ids can have spaces in them at all.

commented

Yes they can, look at the id for the alien forest biome from advanced rocketry which is advancedrocketry:alien forest

commented

image

commented

Yea so it's definitely an issue with advanced rocketry not like whatever weirdness otg does with their biomes.

commented

Hey folks,

OTG registers and unregisters its biomes during a session. Registration happens whenever a world or dimension is created, or an existing world is loaded/joined. Unregistration happens whenever a world is left (SP) or when a dimension is deleted during a session (via the O menu).

Other mods that add biomes tend to register their biomes at app start, not during a session, so this might be causing problems. Also, if you want to be able to use biome resourcelocations to target OTG biomes, openterraingenerator:overworld_webbed_forest would only be registered if you have an overworld using the Biome Bundle preset (which has the webbed forest biome).

OTG biomes have 2 numerical id's btw, an internal otg id (/otg biome) and an mc registry id (/otg biome -s). Biome id's are dynamically generated during world/dim creation, depending on the currently available id's. When adding the same dimensions and the same mods in the same order, biome id's should always be the same. If you're targeting numerical biome id's, you would have a problem though with biome id's changing when users manually delete/create dimensions in the wrong order during a session via the O menu.

commented

How would I find the correct biome id? Would it work on non-OTG worlds? In worlds that started as non-OTG, but became OTG because of the Config.yaml, would that work?

commented

While in a world, you can use /otg biome, /otg biome -s or /otg biomes to get all the id's/resourcelocations.

You cannot turn a non-otg world (created without OTG / not by OTG) into an OTG world. You can only add OTG dimensions to it.

You might be able to use an OTG overworld (which registers its biomes before any other world/dim is loaded) with a non-otg dimension that uses the webbed forest biome. Ofcourse OTG wouldn't actually do the generation/population, so it wouldn't look anything like Biome Bundle's webbed forest. You can ofcourse create a new OTG dimension containing only the webbed forest biome (ask in the Disc how to edit/create presets).

commented

You can ofcourse create a new OTG dimension containing only the webbed forest biome (ask in the Disc how to edit/create presets).

Would I be able to do this in addition to having dimensions for BB + BBOP? I remember you said you can't have multiple dimensions of the same preset

commented

If you're copying biomes from another preset into your own new/cloned preset, it counts as a whole new preset. You only can't use the exact same preset folder (openterraingenerator/worlds/presetname/) for multiple dimensions atm.

The only problem you might run into, is running out of biome id's. Ofcourse if you only use 1 biome in your new preset, that should be fine. Unfortunately BOP registers quite a few biomes, so that limits the amount of otg biomes you can add.

*There are more people who can answer these kinds of questions (setup/presets) on the disc btw, I may not be the quickest to respond.

commented

*word of advice, try not to use underscores in your preset name, in some cases that can cause problems (having 2 presets, "MyPreset" and "MyPreset_1" fe). Just use spaces to be sure.

commented

Please ask on the Disc for additional advice with this, you understand that truly static pre-defined biome id's aren't an option atm, and that OTG has to generate its own biomes. If you have a new proposal, feel free to re-open this.