#DawnLib [V80]

1 messages · Page 18 of 1

drowsy pendant
#

god I feel this though

#

mod development is hell and why we continue to return is beyond my mere mortal understanding

#

I'm pretty sure one of my moons has a similar patch note string

static iron
#

Its monday

mint rain
#

do you have any idea if the dawnlib transpilers could cause [this indexing error](#1485178606983319552 message) to be thrown?

#

i took a brief look at this function and i didnt notice any way for vanilla to throw this error

#

at least, i didnt notice immediately

#

just curious if you might have some insight

oak linden
#

hmm

#

i dont think so, i only add my own logic, i dont mess with anything in vanilla

#

my stuff is basically just:

// vanilla stuff
if (NOTDawnLibOrLunarConfigEnemy)
{
  // more Vanilla stuff
}
// more more vanilla stuff
#

this was how i skipped assigning numberSpawned and the other field

mint rain
#

i see

oak linden
#

with DawnLib i imagine you'd see the error with outside and the other methods too since they use the same transpiler

mint rain
#

it's apparently only showing up on specific moons

oak linden
#

oh interesting

mint rain
#

and i guess i'd need to take a peek at what's happening at runtime with unityexplorer

oak linden
#

would make me wanna look into it just incase maybe

mint rain
#

when the error gets thrown

oak linden
#

yea

#

could look at daytime enemies list

mint rain
#

all i have is the bug report though

oak linden
#

i havent actually looked at whats erroring tbh

mint rain
#

[it apparently affects submersion from generic moons](#1485178606983319552 message)

#

but like

#

vanilla has code to automatically skip daytime spawns when the list is null or count 0

#

and i dont see any other reason it'd ever be accessing an array out of bounds

oak linden
#

the error was pointing at it failing at the this.

#

which confuses me more

#

maybe the error was shifted around due to transpilers in that method? no idea

midnight schooner
#

you should only trust the offsets for the general area

raw swift
#

the current version of the library (0.9.18) dumps hundreds of lines of logs printing out the IL for several functions, if these could be downgraded to Debug logs that'd be nice

#

jeez it's like 2500 lines of logs at least

oak linden
#

the last few updates have not been kind to me and i forgot it and i immediately knew i forgot it and i was pissed

#

these logs dont need to exist so not even debug, they're just gone

#

apologies for the startup spam lol

#

atleast its only on the start so easily skippable

oak linden
#

v0.9.19

  • Code cleanup.
  • Added the ability to add crouching footsteps to a custom footstep surface.
  • Added the ability to control the volume of all audioclips in a custom footstep surface.
  • Added the option to have a bundle in a content container disabled/enabled by default.
  • Added the ability to create your own story logs system similar to sigurd's for the terminal.
    • You can use the scripts CommitKeyToSave and ExtraScanEvents to unlock parts of the log.
    • This is not part of the story log registry, it is part of the terminal commands registry, this may be changed in the future.
  • Added a soft reset all progress to achievements for AchievementTriggers script.
    • This allows resetting achievement progress IF the achievement had not been completed.
  • User generated configs from the editor are now affected by the AllowEditingConfig setting.
  • Fixed issue with disabling/enabling DawnLib on and off with older save files affecting newer ones.
#

i've gotten uncomfortably good with transpilers and i dont like it

urban plaza
#

Added the option to have a bundle in a content container disabled/enabled by default.

this is actually something i needed conveniently earlier today, i appreciate you mindreading

oak linden
#

Lol

fallow remnant
#

I'm so happy that Dusk is out, glad you managed to pull it out guys

#

oh wai~

sacred gull
#

i have a strange problem with downlib i think

#

when i create a lobby and quit without closing the game if i try to join the world and invite a friend he is instant disconnected. but if i reload the game my friends can join. do u know what can cause that?

oak linden
#

Also are you sure it's dawnlib?

sacred gull
#

here it is

#

.

oak linden
#

Oh this

sacred gull
#

yeee

oak linden
#

You honestly had too many errors for me to tell

sacred gull
#

but if i use downlib version 0.9.15 the game don't have this problem i don't understand why

#

if u wont i can send u the log from my friend when try to join

#

19:35:32.0005685] [Error : Unity Log] Failed to assign new player with client id #3: System.NullReferenceException: Object reference not set to an instance of an object
at Dawn.MapObjectRegistrationHandler+<>c__DisplayClass11_0.<UpdateOutsideMapObjectSpawnWeightsOnLevel>b__0 (SpawnableOutsideObjectWithRarity mapObject) [0x00000] in ./src/API/MapObjects/.MapObjectRegistrationHandler.cs:582
at System.Linq.Enumerable.TryGetFirst[TSource] (System.Collections.Generic.IEnumerable1[T] source, System.Func2[T,TResult] predicate, System.Boolean& found) [0x0003f] in <ea489521390f48908a7ce45cb17a6848>:IL_003F
at System.Linq.Enumerable.FirstOrDefault[TSource] (System.Collections.Generic.IEnumerable1[T] source, System.Func2[T,TResult] predicate) [0x00000] in <ea489521390f48908a7ce45cb17a6848>:IL_0000

#

at Dawn.MapObjectRegistrationHandler.UpdateMapObjectSpawnWeights (On.StartOfRound+orig_SetPlanetsWeather orig, StartOfRound self, System.Int32 connectedPlayersOnServer) [0x00013] in ./src/API/MapObjects/.MapObjectRegistrationHandler.cs:532
at (wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition.HookStartOfRound::SetPlanetsWeather?-2139390820(StartOfRound,int)
at (wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition.TrampolineStartOfRound::SetPlanetsWeather?-1957426834(StartOfRound,int)
at CodeRebirthLib.Patches.StartOfRoundPatch.RefreshEnemyWeights (On.StartOfRound+orig_SetPlanetsWeather orig, StartOfRound self, System.Int32 connectedplayersonserver) [0x00000] in ./src/Patches/StartOfRoundPatch.cs:26

#

at (wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition.HookStartOfRound::SetPlanetsWeather?-1822673500(StartOfRound,int)
at (wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition.TrampolineStartOfRound::SetPlanetsWeather?1369423318(StartOfRound,int)
at EasterIsland.Plugin.<Awake>b__26_8 (On.StartOfRound+orig_SetPlanetsWeather orig, StartOfRound self, System.Int32 connectedPlayersOnServer) [0x00001] in C:\Users\User\Documents\LC-ExampleEnemy-main\Plugin - EasterIsland\src\Plugin.cs:497
at (wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition.HookStartOfRound::SetPlanetsWeather?1707407552(StartOfRound,int)
at (wrapper dynamic-method) StartOfRound.DMDStartOfRound::OnPlayerConnectedClientRpc(StartOfRound,ulong,int,ulong[],int,int,int,int,int,int,int,bool)

#

this is the problem

#

and i don't know from what is caused

jolly quail
#

Something with EasterIsland.

sacred gull
#

i added today easterland. i had this problem like 4 days ago

#

when i update downlib i can't enyone join me after reload the lobby without closing the game

#

i think the problem is from updateoutsidemapobjectspawnweights but i don't understand how and why

jolly quail
#

It could be any number of things, you have nearly 400 mods in your pack.

sacred gull
sacred gull
atomic flame
#

Hello, I need to configure a mod and am looking for the "namespace" of the Wesley weather mods. How can I find this information please ?

atomic flame
#

I had a rummage around to see how it worked and found this information, but I must admit I couldn’t find or understand how to do it ^^

sacred gull
#

@oak linden Dawnlib v0.9.19 actually causes this rejoin problem. Now I'm trying to update it to version 0.9.20 hoping that solves the problem. I have no idea what caused it. Without updating your mod, the game runs smoothly without errors. I don't know what you changed from version 0.9.15, but apparently it breaks the rejoin in the lobby if a person crashes and tries to rejoin. I updated all the other mods and everything works. The problem only occurs with your mod. Sorry again for the insistence and for the tag.

#

0.9.20 still don't let join. i try it now

oak linden
#

I understand but even if I wanted to help debug this, there's no way I can test your 400 Mod modpack

calm maple
#

yea, you need to get those numbers up. Xu can't help unless you have at least 500 mods

#

600 pref

oak linden
#

Also I need a gift of a new pc to test it, I don't test for free

harsh holly
#

what if i offered u one corn chip and a kitten?

sacred tulip
#

The kitten might actually convince Xu

sacred gull
#

tnx for answering ^^

harsh holly
#

xu... come adopt my foster kitten

sacred gull
midnight schooner
#

400 mods is enough to kill a victorian child. debugging that and finding out the exact specific cause, when over 400 things are trying to modify the game in their own way is practically impossible

jolly quail
#

Yeah, no offense, but looking at the modlist it just kinda looks like you picked whatever.

urban plaza
#

its okay jsut turn off 100 mods at a time to narrow it down

torn summitBOT
harsh holly
#

Jokes aside ty for dawn lib its made my life so much easier

lunar mantle
#

uhhhhhh-

oak linden
#

you got multiple instances of the game open or smthn?

#

i cant do anything with a screenshot of a log

lunar mantle
#

No

#

I only have one singular instance

oak linden
#

the error do just be that you're accessing this file through multiple sources like multiple instances so iunno

lunar mantle
#

I dunno how the hell its doing that but it is only one instance of Lethal

lunar mantle
lunar mantle
#

Well I have no idea

#

Since I am only running one instance

#

so im confused

oak linden
#

maybe try restarting your pc, im not sure where it's being accessed from

hollow viper
#

If still hapening

sacred gull
oak linden
#

:shrug

#

nothing much changed on 0.9.16

#

and i tested it myself, it was working fine on latest

#

without 400 mods obviously though

sacred gull
#

I update 0.19.15 too 0.19.19 i'll try 16/17/18

#

Now i'm at work T.T

frozen widget
#

@oak linden does custom surface footstep allow water trigger compat?

#

because the base water trigger requires you to be on grass

#

and it's not "grass" tag, it's also footsteps MUST be grass

oak linden
#

im fairly sure it is just requiring your collider to be tagged as grass lol

#

but yes

#

there is compat for custom surfaces to be useable in water, quicksand, and earth leviathan

oak linden
quaint sigil
#

The game takes forever to launch with just 160 mods xD why tf people out here with hundreds

alpine mica
#

It about the journey not the destination plink

static iron
#

What if there is no journey

#

Then what is it about

icy tulip
#

every time you load????

oak linden
#

5 minutes is impressive for 400 mods

#

But still, am not interested in testing that

lunar mantle
sacred gull
#

i load in 5 minute with a 8/9 gb ram used. and for load the world i need like 1/2 minute (my friends too)

sacred gull
#

when i use 0.19.16 the game stop load any type of interiors after quitting and rejoin. so can i ask exactly what did u add from 0.19.15 too 0.19.16?

#

v0.19.21 break everithing like maps interiors and loading. the game load the first vanilla interiors, the next day i have infinite loading seed with a casual interior. i wait like 20 minute but i don't get any error or issue and if i try to quit and create a new game when i try to run another day the console say 3rd day (again with infinity sees loading) if i quit and join another world the console say 4th day with a casual interiors (again infinite loading seed) something with this updates save stuff from lobby

oak linden
#

Again, I can't debug any of this with your 400 Mod modpack, but you can send a log if you'd like

calm maple
sacred tulip
#

500 dawnlibs

slender violet
#

One day the only mod all lethal company community will need is dawnlib

sacred gull
#

.

#

.

#

this are the logs

#

with dawnlib 0.19.15 all work fine

#

this log are with dawnlib 0.19.19

sacred gull
sacred gull
hollow viper
# sacred gull .

why do you have coderebirthlib again? (its prob been asked before so again)

static iron
hollow viper
static iron
hollow viper
wind mist
#

What's the easiest way to get an EnemyType from a DawnLib ID of an enemy?

oak linden
#

In what way do you have the ID

wind mist
#

string

oak linden
#

And from there doing
LethalContent.Enemies.TryGetValue(NamespacedKey.From<DawnEnemyInfo>(Namespace, Key), out DawnEnemyInfo enemyInfo);

#

Whoops

wind mist
#

I get this error when trying to land on a moon I've configured in Lunar (stays frozen on seed screen), I think it has something to do with making indoor objects spawn outside, which used to work. Someone else has reported a similar issue as well.

#

On this moon Landmines were supposed to spawn outside

sacred gull
#

i'll ask tartarus creatore if i need it

oak linden
static iron
#

Code?!?!

#

Like rebirth?

static iron
wind mist
oak linden
#

same for IndoorMapHazard, you need to create that SO for the InsideInfo and fill the stuff that it needs in there

wind mist
#

Did that change recently?

#

Oh yeah that changed in v80 didn't it?

wind mist
# oak linden are you just giving the hazards an `OutsideInfo`? you need to also give em a `Sp...

Well this is what I do when it doesn't have an OutsideInfo

dawnObj.OutsideInfo = new DawnOutsideMapObjectInfo(new SpawnableOutsideObject(), newTable, true, 0);

DawnOutsideMapObjectInfo outsideInfo = dawnObj.OutsideInfo;

outsideInfo = dawnObj.OutsideInfo;
outsideInfo.SpawnableOutsideObject.objectWidth = 12;
outsideInfo.SpawnableOutsideObject.spawnableFloorTags = Array.Empty<string>();
outsideInfo.SpawnableOutsideObject.rotationOffset = Vector3.zero;
outsideInfo.SpawnableOutsideObject.spawnFacingAwayFromWall = false;

outsideInfo.ParentInfo = dawnObj;
#

That's making the SpawnableOutsideObject right?

oak linden
#

Also give it a .name

oak linden
sacred gull
#

what is this error? O.O

wind mist
#

Seems like it did, but I don't know what that does exactly so let me know if I shouldn't be using that :p

oak linden
#

Just don't forget to edit the .name for the .SpawnableOutsideprofabToSpaw too

wind mist
#

What does the .name need to be?

oak linden
#

Something like MapObjectInfo.Key.Key.ToCapitalized()

calm maple
#

Key.Key.Key.Key

oak linden
#

yeah that naming will haunt me 😔, it's not even inaccurate

sacred gull
#

i probably figure out the problem, or mirage v81, shiplobbyplus or lethalmin. this mod togheter break dawnlib rejoin apparently i don't understand how and why but LOL

sacred tulip
#

rejoin?

sacred gull
# sacred tulip rejoin?

yeah if i uppdate dawnlib over 0.19.15 my modpack explode with interiors and lobby rejoin without closing the game. is pretty strange XD

sacred tulip
#

i know mirage is kinda broken

#

also you dont need v81 anymore

#

the og mod updated

#

but still has the same issues it seems

#

with the spawn control stuff

#

that you gotta disable

#

lobby rejoins you mean closing and opening the save? or latejoining?

sacred gull
sacred tulip
#

no

static iron
#

cheese said no

carmine elk
#

Rodrigo said Cheese said no

sacred gull
#

lol

sacred gull
sacred gull
sacred tulip
#

hehe i use lunar to give weights to any moon

frozen widget
#

mr/mrs dawnlibs, can i get something to register my kidnapper fox variant/s

static iron
#

stare Arch duke Dawnlib of Dawntopia, i solemnly request thy aid in recapturing the motherland of Rodrigia

#

-# xu sleeping rn

sacred gull
oak linden
sacred gull
# oak linden Idk what you're looking for

yo. can create problem with dawnlib selectableinteriors or Dantors_Mental_Hospital? yesterday i try to update again dawnlib and give me a multiple error registration, can i send it to you and ask for your a opinion about it?

oak linden
#

uh sure i guess

sacred gull
#

lol wrong log

#

this is the specific error for rejoin the save without closing the game

sacred gull
oak linden
#

you got lunar config?

sacred gull
#

nope literally now i'm try to disable selectableinteriors and add lunarconfig

frozen widget
#

And spawning vain shrouds(or variants of em) via LLL is impossible

#

Same as dawnlib

#

There's no way to configurate allat

#

Giving the fox variant the weights on moons will just not make it spawn either, so it's just useless

sacred gull
hollow viper
#

What is bergsbahgul

frozen widget
#

So Xu, can you add something for enemies spawning with vain shrouds and custom vain shrouds registration?

#

Pretty pleab :>

oak linden
#

uhh, probably not much, i can make adding vain shroud skins, but i don't really want to change vanilla spawning behaviour

frozen widget
#

Why, hardcoded values?

oak linden
#

i also dont really know how the fox decides to spawn
Its likely such an unpolished part of the game as zeekerss only intended the fox to be able to spawn that I won't want to mess with it much as it might change drastically in the future

#

maybe @mint rain can shed some light for me on whether the fox uses anything like spawn weights etc that would make it make sense for me to be able to mess with fox spawn weights and whether adding vain shroud skins won't screw with the fox's visuals if it's able to spawn from said skins

sacred gull
mint rain
#

it'd be really really easy for you to add kidnapper fox variants

#

but the system, as it's currently designed, has a bunch of unused stuff that is not used at all

#

because zeekerss seemed to design the system to be expandable and support other enemy types

#

even though the kidnapper fox is the only "weed enemy" in the game right now

#

im not sure how likely that is to change in the future

#

these are the important notes:

  1. WeedEnemies is a persistent list that is attached to RoundManager.Instance and not individual moons
  2. weed enemies only spawn if at least 16 vain shrouds generated when the ship landed (this number will be x), and then there is an x/70 chance the wave will succeed each time inside/outside/daytime monsters spawn
  3. weed enemies are completely blocked from spawning until 9 AM
  4. there is no "weed enemy spawn curve", it is a purely random amount (either 1 or 2) every time the wave succeeds
  5. like outside spawns, whenever SpawnWeedEnemies calls SpawnRandomWeedEnemy() (once or twice, if the wave is not blocked), it will reset numberSpawned and hasSpawnedAtLeastOne
  6. there is 4 total "weed power" which is a hardcoded value every level uses
  7. weed enemies are subject to all of the normal spawn multipliers (probabilityCurve, numberSpawnedFalloff, also increasedOutsideEnemySpawnIndex but that's probably a bug)
  8. additionally, weed enemies' weights are subject to another scalar based on the number of weeds that generated (x/60 is multiplied by their calculated spawn weight, then truncated, then clamped between 0-200)
  9. there is no such thing as "weed diversity", weed enemies just care about power level (same as daytime spawns)
  10. the final wrinkle: if all weed enemies add up to a total of 20 or less weight, the entire spawn wave will be canceled (this is basically the only reason #8 matters, because all weed enemies have their weights scaled by the same value)
#

#4, #6, #8, and #10 are all totally unnecessary

#

or at least, basically unnecessary

mint rain
#

because the kidnapper fox is limited to 1 spawn, weed spawn waves that say "spawn 2 enemies" can never actually spawn 2 enemies

#

the kidnapper fox is 1 power level so the 4 weed power is never actually entirely used up

#

the kidnapper fox is the only element of WeedEnemies with a weight of 100

#

and yet all of the normal spawn weight behavior is there and should function

calm maple
mint rain
#

the kidnapper fox does have a probability curve that reduces its weight as the day progresses, but this doesn't matter because the fox at 21 weight and the fox at 100 weight both still have a 100% spawn chance since no other "weed enemies" compete with their weight

#

it only matters once the kidnapper fox reaches 20 weight, because then that would cancel the spawn wave (but that means the kidnapper fox needs to fail every single spawn opportunity until like 11 PM, and then succeed a spawn opportunity; this is a condition that probably does not occur on any of lethal company's millions of seeds)

EDIT: because of the numberOfWeeds multiplier, it actually could happen more frequently in circumstances where a spawn wave just barely occurs (i.e. at 16 vain shrouds, the wave would be ~77% likely to just get canceled outright, but if it doesn't, the kidnapper fox's weight would be multiplied by ~27%, and if that makes it a lot easier for it to reach 20 weight earlier in the day)

#

anyways

#

dont read the above

#

what you probably care most about:

  1. DawnLib could probably, pretty easily, just replace RoundManager.Instance.WeedEnemies each round with a custom one defined by the moon
  2. you will probably need to transpile the 4f in SpawnRandomWeedEnemy to some customizable currentMaxWeedPower value defined by the moon
  3. authors registering kidnapper fox variants at the same time as the vanilla kidnapper fox would probably want to copy the kidnapper fox's probabilityCurve, otherwise the kidnapper fox would become rarer as the day progresses (and all the additional spawns that normally dont occur would get overcrowded with a bunch of variants)
#

also i missed a couple notes in my initial post so i will correct that

#

but i guess if you really care 4. "weed diversity" does not exist at all and you'd have to transpile that in yourself if you want it to be a thing

#

since like half of this behavior is totally unused by vanilla it 100% could change at any time

#

the question is "how comfortable do you feel providing the option to utilize what is there to custom content authors"

#

because, while i don't think it's very likely, it's totally possible he could completely overhaul this behavior if he were to ever add additional weed enemies for real

#

and then you'd have to figure out how you'd translate all the existing weed enemy mods to newer versions of LC

#

what the dawnlib API would have to do with old weed mods

static iron
#

hi!

white finch
#

Finally, DawnWeed script 🔥

alpine mica
frozen widget
oak linden
#

Something to wake up to

#

Thanks buttery, you really do put more effort into this stuff than most lol

#

This system is a lot more polished by zeekerss than I thought

#

I'll have to allow people to register custom vain shroud and custom enemies onto the weed enemies list
Among the many other things you said lol

jolly quail
#

Alrighty so I mentioned before there was potentially a bug with rounds having erroneous scrap totals.

#

The bug seemingly occurs upon team wipe.

#

Not sure on the details but supposedly the value of the day the team wipes on gets added to the next day despite there not being any additional scrap.

oak linden
#

uhh im not sure if im the one causing that one but i should take a look when i get the chance

carmine elk
#

It’s all your fault, Xu. Not DawnLib. You

sacred gull
normal ridge
#

thats my secondary name lol

sacred gull
#

@oak linden i finally found it O.O

lunar mantle
#

what be this

sacred gull
#

this break everything with dawnlib:

  • infinite loading seed
  • rejoin after quit
  • strange save from old save to new save
lunar mantle
#

looks like it’d be an old mod

sacred gull
#

nope is updated for v81

lunar mantle
#

Hmm

#

Interesting

#

what does it do?

sacred gull
sacred gull
lunar mantle
#

I recommend LobbyControl tbh

sacred gull
lunar mantle
#

Yes

#

You can set it to auto join in the configs or you can manually open the lobby from terminal

sacred gull
#

my god is like 1 week i try to figure out the issue

#

finally O.O

sacred gull
#

if u have a screen or something like this i'm literally dead now XD

#

is like 16 hours in a row on this issue hahaha

sacred gull
sacred gull
alpine mica
# sacred gull

Bug Fixes

  • Initial Release for Lethal Company v81

Finally someone fixed this

obsidian marsh
# sacred gull ???

they're poking fun at the changelog for marking initial release as a bugfix

obsidian marsh
sacred gull
thorn abyss
mint rain
#

i am publishing for v1.17.9 right now, which among other things, probably resolves this issue as well

jolly quail
#

Ahh

vernal umbra
#

did anything ever come from that investigation into the dawn save system

#

i think at one point it was mentioned to be something caused by having a non-dawnlib save present as well

#

but it's still happening after i deleted my vanilla save

oak linden
#

Atleast for me if I create a save
Then I delete it without dawnlib existing
Dawnlib would clean it up on next launch

#

It even has logs when it does it too under save manager internal debugging

vernal umbra
#

so should i launch in vanilla and delete the save then make a new one with dawn

#

i should turn on the debug logs while im doing that

oak linden
#

You're saying that would reproduce the bug right?

#

And yeah, debug logs and save manager logs enabled

vernal umbra
#

its been reproducing even without any vanilla saves

#

i got it before when my vanilla save was in slot 1 and my modded was in slot 2

#

and then i got it again when i deleted my vanilla save and loaded modded in slot 1

#

it was an entirely different save that i recognized when i loaded in slot 1

oak linden
#

So
You had 2 saves
1 for vanilla, 2 for dawnlib
Deleted slot 1 without dawnlib installed
Loaded into slot 1 with dawnlib
Items from slot 2 transferred into slot 1?

vernal umbra
#

oh, i deleted vanilla in slot 1 with dawn active

oak linden
#

Ic

vernal umbra
#

what i'm trying rn is deleting my modded save in slot 1 while in vanilla then making a new one in modded

vernal umbra
#

this is after deleting the file in vanilla and loading into it in modded

oak linden
#

And what happened?

vernal umbra
#

everything that was in the file from last load attempt was still in it

#

basically whatever dawnlib wrote to slot 1 isnt getting cleared and it keeps retrieving that

#

im gonna load modded and do both loading and deleting to see if its not triggering something

#

same result as before, the items and upgrades arent being deleted

oak linden
#

Wow you must have something in there mega fucked if its not clearing even with the mod in there when you delete the save

#

Send me a modpack code, I'm not seeing the specific log I was expecting

vernal umbra
#

019e343f-963b-ebb8-1c33-f76700bf0ef3

#

the only other mods i can think of that actively touches saves is brutal, lcbettersaves, and lethalperformance

oak linden
#

I always run with LP so that should be fine

slender violet
#

Even if I'm not using lunarconfig moon options it looks like overrides butterybalance option no coilhead on vow moon.

#

and simulate command doesn't show the correct values with butterybalance

oak linden
#

ill see if i can figure smthn out for when buttery should inject their values later

mint rain
#

well

#

i think what im doing right now

#

is the first time you land on the map

#

it checks the network variable that says "change the interior weights"

#

and then applies the changes on each client before GenerateNewFloor()

#

i assume it shows the correct simulate weights if you land once and go back to orbit?

#

this works for vanilla contexts because vanilla does not have any sort of "simulate" command

#

and i just figured anybody using the simulate command could manually set up interior weights with LLL/lunarconfig/whatever

slender violet
#

It's not a big problem so if it takes a lot of time it doesn't need to add compatibility

wind mist
#

Does Dawnlib mess with special enemies? It seems when things have weights and Lunar Config tags special enemy just gets ignored/overwritten

oak linden
oak linden
oak linden
mint rain
#

if you can set your weights on like startofround.awake
clients need to know what the host's NetworkVariables are set to before they can make changes

StartOfRound.Awake() spawns my mod's network handler for the host, but for clients, I don't know if they willl have the correct values until OnNetworkSpawn() is called on that network handler

#

im actually not sure where that winds up occurring in the pecking order

#

the earliest i could apply changes is "whenever OnNetworkSpawn() gets called on a particular client"

oak linden
#

oh

#

yeah that's way late

mint rain
#

the host can read directly from their config

#

and apply changes in StartOfRound.Awake()

#

so i can make it "correct for only the host" "sort of easily"

#

but if you aren't expecting these values to change mid-game

#

i dont think there's anything i can do for the clients

#

unfortunately

carmine elk
#

hey, idk how big of a deal this is because I doubt it would happen to normal players too often, but I was routed to a LLL moon of mine and quit the game, then turned off LLL and rejoined with DawnLib on and got an IndexOutOfRangeException. It might also be possible if people remove a specifc moon idk. I wonder if there should be a fallback to a vanilla moon

[Debug  :   DawnLib] lethal_company:rend -> 85 Rend
[Debug  :   DawnLib] lethal_company:dine -> 7 Dine
[Debug  :   DawnLib] lethal_company:offense -> 21 Offense
[Debug  :   DawnLib] lethal_company:titan -> 8 Titan
[Debug  :   DawnLib] lethal_company:artifice -> 68 Artifice
[Debug  :   DawnLib] lethal_company:liquidation -> 44 Liquidation
[Debug  :   DawnLib] lethal_company:embrion -> 5 Embrion
[Info   : Unity Log] 1107298560
[Info   : Unity Log] 1107298560
[Info   : Unity Log] level id: 18
[Info   : Unity Log] Changing level
[Error  : Unity Log] IndexOutOfRangeException: Index was outside the bounds of the array.
Stack trace:
DMD<StartOfRound::ChangeLevel>?-218599044.ChangeLevel (StartOfRound this, System.Int32 levelID) (at <f05f43c7ca3f468ba4a72f406fc8b87b>:IL_001F)
DMD<>?-499189248.Trampoline<StartOfRound::ChangeLevel>?-1421404202 (StartOfRound , System.Int32 ) (at <158e3dfcb5d14baa89cf9f319eee5d57>:IL_002B)
Dawn.MoonRegistrationHandler.StartOfRoundOnChangeLevel (On.StartOfRound+orig_ChangeLevel orig, StartOfRound self, System.Int32 levelid) (at ./src/API/Moons/.MoonRegistrationHandler.cs:489)
DMD<>?-1951732064.Hook<StartOfRound::ChangeLevel>?-1354068592 (StartOfRound , System.Int32 ) (at <d34de2cf569847a987fc0ac661e8fc84>:IL_0015)
StartOfRound.SetTimeAndPlanetToSavedSettings () (at <aca1e98d6f844d3f85cd22b6f7be2f9b>:IL_00DD)
StartOfRound.Start () (at <aca1e98d6f844d3f85cd22b6f7be2f9b>:IL_008D)
#

because it did break stuff, even after I routed back to Experimentation. Like the quota and deadline was wrong and the monitor wouldn't show what you were orbiting

#

actually... this could be a vanilla thing maybe now that I think about it

#

yeah, it's vanilla. never mind

#

I mean, you could attempt something on DL's side if you felt so inclined but you wouldn't need to

white finch
wind mist
oak linden
#

In what way?

#

But maybe?

#

Dunno

carmine elk
#

Hey Xu. So, I've got something I'm doing that I kind of need to lock the ship lever for and not let anyone land until done. I don't want to just completely do my own thing since I don't want to unlock it if LLL or DawnLib still need it locked, or the reverse where they unlock the lever before I'm done. I did add compat with LLL because it just seems to handle it in a loop, so with a prefix I can ensure my thing is done and then let LLL handle what it was checking for. DawnLib seems to do it differently and while I think what I have works if both LLL and DL are installed (because I think the LLL loop is overpowering Dawn), I want to make sure it also works if just DL is installed. I see this line where the unlock has a yield return for waiting on some conditions and I think I'd like to just add a boolean of mine there as that would mean both Dawn and my thing are done and it's safe to unlock but I don't know how exactly to do that. I'm wondering if you'd know how to get that slipped in there or if you'd have another idea for ensuring both things are done before unlocking.

GitHub

Lethal Company Library for developing mods. Contribute to TeamXiaolan/DawnLib development by creating an account on GitHub.

white finch
#

(It ain't that bad actually plink)

#

Just gotta keep in mind you ain't patching that method, but rather MoveNext()

#

If you do a Prefix/Postfix it'll get called repeatedly over and over until the Coroutine finishes

#

Transpilers are ideal for em, but the caveat is you gotta write a Transpiler greed

hollow viper
white finch
#

MethodType.Enumerator ye

hollow viper
#

damn had to edit my msg

#

smh

white finch
oak linden
lost crest
oak linden
#

it's definitely a day when i have to write 6 transpilers lol

urban plaza
#

gods little gift

spiral axle
#

looks like an interesting gamemode

oak linden
#

the transpilers are just for more convenient ways to talk with other people in the game instead of mute people sending their messages in discord (in this context its normal to be unmuted in discord talking)

#

i know nicechat is an option that allows for a good chunk of what im doing already, but ehh

#

i took one look at the github and instead wanted to make my own thing

hollow viper
oak linden
#

no

hollow viper
oak linden
#

i think i told you about this thing before

hollow viper
#

not about chat

#

i mean i get what this is for

oak linden
#

ye

sacred tulip
#

I dont know

oak linden
sacred tulip
noble zephyr
#

with Dawnlib and weather tweaks/more weathers, the weathers on the main monitor are different than what is shown in the >moons listing in the terminal

#

when I turn "Vanilla Compatability" on, it fixes the weathers, but it breaks a lot of other mods (Like CodeRebirth). Would love if the weathers worked with Vanilla Compatability off

charred field
#

what's the vanilla compatability setting do?

frozen widget
#

@oak linden what's smart agent navigator script for

#

and should i use it for enemy variants i make

oak linden
oak linden
frozen widget
#

or would at least do a change to the nav agent?

oak linden
#

It wouldn't do anything no

frozen widget
#

well that's too sad

urban plaza
oak linden
drifting night
#

hello hello taishinWave was doing some testing and the newest version of dawnlib seems to make my moon/interior mod break which makes me assume something ive got set up in my mod is going all wonky, i thiiink it might be sound related as i see these 4 errors in the log on the newest version but im not really sure what they mean

#

or atleast i think its this i dont think ive noticed it before

hollow viper
carmine elk
# drifting night

I’m going to guess Xu made those fatal just for visibility. They don’t sound fatal

drifting night
#

ah TS_phoenixThink

carmine elk
drifting night
#

out of curiosity though is anyone noticing issues with any other complex moons with this update?

#

if not im assuming its something funky with my moon setup thats just not vibing with a new dawnlib feature

drifting night
#

thats

#

a really good idea

hollow viper
drifting night
#

wtf okay i tried to but its only loading a log from over a month ago

#

uhhhh

#

wait im confused

#

it says the file was last updated 2 minutes ago but i open the file and its an ancient log

hollow viper
#

delete it and launch the game?

drifting night
#

wait

#

i might be stupid

#

i think it just always says that

#

:cluer

#

wtf im so lost

#

i deleted it and tried again

#

i think it is "the log" but it just has like nearly nothing in it

#

none of the errors i saw are here

thorn abyss
#

I'm getting spamlogged with this :,]

frozen widget
#

@oak linden i have gotten back into coding

#

time to tell me how i can use that smart nav agent script

oak linden
oak linden
#

Do both of you not get the same issue on 0.9.21?

drifting night
oak linden
#

Can you send me your modpack code and Mod zip

drifting night
#

sure thing

oak linden
#

I can't test now but I'll try to soon

drifting night
#

019e55dc-5ad0-cb7f-7f21-a5667e28c64d

oak linden
#

Other than that, you can try telling me what happens that makes you think it doesn't work lol

drifting night
#

no idea in the slightest, i had no idea an issue was happening until someone using my mod asked me about it earlier today, as far as i can tell everything shatters including base game enemies

oak linden
drifting night
#

so something major is breaking that leads to nothing else working, even base game enemies are erroring

#

just about every custom function i have made for the moon doesnt run properly so maybe the netcode is breaking or something..?

#

im not the best with stuff like this myself

oak linden
#

@hollow viper run this and give me logs pls

hollow viper
# drifting night
[Debug  :dev.ladyalice.dungenplus] Main branch gen failed at Branch 0 (Length: 25, Ratio: 0,8064516)
Prev tile: B5-Hall1
Archetype: Block5Archetype
Tilesets: TartarusBlock5 (DunGen.TileSet)
Reason: DunGen.NoMatchingDoorwayPlacementResult
Available Doorways: Door 2, Door 2 (2)
Used Doorways: Door 2 (1)
#

please enable debug logs in testing profiles

#

this is getting spammed

drifting night
#

i have them enabled

hollow viper
#

from different tiles and archetypes

drifting night
#

the interior generates fine, thats odd

hollow viper
#

like at all

drifting night
#

weird

hollow viper
#

its failing with some lenght, yes, but it cant generate

#

nothing interesting

oak linden
# hollow viper nothing interesting

What about this part

:  HarmonyX] Error while running static void loaforcsSoundAPI.LethalCompany.Patches.RoundManagerPatch::Reporting(). Error: System.TypeLoadException: Failure has occurred while loading a type.
  at RoundManager.GenerateNewFloor () [0x002cb] in <aca1e98d6f844d3f85cd22b6f7be2f9b>:IL_02CB
hollow viper
#

let me check ig

oak linden
#

I have no idea tbh

hollow viper
#

as for you, @drifting night , your interior is either not getting culled outside or cull down entirely inside

#

on your moon

hollow viper
oak linden
#

Weird

#

Can u downgrade and check if any of these issues disappear

hollow viper
#

to waht vers

#

.21?

#

@drifting night is floor on your tiles networked by any chance

drifting night
oak linden
hollow viper
drifting night
#

when i tested it seemd to work on .20 i just picked a random older version

oak linden
#

That one should be fine, it's been out for 2 weeks or so

drifting night
#

idk whether or not that would make a difference

drifting night
hollow viper
#

i mean not like few objects

drifting night
#

or atleast the entry tile does

hollow viper
drifting night
#

it is?

hollow viper
#

yes

#

well for performance at least since tiles not gonna cull down as they should

#

idk how exactly you networked them so cant say more

drifting night
#

idk they just have this on them

hollow viper
#

did you just slap it next to tile component

drifting night
#

yup

hollow viper
#

like not even spawning

drifting night
#

dont remember why its there but its probably important

#

or maybe it isnt

oak linden
#

Base game never spawns any network objects on tiles iirc

#

That's why the spawnsyncedobject stuff exists

drifting night
#

they mightve just appeared and i forgot to remove them or something

#

no idea myself

#

should i remove them?

#

actually yea the script on the entry tile isnt even networkbehaviour its client side stuff so

#

idk why id have one on there

oak linden
drifting night
#

hm still super broken

#

gonna test on .20 again to see if its working

hollow viper
#

-# try artifice

drifting night
#

seems perfect as far as i can tell

drifting night
#

if so that might be why, its designed very specifically for certain values on one moon i made for the mod

hollow viper
#

tartarus, experimentation and artifice

#

artifice was always failing

#

tartarus and experimentation got culling issues but generated

drifting night
#

culling issues are interesting

#

i havent heard about that in a long time

#

maybe this tile is the reason again

#

i did notice it looked weird even in .20, this is the same for my other interior/moon combo too

#

through imperium noclip

#

i dont use cullfactory if that means anything

#

although even vanilla interiors look weird in imperium noclip now

#

its as if not everything is rendering, but thats a separate thing i dont think is relevant to this

hollow viper
drifting night
#

heres some errors i see on .22

#

i assume though these all are a result of something else breaking i havent determined yet

#

but yea i cant enter the interior, and none of my enemies can be spawned with imperium, they dont even appear in th elist

#

outside of the culling though interior appears to be perfect

#

it is spawning keys for whatever reason though

#

my moon/interior isnt supposed to use those

oak linden
oak linden
drifting night
#

ill try and send the log

oak linden
#

Ye just send log then

drifting night
drifting night
#

let alone ones that can be locked

#

but its so bugged that maybe that function is just freaking out and spawning them anyways

#

so ill ignore it for now

oak linden
#

Icic

carmine elk
carmine elk
#

I think it was only once for me personally but I’ve seen a few other people mention it. Iirc I think I had it set to disabled and somehow once it led to the whole thing being culled

frozen widget
#

@oak linden can i ask you some things about EnemyAI and stuff

carmine elk
#

Could be worth a jiggle just in case

frozen widget
#

so i may have an error

oak linden
#

uhuh

frozen widget
#

regarding Nutcracker AI

#

that makes NO SENSE whatsoever

oak linden
#

go on

frozen widget
#

even TKronix got no idea why

#

the Collision, somehow says it's missing something

#

when everything is set up the exact way it is for base nutcracker

#

AND

#

that snippet of code that makes the collision detection

#

has not been touched whatsoever

oak linden
#

can i see the error lol

frozen widget
#

so it's like some kind of ghost is in the machine

frozen widget
# oak linden can i see the error lol

[Info : Unity Log] GuerrierCustom(Clone): Collided with player!
[Error : Unity Log] NullReferenceException: Object reference not set to an instance of an object
Stack trace:
EnemyAICollisionDetect.OnTriggerStay (UnityEngine.Collider other) (at <aca1e98d6f844d3f85cd22b6f7be2f9b>:IL_0032)

#

this gets spammed when player collides with it

oak linden
#

okay show me the component from unity

frozen widget
oak linden
#

the EnemyAICollisionDetect component

frozen widget
#

hold on i think i found the issue

#

i am probably the worst possible person to ever be landed the power of coding

#

i had 2 colliders and forgot to give one of them reference to the main script because i forgor i had 2

thorn abyss
# oak linden Full log pls

Was not able to reproduce it (even when it happened twice today early)

If it happens again, I'll send it

oak linden
thorn abyss
oak linden
#

im hearing a lot of issues with that rn

#

unsure why but i'd lay off that until next CR update

#

i believe that's causing your issues

#

actually i might've just figured it out

#

testing nr

#

rn*

#

yeah okay it was dawnlib with oxyde lol, will update dawnlib soon

sacred tulip
#

Bad bad

calm maple
#

Maybe remove a few of the fatal logs you left in. That stuff scares users, ya dongus

oak linden
carmine elk
#

We should log everything as fatal because… well I don’t know. But we should log issues as debug because it has bug in the name

oak linden
#

true...

#

just pushed an update to address the issues lol

#

and yes, if you played today and saw your game generate an extra fire exit

#

that was me

#

and yes, it was really funny

oak linden
#

it was just a blocked fire exit

hollow viper
#

xu xu xu

sacred tulip
#

Shoe shoe shoe

carmine elk
spare fjord
#

WIth DawnLib 0.9.23 on Kanie moon I encountered:

  • when entering through Main -> player ends up entering through Fire;
  • when entering through Fire -> player ends up entering through Main;

Weird thing is that Kanie does not have a DawnLib dependecy at all.
This does not happen with DawnLib 0.9.22, 0.9.21.
Was tested on fresh profile with Kanie + DawnLib + Imperium.

oak linden
spare fjord
oak linden
unreal nacelle
jolly quail
#

I encountered a pretty nasty bug with the terminal

#
[Error  : Unity Log] An error occured while post processing terminal text: System.Collections.Generic.KeyNotFoundException: The given key 'Dawn.DawnMoonInfo' was not present in the dictionary.
  at System.Collections.Generic.Dictionary`2[TKey,TValue].get_Item (TKey key) [0x0001e] in <1071a2cb0cb3433aae80a793c277a048>:IL_001E
  at LunarConfig.Objects.Config.LunarConfigCustomMoonOrder.GetIndex (Dawn.DawnMoonInfo moonInfo) [0x00000] in ./Objects/LunarConfigCustomMoonOrder.cs:24
  at System.Linq.EnumerableSorter`2[TElement,TKey].ComputeKeys (TElement[] elements, System.Int32 count) [0x00010] in <ea489521390f48908a7ce45cb17a6848>:IL_0010
  at System.Linq.EnumerableSorter`1[TElement].ComputeMap (TElement[] elements, System.Int32 count) [0x00000] in <ea489521390f48908a7ce45cb17a6848>:IL_0000
  at System.Linq.EnumerableSorter`1[TElement].Sort (TElement[] elements, System.Int32 count) [0x00000] in <ea489521390f48908a7ce45cb17a6848>:IL_0000
  at System.Linq.OrderedEnumerable`1[TElement].SortedMap (System.Linq.Buffer`1[TElement] buffer) [0x00006] in <ea489521390f48908a7ce45cb17a6848>:IL_0006
  at System.Linq.OrderedEnumerable`1+<GetEnumerator>d__3[TElement].MoveNext () [0x0003d] in <ea489521390f48908a7ce45cb17a6848>:IL_003D
  at Dawn.FixedGroupSizeGroupingAlgorithm.Group (System.Collections.Generic.IEnumerable`1[T] input) [0x0008d] in ./src/API/Moons/IMoonGroupAlgorithm.cs:59
  at Dawn.MainGroupAlgorithm.Group (System.Collections.Generic.IEnumerable`1[T] input, System.Boolean reverse) [0x0008a] in ./src/API/Moons/IMoonGroupAlgorithm.cs:207
  at Dawn.MoonRegistrationHandler.DynamicMoonCatalogue (On.Terminal+orig_TextPostProcess orig, Terminal self, System.String modifieddisplaytext, TerminalNode node) [0x00075] in ./src/API/Moons/.MoonRegistrationHandler.cs:393
  at DMD<>?2023343454.Hook<Terminal::TextPostProcess>?238029012 (Terminal , System.String , TerminalNode ) [0x0001b] in <0dc2774ac9ce4d1db1620f6d70a71efe>:IL_001B
  at DMD<>?-478419032.Trampoline<Terminal::TextPostProcess>?492734626 (Terminal , System.String , TerminalNode ) [0x00031] in <cddac6f97e644bb38c72c2d7a5409a64>:IL_0031
  at Dawn.UnlockableRegistrationHandler.AddShipUpgradesToTerminal (On.Terminal+orig_TextPostProcess orig, Terminal self, System.String modifiedDisplayText, TerminalNode node) [0x00000] in ./src/API/Unlockables/.UnlockableItemRegistrationHandler.cs:130
  at DMD<>?1057266410.Hook<Terminal::TextPostProcess>?-481176688 (Terminal , System.String , TerminalNode ) [0x0001b] in <197fd76e044e400ca8b92e203ab11354>:IL_001B
  at DMD<>?-2030099692.Trampoline<Terminal::TextPostProcess>?-1164809812 (Terminal , System.String , TerminalNode ) [0x00031] in <78ba877cbd594e008a57609305d29a95>:IL_0031
  at Dawn.Internal.TerminalPatches.UpdateItemPrices (On.Terminal+orig_TextPostProcess orig, Terminal self, System.String modifieddisplaytext, TerminalNode node) [0x0000f] in ./src/Internal/Patches/TerminalPatches.cs:138
  at DMD<>?-1147765630.Hook<Terminal::TextPostProcess>?478929712 (Terminal , System.String , TerminalNode ) [0x0001b] in <896ad820f8174e09b2a4412248a282b4>:IL_001B
  at DMD<>?1490508432.Trampoline<Terminal::TextPostProcess>?-359730198 (Terminal , System.String , TerminalNode ) [0x00031] in <c37e9a298022440880ff569b12e6322d>:IL_0031
  at Dawn.Internal.TerminalPatches.HandleTerminalTextModifiers (On.Terminal+orig_TextPostProcess orig, Terminal self, System.String modifieddisplaytext, TerminalNode node) [0x00000] in ./src/Internal/Patches/TerminalPatches.cs:125
  at DMD<>?-1950961622.Hook<Terminal::TextPostProcess>?-775502524 (Terminal , System.String , TerminalNode ) [0x0001b] in <b62abdf25d5d46adb7e226e78084ca0f>:IL_001B
  at DMD<Terminal::LoadNewNode>?-87647176.LoadNewNode (Terminal this, TerminalNode node) [0x00098] in <cafb19973dd249ecb79d75ed576858cf>:IL_0098```
#

Leads to this happening

#

It occurs when LunarConfig is active.

oak linden
#

Not my issue but I'd have checked it out if I was on the pc

#

Someone ping me in 5 to 6 hours

lunar mantle
#

EPIC RAP BATTLES OF HISTORY

#

LUNARCONFIG

#

VERSUS

#

DAWNLIB

oak linden
#

Lunarconifg

#

Nice

jolly quail
#

Ah it's the catalog index feature

oak linden
#

Bongos first PR to something dawnlib related in 7 months and it already broke, this is funny

#

But uh yeah, good night, ping me later and I'll remember

jolly quail
#

Ok I will ping you at 10 PM

upbeat charm
upbeat charm
#

DawnLib's new update has been being goofy with my modpack since yesterday

jolly quail
#

@oak linden

calm maple
#

woaw, its almost exactly between 5 and 6 hours later

#

Terraformer9x the stopwatch

white finch
calm maple
#

I'm never going back to 2pm

#

u can't make me

hollow viper
runic hedge
#

yo, is there currently a way to add the bestiary video to an enemy through unity dawnlib project?

upbeat charm
#

🫩

#

DawnLib is messing w/so much rn

jolly quail
upbeat charm
#

I'll check back soon

upbeat charm
#

Had a 10.5h work day, might be missing it due to exhaustion lol

#

FOUND IT.

#

Testing now

#

YES.

#

Thank you! @jolly quail

noble zephyr
#

anyone know if dawnlib is causing moons to not appear in the terminal sometimes? Using it with wesleys moons and a bunch of moons disappeared

#

already posted about it in #1241786100201160784 if you want more details

vernal umbra
#

i just cleared all the moon entries out of it and they started appearing again

noble zephyr
vernal umbra
#

i didnt make a copy because it coincided with switching to controlling everything with lunarconfig so i didnt need it anymore

noble zephyr
vernal umbra
#

yeah

noble zephyr
# vernal umbra yeah

this didnt fix it for me, i deleted the config and the moons still dont show in the terminal. this is me loading a pre-existing save, so i have no idea if it would fix it for a new save. but this issue only occurred many quotas in to begin with

vernal umbra
#

do you have anything that might change the terminal

#

like terminal formatter or darmuhs terminal stuff

noble zephyr
#

019e667a-f398-eae8-4608-c027557288db this is my code. i dont have any terminal mod besides "TerminalConflictFIx" and "Interactive Terminal API"

vernal umbra
#

i dont see anything out of the ordinary here that would cause your issue

#

maybe selectable interiors? since notezy has been gone for a while

noble zephyr
#

idk if the problem is baked into the save at this point and I'd need to make a new save to test but it happened very randomly after 5-6 quotas so i have no idea how I'd test it outside of this save

#

plus i really want to continue this save since we got so many moons

oak linden
oak linden
oak linden
noble zephyr
#

i dont have many mods that change the terminal at all so its been hard to figure out the cause

oak linden
#

Nope, no idea

vernal umbra
#

hey so i forgot, was this error being caused by an interaction between dawnlib and lethallib or something else?

#

cus it is breaking a few other mods now like neatmenu and i'd like to get to the bottom of it

runic hedge
#

could someone possible explain a bit more how to interact with the config generated by the dusk definition? I have added all of my setting names with their fields and have tried a few things to get the config values for my enemy. i seen from previous messages inthe chat that you can get the values from the asset bundle loader? how do you do this specifically? should i simply use the EnemyHandler.Instance.name.GetConfig<bool>("setting name").value in my AI script and that will fetch the values from the definition?
alternatively i can use ConfigReader script to read a config bepinex configuration script? how would my content handler know to generate the config in this case?
correct me if im misunderstanding it

oak linden
#

its not the content handler generating it, it's your duskcontentdefinition

#

you're just grabbing it from there

runic hedge
# oak linden you're just grabbing it from there

ok so its basically just make the config entries in the definition, and then use that reference in the code? what is each part of the string referencing? the line u gave as an example was EnemyHandler.Instance.DuckSong!.GetConfig<bool>("Setting name").value. is EnemyHandler a method used by the game or is it an example placeholder your enemy name instance (e.g. reikoAI)?

oak linden
#

the example was using the contenthandlers from dawnlib

runic hedge
runic hedge
# oak linden the example was using the contenthandlers from dawnlib

so basically the steps would be to reference the dusk enemy definition in the enemy scripts and then to pull the config values from it? what is the syntax to reference the config fields created in the unity inspector generated from the dusk definition to use in my script? I havent made an enemy handler as i thought the unity scripts did this? would i simply need to create a method to get the dusk defintion in my script and then use that in the getconfig string? is there any scripts you could point me to?

hollow viper
#

(well as example its for interior and item but will be pretty same for enemy)

#

and to pull config entry/value you will do smth like this:
HabitatContentHandler.Instance.habitatAssets.GetConfig<bool>("Enable forcefields").Value)

runic hedge
runic hedge
runic hedge
# hollow viper yep

is that specifically so it's easier to reference the definition specifically for the config?

hollow viper
runic hedge
#

ive obvs missed something but not sure what yet

hollow viper
#

for items/enemies i dont remember but i think they are in the same assetbundle as item/enemy

runic hedge
hollow viper
#

show your code then

#

content handler and how you call config value

#

and screenshot config entry in unity

runic hedge
# hollow viper content handler and how you call config value

using BepInEx.Configuration;
using Dusk;
using System;
using System.Collections.Generic;
using System.Runtime.CompilerServices;
using System.Text;

namespace Jinn
{
        class JinnContentHandler : ContentHandler<JinnContentHandler>
        {
            internal JinnAssets? jinnAssets;
            internal GramophoneAssets? gramophoneAssets;
            internal RapierAssets? rapierAssets;


            public class JinnAssets(DuskMod mod, string filePath) : AssetBundleLoader<JinnAssets>(mod, filePath) { }
            public class GramophoneAssets(DuskMod mod, string filePath) : AssetBundleLoader<GramophoneAssets>(mod, filePath) { }
            public class RapierAssets(DuskMod mod, string filePath) : AssetBundleLoader<RapierAssets>(mod, filePath) { }


            public JinnContentHandler(DuskMod mod) : base(mod)
            {
                RegisterContent("jinn", out jinnAssets);
                RegisterContent("gramophone", out gramophoneAssets);
                RegisterContent("rapier", out rapierAssets);
            }
        }
}

//i declare variables top of AI script:
public int baseSpeed;
public int attackCooldownSlow;
public float minDistance;
public float maxDistance;
public bool canTeleport;
public float teleportWarningDelay;
public float maxDistanceAfterWarning;
public float minDistanceAfterWarning;
public bool canBeBurned; 
public bool burnLights;
public int flashlightDrainPercentage;
public int burnSlowdown;
public int attackDamage;

//then i assign values in start method:
public override void Start()
{
    base.Start();
    updatePositionThreshold = 15f;
    baseSpeed = JinnContentHandler.Instance.jinnAssets.GetConfig<int>("ConfigJinnBaseSpeed").Value;
    attackCooldownSlow = JinnContentHandler.Instance.jinnAssets.GetConfig<int>("ConfigJinnAttackCooldownSlow").Value;
    minDistance = JinnContentHandler.Instance.jinnAssets.GetConfig<float>("ConfigJinnMinVisibleDist").Value;
    maxDistance = JinnContentHandler.Instance.jinnAssets.GetConfig<float>("ConfigJinnMaxVisibleDist").Value;
    canTeleport = JinnContentHandler.Instance.jinnAssets.GetConfig<bool>("ConfigJinnCanTeleport").Value;
    teleportWarningDelay = JinnContentHandler.Instance.jinnAssets.GetConfig<float>("ConfigJinnTPWarnDelay").Value;
    maxDistanceAfterWarning = JinnContentHandler.Instance.jinnAssets.GetConfig<float>("ConfigJinnMaxDistAfterDelay").Value;
    minDistanceAfterWarning = JinnContentHandler.Instance.jinnAssets.GetConfig<float>("ConfigJinnMinnDistAfterDelay").Value;
    canBeBurned = JinnContentHandler.Instance.jinnAssets.GetConfig<bool>("ConfigJinnCanBeBurned").Value;
    burnLights = JinnContentHandler.Instance.jinnAssets.GetConfig<bool>("ConfigJinnBurnLights").Value;
    flashlightDrainPercentage = JinnContentHandler.Instance.jinnAssets.GetConfig<int>("ConfigJinnFlashlightConsumption").Value;
    burnSlowdown = JinnContentHandler.Instance.jinnAssets.GetConfig<int>("ConfigJinnBurnSlowdown").Value;
    attackDamage = JinnContentHandler.Instance.jinnAssets.GetConfig<int>("ConfigJinnAttackDamage").Value;

//then in the AI methods i just call the variable e.g. agent.speed=baseSpeed;

hollow viper
runic hedge
#

yh tbh i thought it would condense it automatically

hollow viper
#

`

#

not "

#

what about unity

runic hedge
#

yeah was going to but then i realised i recently got an american keyboard

#

so had to figure out where the ` was

#

lol

hollow viper
#

is enemy spawnable in game?

runic hedge
#

yeah it's registered fine. basically working flawlessly until i tried to implement config support

#

im still learning dawnlib

runic hedge
#
using BepInEx.Logging;
using Dawn;
using HarmonyLib;
using System.IO;
using System.Reflection;
using UnityEngine;

namespace Jinn
{
    [BepInPlugin(modGUID, modName, modVersion)]
    [BepInDependency(DawnLib.PLUGIN_GUID)]
    public class Plugin : BaseUnityPlugin
    {
        public const string modGUID = "reiko888.Jinn";
        public const string modName = "Jinn";
        public const string modVersion = "1.0.0";

        public static Plugin Instance = null!;
        internal static new ManualLogSource Logger = null!;
        internal static readonly Harmony harmony = new Harmony(modGUID);

        private void Awake()
        {
            if (Instance == null)
                Instance = this;
            Logger = base.Logger;
            harmony.PatchAll(Assembly.GetExecutingAssembly());
            Logger.LogInfo($"Plugin {modName} is loaded!");
        }
    }
}
hollow viper
#

ok so

#

you need to register your mod thru code

#

not thru dawnlib

#

and remove .extension from content container asset bundle

runic hedge
#

yeah i seen this and tried to copy its logic, but it said that the bundle had already been loaded

runic hedge
hollow viper
#

no code is you giving your assetbundle with content container an extension

#

check dawnlib wiki for more info

runic hedge
#

yeah im aware the duskmod extension registers it for you, so i went with no code

#

does going no code have the downside of not being able to do things that i want with the config for example?

#

so the best thing to do would be to just register through code instead of dusk mod extension?

#

@hollow viper

#

if im understanding correctly

hollow viper
runic hedge
#

ahhhhhhhh

hollow viper
#

i mean for you it will basically few lines atp

runic hedge
#

yeah no biggie

#

tyvm for your help tho

#

ill register it via code, will also help me when it comes to registering terminal node too so that solves both problems i needed to s olve

oak linden
#

i apologise for being unavailable to help with that, im currently recovering from private issues so I was away for yesterday and maybe longer

#

im glad fumo was able tohelp you

runic hedge
quiet tree
#

I don't understand how DawnLib wants I to load my assets

#

Sometimes it asks for the assetbundles to be in /Assets/

#

sometimes not

oak linden
#

its ont a sometimes thing, its always

quiet tree
#

the what

#

i don't have anything with .duskmod

#

In fact I only use dawnlib loading so I can load achievements

#

Since I can't load the assets manually into DawnLib

oak linden
#

if you're loading through the editor, you have to be using a .duskmod unless you've setup your own content handlers

quiet tree
#

through the editor ?

#

No i'm not, i'm loading programmatically

oak linden
#

can i see your code?

quiet tree
#

Yes

#
    void Awake()
    {
        NetcodePatch();
        
        var backroomsModExists = BepInEx.Bootstrap.Chainloader.PluginInfos.ContainsKey("Neekhaulas.Backrooms");
        Instance = this;
        logger = Logger;
        logger.LogInfo("""/// B##CKR##MS R#N#W#D \\\""");
        if (backroomsModExists)
        {
            logger.LogError(""">>> IMP#SSIBL# T# L##D <<BACKROOMS RENEWED>>: The other backroom mod is already here !""");
            return;
        }
        harmony.PatchAll();
        logger.LogInfo(""">>> [x] P#TCH#S #PPL##D""");
        // Load configs earlier to avoid race condition
        Configs = new LocalConfig(Config);
        logger.LogInfo(""">>> [x] C#NF#G L##D#D""");

        // I understood the lesson, Thunderstore, no more embedded assets !
        assetBundle = AssetBundle.LoadFromFile(Path.Combine(PluginDir, "backroomsrenewed_assets"));
        var tocAssetBundle = AssetBundle.LoadFromFile(Path.Combine(PluginDir, "backroomsrenewed_toc"));
        RegisterPrefabs();
        mod = DuskMod.RegisterMod(this, tocAssetBundle);
        logger.LogInfo(""">>> [x] #SS#T B#NDL# L##D#D; #SS#TS L##D#D""");
        RegisterAchievements();
        logger.LogInfo("""\\\ /!\ #RR#R: #NT#GR#T# CH#CK F##L#R# -- PR#C##D C#R#F#LL# /!\ ///""");
        logger.LogInfo(""">>> Entering the b--#c__ro#^m:s~""");
    }

    void RegisterAchievements()
    {
        achievements = new AchievementAssets(mod, "backroomsrenewed_achievements");
        mod.RegisterContentHandlers();
    }
oak linden
#

ah so you are using contenthandlers

quiet tree
#

I think so

#

I need to repatch my project

#

Somehow my deps have broken since idk when

oak linden
#

f

#

also you dont need this

quiet tree
#

It wasn't doing that before

quiet tree
#

obsolete

#

need to remove it

oak linden
# quiet tree It wasn't doing that before

it'll spit out those errors if you check validate references on some of the dlls, its on by default but if you turn it off and delete the dlls then re-add them, then it'll turn itself back on

quiet tree
#

o

oak linden
#

the wiki should have more proper info about this

#

just make sure you're replacing your dlls without deleting the .meta files

quiet tree
#

Aaaah

#

Yeah I'll keep the .meta in the gitignore then

#

well remove the .meta from gitignore

#

Not the right channel but any clue about this one ?

#

Alright

#

So now that my main issues are fixed, back to the real problem

#

Achievements won't load or something because "path" is missing or something ?

quiet tree
#

Ah sike

#

now Netcode Patcher is yapping

oak linden
oak linden
quiet tree
#

I'll try to show you

#

if netcode patcher accepts to fucking work

frozen widget
#

@oak linden how do i use the smart agent in an enemy AI?

#

since i saw there is something about it letting monster navigate between in and out

quiet tree
#

Also

#

Fyi creating a config entry on Achievments in Unity made crash my editor

#

maybe it's unrelated ?

#

@oak linden there

quiet tree
#

no achievements for the backrooms ;-;

oak linden
quiet tree
oak linden
# quiet tree

yah you dont have a manifest, icon etc in your profile folder

#

at the end of the day, this warning is harmless in a testing environment

#

but i'd be very concerned if this popped up in like, a TS download

quiet tree
#

I won't bundle my mod with Dawn

#

I have my manifest and all on the side

#

I just haven't bothered copying them in unity yet

#

Why do the achievements not appear on main menu though ?

oak linden
#

im confused what you're asking, but your screenshot you sent showed no manifest etc

quiet tree
#

but it's here it exists

#

I just don't understand why I'm forced to use the content thing and load the achievements with that

#

oh is it so the mod has an icon in the Achievements page and all

oak linden
quiet tree
#

So if there's any missing info, the achievements won't show ?

oak linden
#

i need to see your unity setup

#

i.e. your dusk achievement definitions

quiet tree
spiral axle
#

Hey, a quick question - Dawn's Simulate command handles weights as floats, and from my quick testing it doesn't appear to use the decimal point. Is there a case that it would be using that? (probably division in weights, but i couldn't replicate that)

oak linden
spiral axle
#

oh, alright

#

is it rounded normally or always down?

oak linden
#

not sure, ill check

oak linden
spiral axle
#

alrighty, thanks! 😇

oak linden
# quiet tree

i just realised, you dont have the editor tool lol

#

that's probably why its not working

quiet tree
#

what

upbeat charm
#

Yo Xu

oak linden
#

hi

oak linden
upbeat charm
#

First thanks for all your work animeheart Do you have a sec to check a possible mod idea out?

oak linden
#

the com.github.teamxiaolan.dawnlib.editor.dll

oak linden
oak linden
# quiet tree

and then your screenshots here should look different

oak linden
# frozen widget <@514120543046336516> how do i use the smart agent in an enemy AI?

also i just remembered you sent this last night
you need to reference the script SmartAgentNavigator
then you need to, on your enemy's Start, do SmartAgentNavigator.SetAllValues(isOutside); or something similar
and from there you can just call SmartAgentNavigator.DoPathingToDestination(Destination); or SmartAgentNavigator.StartSearchRoutine(Radius);

oak linden
#

a common issue with using more suits is that the suits just put themselves all in the rack and it looks ugly
how would people want it to look like? ignoring model limitations, UI etc, how would you want the suit rack redesigned/UI done for, to make choosing a suit a better experience that doesn't limit you to a specific number of suits?

jolly quail
#

You could allow players to use the coat rack method for those who prefer it more vanilla

#

But I think UI is better if it goes beyond the limit

oak linden
#

do you have any ideas on how you'd like the UI to look like? I could have stuff modelled, UI created etc for something that looks "as vanilla as I could possible do"

quiet tree
#

Like when you do monitor view on the screen but with skins

oak linden
#

hmm yeah I don't think a suits terminal would be the most vanilla thing either honestly, still open to the idea though, even if it sounds slightly difficult, should be doable

quiet tree
#

It feels less unvanilla-ish than a new UI

#

Using the terminal for that makes it feel integrated imo

#

It feels like it's a fancy way to equip and preview suits

#

With interactive terminal of course, selection with arrows and enter for example, like those other interactive terminal mods

#

Oh I almost want to do it myself now

#

Shit

#

Too many mod projects

#

I must focus

oak linden
#

lol

#

fair enough honestly

jolly quail
#

It could just look like the store list

oak linden
#

would people really want it in the terminal? i feel like i personally dislike using the terminal honestly

#

am i a lone terminal disliker

jolly quail
#

Oh do you mean a ui when using the coat rack?

quiet tree
#

Especially when it's well done and you don't need to type commands

#

And instead you can navigate with arrows, and you have a live preview behind the text

#

Fancy shyt

oak linden
quiet tree
#

And you definitely can't increase the rack length lol

oak linden
#

Yah

quiet tree
#

Yep well

#

Either a button that cycles the suits

#

Or the terminal sound like good options to me

#

And fancy terminal to be ergonomical

oak linden
#

Hmm well in both scenarios we already have mods that do both, so for now it's not necessary I do anything ig
But if anyone comes up with any other ideas I'd be down to hear em out

#

Lol I'm not making new models as part of dawnlib if that's what you mean

quiet tree
#

Lol

#

No I meant just a fancy terminal page

#

As I detailed

oak linden
#

okay i thought you might've meant that, wasn't 100% sure

carmine elk
#

Stack racks. Put racks on top of racks! (There is no ceiling. You’re imagining it)

oak linden
#

true...

charred field
#

it looks like ass tho I typically just disable the mod

#

I don't ever have it where having too many suits is an issue cuz with a config in moresuits i think you can fit like 30+ on there...

charred field
charred field
quiet tree
charred field
#

ooh I get what you mean yeah lol

oak linden
charred field
#

Yeah but it looks like ass cuz it's a disembodied UI

#

lole

#

and you don't wanna model

oak linden
#

I didn't say I didn't want to model

#

And even if I didn't
A better UI could still be made

#

I asked for suggestions, if you think it's not worth making then I'm not really interested in hearing why it's not, I'm aware of too many suits and suits terminal existing

drowsy pendant
#

Honestly, I'd be fine with the TooManySuits' solution if the UI wasn't always just floating there (if I'm remembering correctly). Would rather it only be when near the suit rack or directly looking at the suits

#

Feels weird for the UI to be just constantly floating above the suit rack with zero rhyme or reason

oak linden
#

It is just like, out there, and it's pretty ugly in the middle of the ship

drowsy pendant
#

Mhm. If it was only when you're actively near the rack and looking at suits, that'd help a lot

sacred tulip
#

add more racks!! idk if this was already suggested lol

drowsy pendant
#

you severely underestimate how many suits people have, you'd have like, dozens of racks that won't fit in the ship

sacred tulip
#

true hehe

#

but like, imagine you can config which ones appear in each rack, and so you can have only the ones you want in that moment idk

charred field
#

not that I don't think suggestions should be made

sacred tulip
#

terminal is the best option for both immersion and dealing with huge amounts

drowsy pendant
#

Eh, suitsTerminal doesn't feel immersive, though, it feels like a completely different terminal UI than the base game

sacred tulip
#

well, a new ui that fits it better!

#

not the best at this tho, im not one to play with that many suits hehe

charred field
#

that's jhust made to acomodate suit hoarders

drowsy pendant
#

I mean fair. I just personally don't think that's great. Honestly I wonder if you could just make a mod that removes the suit rack since there's so many suit mods and just adds a button similar to MoreCompany's cosmetics window where you can just... change the suit there

sacred tulip
#

that could work too

drowsy pendant
#

suit rack is fine for vanilla but when there's a ton of modded suits I wonder if just, decoupling it from the ship entirely is the best bet

charred field
#

yeah that'd work

sacred tulip
#

nikki cooking!!!

charred field
#

Just not sure if that works for this specific scenario

drowsy pendant
#

yeah fair

charred field
#

but im not xu so :P

charred field
drowsy pendant
#

it'd be the mod I would personally want but again, might not be best for an API feature. But honestly I don't know how many of these are? I think most suggestions that will make it still feel like an API would fall under "DawnLib adds an API for handling suits, then a mod can be made to interact with said suits"

charred field
#

idk if you got the wrong idea from my message but I was not dissing at all w anything that I said :P

drowsy pendant
#

-# and if there's a SuitsMenu mod I'll add NeatMenu compat :3

#

But a separate SuitsMenu mod would be my solution as opposed to trying to keep it in the ship tbh

oak linden
#

above that, i said im okay with modelling

sacred tulip
#

modellib

oak linden
drowsy pendant
#

at least most modded players

#

obviously vanilla do

calm maple
#

I can't remember the last time anyone I played with bought a suit

sacred tulip
#

me!!!!

calm maple
#

I don't play with u

sacred tulip
#

well and i dont play with u!!! >:(

drowsy pendant
#

-# literally what I was about to say, not trying to be mean, just funny lol

#

tbf even if I did buy suits I prefer mods that perma unlock them as opposed to every playthrough

#

it feels like a playthrough tax that I could just spend on going to a different moon to actually affect gameplay

#

instead of "I can be urple now"

calm maple
#

don't underestimate the power of being ourple

oak linden
#

everybody i play with buys suits 😔, i just dont play with hyper modded lobbies lol

drowsy pendant
#

I feel like the moment CodeRebirth gets involved things feel heavily modded, but that's just me. Idk what you actually play though

calm maple
#

But yea, that's a different problem. Nobody I've played with wants to spend money on anything but going to moons. Instead of flashlights they just wanna put their gamma up, nobody uses walkies, nobody wants to buy furniture like showers or pumpkins or suits cuz its a waste of money

drowsy pendant
#

Also I love being purple, don't get me wrong, but like... if I have the option to not spend an extra 150 credits for it, I'm gonna take it

sacred tulip
#

she has never played with code rebirth before

sacred tulip
#

lol

drowsy pendant
#

Furniture I actually do buy because it affects the luck stat or whatever it is

oak linden
#

i.e. rn playing with 36 mods

drowsy pendant
#

I mean fair but also furniture nice

#

and tbf I have "KeepFurnitureUnlocks" or whatever it's called

#

so that makes it more satisfying

calm maple
#

I wamt furmiture

drowsy pendant
#

especially with 2 story ship, bottom floor feels like the ship operating room and top floor is just furniture and hangout

charred field