Larian Banner: Baldur's Gate Patch 9
Previous Thread
Next Thread
Print Thread
Joined: Feb 2018
D
apprentice
OP Offline
apprentice
D
Joined: Feb 2018
Are instances in level templates supported? I've created a level template, added instances and within the editor it works perfectly. However, if I fire up the game and play my level placed instances inside the level template don't show up.

Joined: Sep 2017
member
Offline
member
Joined: Sep 2017
Hi DerCapac,

There are some fixes to painted instances planned for the next patch, including fixes for level templates.

Joined: Feb 2018
D
apprentice
OP Offline
apprentice
D
Joined: Feb 2018
Sorry to revive this old post, but we had a chat recently on discord where TheComposer indicated that this feature is working for him. However, in my mod painted instances inside placed level templates still don't show up in game.

Here is what my level template looks like in the editor:
https://cdn.discordapp.com/attachments/366250879101304832/472400006041567233/in-editor.JPG

And this is how it renders in the actual game:
https://cdn.discordapp.com/attachments/366250879101304832/472400062144839710/in-game.JPG

Kevin asked me to check whether my editor and game are up to date and I've verified all my steam caches. The game on Steam is at 3.0.226.993 (which is the current release according to the forum: http://larian.com/forums/ubbthreads.php?ubb=postlist&Board=66&page=1) and the editor is at 3.0.232.183. So everything seems tp be up to date.

I noted a new error is showing up, at least I didn't noted it before: Instancegroup with merged leveltemplate uuid (cc430ae4-2bb3-4b00-8523-7c89ac1c4e55_6afad9bc-189c-4df9-8e07-e55b6868ce28) already exists when instantiating leveltemplate?

TheComposer asked me to check level boundaries and do a complete ai grid rebuild, but that didn't help.

So, am I doing something wrong, do I have to change / configure something? Or is it a misunderstanding and the feature is not available in the game version on Steam?

Last edited by DerCapac; 30/07/18 11:17 AM.
Joined: Sep 2017
veteran
Offline
veteran
Joined: Sep 2017
Judging by the error, could you have a look at the following path and check if there's a merged.lsf file in the folder?

Quote
\Data\Mods\YourMod\Levels\YourMod_Level\LevelTemplates


If there is, can you copy it someplace else as backup, then remove it?

Edit: Alternatively have a look into the level template folder (should be a separate level on its own), and see if you see any oddities within the /Instances/ folder there?

Here's a screen cap of how mine looks.

[Linked Image]
[Linked Image]
[Linked Image]

Last edited by The Composer; 30/07/18 12:58 PM.
Joined: Feb 2018
D
apprentice
OP Offline
apprentice
D
Joined: Feb 2018
Okay, checked this. I don't have a merged.lsf file in the folder "LevelTemplates", as I'm building a standalone mod and don't overwrite anything from the main game this is the expected behavior I guess.

Went through the the instance group folders, they all contain a file named "group.lsf" and a bunch of "batch_##.lsf" files, so they basically look like yours. Also checked for naming collisions, all the folders have unique guids after the "group_" part.

So, just to add that, the instances show absolutely no issues in the editor, I can edit them perfectly and they show up as expected in the editor.

Last edited by DerCapac; 30/07/18 01:33 PM.
Joined: Sep 2017
Location: Belgium, Ghent
addict
Offline
addict
Joined: Sep 2017
Location: Belgium, Ghent
That error occurs (editor only) when the instance groups (behind the scenes, every used visual is put in a separate group) are being read from file, and it attempts to merge the same level template multiple times with that group.

Are you by any chance placing the same level template multiple times?

Also: Does it work if you explode the level template? (Not that that is a useful solution, but it might help us rule out some possible issues).

Last edited by Larian_KVN; 30/07/18 03:46 PM.

CTRL+K the elf
Joined: Sep 2017
veteran
Offline
veteran
Joined: Sep 2017
Yeah, I've discovered multiple issues with plopping down the same level template more than once into a main level. (It'll actually crash the game and engine upon any form for reload, at least if you're doing it in a Larian main-map, from my experience).

Joined: Feb 2018
D
apprentice
OP Offline
apprentice
D
Joined: Feb 2018
No, all the level templates are there only once, I use them to place interiors and caves, no need to have them multiple times.

I've exploded the level template and loaded my game, the instances show up after exploding the level template:
https://imgur.com/a/adJzjSt

Joined: Feb 2018
D
apprentice
OP Offline
apprentice
D
Joined: Feb 2018
@Kevin: The error mentioned earlier (Instancegroup with merged leveltemplate uuid (...) already exists when instantiating leveltemplate?) shows only when changing the persistent setting of a level template, so probably its only related to that action and not my setup in total.

Joined: Feb 2018
D
apprentice
OP Offline
apprentice
D
Joined: Feb 2018
I've created a completely new story campaign, added a new level, called it "LevelTemplate" and quickly painted some grass (note the brown ground, this is the level template from now on):
https://imgur.com/a/H5DQYh4

Next, I've created a RootTemplate for the Level "LevelTemplate" and a new level "Main", placed the Level Template in there, generated the AI grid, added a trigger as a starting point for the character creation script:
https://imgur.com/a/X9Z9rbO

I've added the character creation setup from the wiki and did a story build, this is what I get when I launch the game: Instances in the level template in the actual game.
https://imgur.com/a/0j4ea2D


I'm happy to see the system at work. But, well this test case is not complete yet. The main level is pretty empty right there. So I headed back to the editor and painted some grass onto the main level terrain:
https://imgur.com/a/TPZ1ZNB

And, yes, it's broken. Back in the game, the instances of the level template now become lost / hidden / whatever:
https://imgur.com/a/ddyqbq6

Last edited by DerCapac; 31/07/18 09:02 AM.
Joined: Sep 2017
Location: Belgium, Ghent
addict
Offline
addict
Joined: Sep 2017
Location: Belgium, Ghent
Thanks for the detailed steps DerCapac!

I'm suprised this issue doesn't come up for Composer, if it's so easily reproduced that way.
I noted it down and we will take a look / fix whatever needs fixing smile

In the meantime, sadly, there is no better workaround I can provide than exploding the template.

Sincerely,
Kevin


CTRL+K the elf
Joined: Feb 2018
D
apprentice
OP Offline
apprentice
D
Joined: Feb 2018
Thanks a lot, Kevin! This was in no way meant to be a bug report, I primareley wanted to figure out whether this is supposed to work and whether I did something wrong. But of course I am more than happy if you could check if there is a problem in the engine.

Level templates are a great feature of the Divinity Engine! Obviously you at Larian will start a project far better prepared than most of us modders, so when you actually start building a level you probably have a good idea what will be in there and which parts will be needed and can plan ahead accordingly. For those of us with a less of a scaffolding to work along, level templates allow a great degree of freedom to rearrange level parts on the fly without having to rebuild stuff.

(Also, just to mention it, they already do some crazy stuff. e.g. if one paints surfaces or movement data to the ai grid of a level template, those information will be compiled into the ai grid of the hosting level, which is amazing!)

Last edited by DerCapac; 31/07/18 12:28 PM.

Moderated by  Larian_KVN 

Link Copied to Clipboard
Powered by UBB.threads™ PHP Forum Software 7.7.5