Larian Banner: Baldur's Gate Patch 9
Previous Thread
Next Thread
Print Thread
Joined: Sep 2017
veteran
OP Offline
veteran
Joined: Sep 2017
So the level template system is in theory pretty ingenious and practical, but...

It doesn't seem to go hand-in-hand with story goals, as if you add a level template to a level, as in my test, I added a small testlevel to another level. Any story goals written for the small testlevel will no longer work, example;

An event trigger that makes a displaytext trigger, works in small testlevel but not in its level template in the other level its added into. Any item added in the level template gets a completely new GUID.

I post here in troubleshooting because somehow I feel that can't be the intended design? Or is the workflow make the entire map down to each brick > add to main level > add characters, items, loot, secret digspots +++ while in the main level > write story goals ?

Last edited by The Composer; 01/11/17 06:08 PM.
Joined: Sep 2017
M
member
Offline
member
M
Joined: Sep 2017
So for me i have the following setup: One main level (with one big script) with alot of DBs defined in a INIT (like quests, dialogs etc) if i teleport the player to a different level yes all items get new GUDIs. IF i want to access items from diferent levels i need to put them global for project. But i also noticed that if I move the character to the next level that some DB's which I defined (and were loaded during the first level) arent available anymore in the 2nd level. So to make sure I didnt miss anything i just created another script specifically for that level that gets started when the 2nd level loads.

your issue is also strange -> maybe its all the same reason?

Joined: Sep 2017
veteran
OP Offline
veteran
Joined: Sep 2017
I'm not sure I understand exactly what you're trying to say, or how it applies to the question I raised. You need what ever character/item you want to respond to scripts cross-level to be global yes. Next levels would naturally have other GUIDs as it's another level. But I'd have hoped level templates kept its content identical because added level templates should update on the fly if you edit its original source, implying they're interconnected as one constant level. Say you add Level Template A to Fort Joy. You load Level Template A and add a tree. That tree should then show in Fort Joy too. But you can't target that tree in Fort Joy unless you explode Level Template A, which is fine as that's what you do once you're done.

My issue with that is, if you want to make scripted events, such as an execution, destructible objects, secrets or what-not, that work won't be lasting if done while working on Level Template A. You'd either have to go through every item, character, etc and do a find and replace for each corresponding GUID, or do only the terraforming and decoration in Level Template A, and then make anything relying on Story Goals in the main map, which means anyone putting level templates to use, statistically are prone to have a pretty huge map eventually, and doing tons of adding new items and experimenting back and forth in a Fort Joy / Reaper's Coast sized map puts a strain even on my system.

Writing all this makes me realize, that's probably just how it is. But oh-what a missed feature and development convenience that's been overlooked.

Joined: Dec 2013
old hand
Offline
old hand
Joined: Dec 2013
Did you make your level template persistent?

I am pretty sure that event triggers placed in a level template level were still working correctly for me in the 'parent' level that used it as a template. I will do some testing again with that to verify though.

I am however debugging what I think is a related problem with Camera Spectator Triggers. If I try to switch the player's camera view to a spectator camera that is located in a level template, it only works when the player is physically located in that level but not in levels that make use of it as a template.

It may be that they intended level templates to primarily be used for editing and shaping non-interactive terrain though, which as you said would be a bit of a bummer.


DOS2 Mods: Happily Emmie After and The Noisy Crypt

Steam Workshop
Nexus Mods
Joined: Sep 2017
veteran
OP Offline
veteran
Joined: Sep 2017
That is a very good idea / suggestion! I haven't learned / experiemented with that yet, but had sort of naturally ruled it out as I've only seen ActivatePersistentLevelTemplate been used in the campaign like... Perhaps five-or-so times? And almost none of their level templates that I recognize from the campaign are set as persistent so I drew the conclusion that it can't be the case. But, now as you mention it, I do recall having read something about a travel agency and transporting characters/items cross level.

I'll experiment a bit and return with what ever my results may be.

Joined: Sep 2017
veteran
OP Offline
veteran
Joined: Sep 2017
Doing a ActivatePersistentLevelTemplate(a34ed151-af71-4f09-9d28-f1f00e914506); on the "main level" seems to make the story goals respond to the intended objects, so it indeed seems to be the way to go! I'm still a bit vary but with this, I'll proceed with working as I've done so far, and should it not work out in the end for what ever reason, it's just a massive chore of combing through everything with a find & replace job, which in worst case is a good dual-monitor Netflix bingewatch excuse to combine with.

Thanks for your feedback Windemere, it seems like it's what I need to do.

Joined: Dec 2013
old hand
Offline
old hand
Joined: Dec 2013
Sure thing, glad it helped. I have the same trepidation going forward especially in light of those cameras not working for me right now.


DOS2 Mods: Happily Emmie After and The Noisy Crypt

Steam Workshop
Nexus Mods
Joined: Mar 2016
Location: Belgium
T
addict
Offline
addict
T
Joined: Mar 2016
Location: Belgium
An alternative to persistent level templates, is to make the items/triggers/characters that you want to have the same UUID everywhere as global.

A major purpose of non-persistent regular level templates is to be able to insert the same level multiple times in different places, with every instance being completely independent of every other instance. Hence, the fact that UUIDs for items inside the level templates are regenerated in indeed inherent to that. There's no easy way to get those UUIDs, unfortunately (the "easiest" way I know of is interacting with the items and then checking osirislog.log).

Joined: Sep 2017
veteran
OP Offline
veteran
Joined: Sep 2017
Thank you, Tinkerer. I will experiment some with that as well.

Joined: Dec 2013
old hand
Offline
old hand
Joined: Dec 2013
Thanks Tinkerer.

Do you know whether it is a bug or working as intended that spectactor camera triggers do not appear to work when they are placed in the level serving as the template and then referenced by a level using that template?

For instance, I have event triggers and spectator camera triggers in Level A.

Level B uses Level A as a template.

If a player is in Level B and enters one of the event triggers originally placed in Level A, it is supposed to activate a camera spectator trigger associated with that trigger (also placed in Level A). The event triggers do fire as expected and call the procedure CameraActivate(), but I get an error in the editor as follows:

Code
Could not find camera SoM_OM_SpecCamB3 when activating from osiris

Category: Design
Count: 1
Timestamp: 03-11-2017 19:04:32:560
Function: ecl::GameProtocol::ProcessMsg
Location: EoCClient\Client\GameProtocol.cpp (623)


If I run the same test from within the template Level A itself, it works fine. It just doesn't work when used as a level template in another level.

It's notable that the CameraActivate() procedure uses the trigger name rather than a GUID for the spectator camera. I wonder if whatever tricks were used to be able to access the original GUIDs doesn't work for the names?


DOS2 Mods: Happily Emmie After and The Noisy Crypt

Steam Workshop
Nexus Mods
Joined: Mar 2016
Location: Belgium
T
addict
Offline
addict
T
Joined: Mar 2016
Location: Belgium
Have you tried making that spectator camera global? I have no personal experience with spectator cameras, and I don't think we have any in our own level templates, so it's quite possible they don't work together very well.

Joined: Sep 2017
veteran
OP Offline
veteran
Joined: Sep 2017
Speaking of level templates, any reason why instance paintings don't transfer along with level templates? Or is that a persistent thing too?

Joined: Mar 2016
Location: Belgium
T
addict
Offline
addict
T
Joined: Mar 2016
Location: Belgium
Originally Posted by The Composer
Speaking of level templates, any reason why instance paintings don't transfer along with level templates? Or is that a persistent thing too?

That sounds like a bug. I noticed that a bug regarding instances and inherited levels was recently fixed (not yet in any released patch), maybe that will also solve this issue.

Joined: Sep 2017
veteran
OP Offline
veteran
Joined: Sep 2017
I will await any workarounds until a patch or two then, no need to divert extra time into something that may be unecessary. Thanks!

Joined: Dec 2013
old hand
Offline
old hand
Joined: Dec 2013
Originally Posted by Tinkerer
Have you tried making that spectator camera global? I have no personal experience with spectator cameras, and I don't think we have any in our own level templates, so it's quite possible they don't work together very well.


Yeah, I had tried that and it didn't make a difference. Thanks for the reply, probably just something to work around.


DOS2 Mods: Happily Emmie After and The Noisy Crypt

Steam Workshop
Nexus Mods

Moderated by  Larian_KVN 

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