#LethalLib

1 messages · Page 3 of 1

lofty nymph
#

that doesn't make sense Thonk

#

why would they create another instance

#

i need to have a look at the ngo source

humble pasture
#

wait let me check the repo

lofty nymph
#

afaik the reference in the network manager is the exact same as the original prefab

#

otherwise i would have had other issues in the past

solar blaze
#

wonder why it's behaving like it's deep for me

#

so far my experience aligns with what xilo is saying

lofty nymph
#

if that's true that seems like really weird behaviour

#

i don't see the reason they would need to implement it that way

#

unless it is purely to protect the prefab

solar blaze
lofty nymph
# solar blaze

looking at this it just adds the original prefab to the list Thonk

humble pasture
#

yeah

#

I was talking out of my ass earlier xd

lofty nymph
#

so where is this behaviour coming from then

#

curious

humble pasture
#

very

lofty nymph
solar blaze
#

yeah

lofty nymph
#

@humble pasture I wonder if it just saves a list of components that were on the object or something

#

i am not sure what else could be happening

#

no w ait

#

nvm it did get added

#

lmao

#

okay yeah modifying after registering does seem to work fine for me @solar blaze

solar blaze
#

huh

#

alrighty

lofty nymph
#

can i see your code?

#

i just did

testPrefab = LethalLib.Modules.NetworkPrefabs.CreateNetworkPrefab("test");
testPrefab.AddComponent<TestBehaviour>();
solar blaze
#

this is what I tried and what it currently is

lofty nymph
#

lol

solar blaze
#

oh yeah hahaha

#

I guess the only difference is is my prefab is local

lofty nymph
#

speaking of, i don't need to do that

solar blaze
#

but why would that matter

lofty nymph
#

it should not

#

if you look for your prefab in HideAndDontSave, is the component missing there too?

solar blaze
#

oh I have two, one with the component and one without. I guess there's just something I must have overlooked in my repo then sorry lol

lofty nymph
solar blaze
#

yeah I didn't think it would still be loaded if I removed it from there but I hardly recognize my repo anymore so I guess that's it

timid brook
#

Ahh I see what you mean now. Unfortunately that doesn't seem to be fixing the issue, it still tries to use the base method :/

lofty nymph
#

you are referencing the latest version of lethallib right?

timid brook
#

Yeah I'm referencing 0.13.2

lofty nymph
#

that is very odd

#

hmm..

#

@fresh folio you did not have issues with this?

#

maybe i shouldn't have made the dictionaries nullable

candid willow
#

just tested, them being nullable in the signature actually shouldnt've made a difference

#

what i said goes only for primitives

#

so yeah this is a really weird issue

candid willow
#

i can't reproduce it either

lofty nymph
#

so odd

#

the only thing i can think of is that it is somehow referencing an old lethallib version

fresh folio
lofty nymph
#

yeah i have no clue

candid willow
#

oh it might be

#

isnt it supposed to be +2 overloads

fresh folio
#

You dont need to use both though

candid willow
#

as in, the ide should tell you there's

#

2 other overloads

fresh folio
#

but yeah

#

it should

candid willow
#

it's gotta be an older ver then

#

surely

lofty nymph
#

my thought is that maybe they are referencing a dll file directly somewhere

#

and it is using that rather than nuget

#

(if they are even using nuget)

#

thats the only thing i can think of

timid brook
#

I'm referencing straight out of my dev TS profile which has the latest version installed. But yeah it seems to not be using latest despite latest being what's referenced

#

Cause it's only saying there's 1 overload

#

Okay switched to nuget and it works 👍

#

nuget = poggers

devout creek
#

I should switch to nuget at some point don't know how to start doing that only reference DLL in current script package

timid brook
#

It's stupid easy

#

just copy that and paste into your csproj

devout creek
#

Ah thanks

timid brook
#

Is this just a certain thing I need to toggle in the NetworkObject script or will I need NetcodePatcher for this? The scrap item is basically locking people's inventories because only the host is allowed to drop it

Stack trace:
UnityEngine.Debug:LogException(Exception)
Unity.Netcode.NetworkObject:OnTransformParentChanged()
UnityEngine.Transform:SetParent(Transform, Transform, Boolean)
GameNetcodeStuff.PlayerControllerB:SetObjectAsNoLongerHeld(Boolean, Boolean, Vector3, GrabbableObject, Int32)
GameNetcodeStuff.PlayerControllerB:DiscardHeldObject(Boolean, NetworkObject, Vector3, Boolean)
GameNetcodeStuff.<waitToEndOfFrameToDiscard>d__355:MoveNext()
UnityEngine.SetupCoroutine:InvokeMoveNext(IEnumerator, IntPtr)

[Error  : Unity Log] NullReferenceException: Object reference not set to an instance of an object
Stack trace:
GameNetcodeStuff.PlayerControllerB.SetObjectAsNoLongerHeld (System.Boolean droppedInElevator, System.Boolean droppedInShipRoom, UnityEngine.Vector3 targetFloorPosition, GrabbableObject dropObject, System.Int32 floorYRot) (at <af9b1eec498a45aebd42601d6ab85015>:IL_00D5)
GameNetcodeStuff.PlayerControllerB.DiscardHeldObject (System.Boolean placeObject, Unity.Netcode.NetworkObject parentObjectTo, UnityEngine.Vector3 placePosition, System.Boolean matchRotationOfParent) (at <af9b1eec498a45aebd42601d6ab85015>:IL_023C)
GameNetcodeStuff.PlayerControllerB+<waitToEndOfFrameToDiscard>d__355.MoveNext () (at <af9b1eec498a45aebd42601d6ab85015>:IL_0039)
UnityEngine.SetupCoroutine.InvokeMoveNext (System.Collections.IEnumerator enumerator, System.IntPtr returnValueAddress) (at <e27997765c1848b09d8073e5d642717a>:IL_0026)```
solar blaze
#

Set the auto parent bool to false

solar blaze
timid brook
#

Okay I had a feeling it was the auto parent thing being true, just didn't have time today for a test with it false. Thank you!

rain saddle
#

Does anybody know how to fix this exception?

timid brook
# rain saddle Does anybody know how to fix this exception?

idk much about this stuff yet, but just off the order of events in your logs it looks like you may be despawning a network object prior to letting a related RPC event to happen. (i'm guessing) you'd want to reorder it so the RPC fires before the despawn

#

(again im new to unity and rpc stuff, could be something totally different)

lofty nymph
#

alternatively they instantiated the prefab but didn't spawn it

rain saddle
#

This is the method that is causing the exception when I hit the enemy

public override void HitEnemy(int force = 1, PlayerControllerB playerWhoHit = null, bool playHitSFX = false)
        {
            base.HitEnemy(force, playerWhoHit, playHitSFX);

            if (!isEnemyDead)
            {
                creatureSFX.PlayOneShot(hitDemogorgonSFX, 1f);
                WalkieTalkie.TransmitOneShotAudio(creatureSFX, hitDemogorgonSFX);
                enemyHP -= force;
                if (IsOwner)
                {
                    if (enemyHP <= 0)
                    {
                        KillEnemyOnOwnerClient();
                        return;
                    }
                }
            }
        }
solar blaze
#

If you did register the network prefab and spawn it and this is occuring and only on death it looks like maybe move the TransmitOneShotAudio to only fire if the enemy isn't killed that hit.

solar blaze
# rain saddle This is the method that is causing the exception when I hit the enemy ``` publi...

Seems like what's happening in KillEnemyOnOwnerClient is more important than what's happening here too. But yeah my best guess is you're creating a race condition that despawn will win. You could even call killenemyonowner in an ienumerator after 0.5 seconds and see if it persists to troubleshoot. I assume you'll want to keep the enemy model in a disabled state and a death animation like the base game so you could probably even disregard this if you plan on not despawning it.

rain saddle
solar blaze
rain saddle
#

Oh okay thank you

undone brook
#

the network prefabs all sit under a disabled object in the hide and don't save scene, my network prefab only starts working if I activate said object

#

is this the intended behaviour?

humble pasture
#

you're supposed to spawn it to activate it

undone brook
#

thanks

quaint garnet
#

hi, is there any documentation or like examples of using UnlockableItems? I just wanna add a couple of things to my mod and I can't figure out how to load the asset from a bundle and register it for the shop

solar blaze
quaint garnet
solar blaze
quaint garnet
#

ohhh, that's convenient, thank you so much!

quaint garnet
#

well, I'm not sure what I'm doing wrong but I keep getting this error: "[Error : Unity Log] NullReferenceException: Object reference not set to an instance of an object" I feel like I've tried everything to fix it but I guess I'm just not seeing the problem

wintry dew
#

Is it possible to set up a paid moons with LevelTypes?

lofty nymph
wintry dew
lofty nymph
#

yeah you'd have to manually assign the levels

#

not something i had considered before

wintry dew
lofty nymph
# wintry dew sorry to bother you, but could you tell me the average rarity of the enemy? It's...
wintry dew
#

oh there was this thx 👍

tough path
#

How does LethalLib add enemies to levels? Enum or SelectableLevel ref

lofty nymph
#

but it uses the enum name to find the correct one

#

enum name matches the level asset name

tough path
#

I can prob do a very small function in LLL to pass it over to you

#

Level asset name?? Omg it was YOU

lofty nymph
tough path
#

you are the person who have people thinking internal level names are [Name]Level 😛

tough path
#

And LLL’s name check is too lenient so it’s like confirmation biasing people 😭

lofty nymph
#
var name = level.name;
var levelEnum = (Levels.LevelTypes)Enum.Parse(typeof(Levels.LevelTypes), name)

yeah lol

#

this is how lethallib has done it since the start since it was an easy way to turn the asset names into flags

tough path
#

That’s fairrrr

lofty nymph
#

the only reason i chose the asset names is because of that

devout glacier
lofty nymph
devout glacier
#

the way ive had the moon dungeon chances explained to me that makes the most sense is picturing a lottery where one dungeon has 300 tickets and the other has 15, and then a ticket is picked at random

#

seems to be what a weighted list is

tough path
#

yee its how it works for enemies too

#

somewhat

tough path
devout glacier
#

whats the difference between X and 0 here? is it just cuz those enemies aren't included in the array at all?

tough path
#

i think these are right

barren hamlet
#

is "DiceItem" the correct path here?

solar blaze
#

pretty sure you'll need the file suffix as well

#

so in this case DiceItem.asset

#

I think you can load assets like that without using the absolute path though yeah

#

but if you ever wanna see the paths you can open the .manifest file that is generated alongside your assetbundle and it will list the absolute paths of all assets it contains

quaint garnet
#

it's regarding LethalLib btw that's why I figured I'd ask here ^

solar blaze
#

wonder if it's because you have a space in your path

quaint garnet
#

NetworkPrefabs.RegisterNetworkPrefab(WallFlags.unlockables[0].prefabObject); I at least found out this is where the error is, I just don't know why

solar blaze
#

Well you said WallFlags is null

quaint garnet
#

yeah

#

idk, I'm just shotgunning ideas at this point

solar blaze
#

yeah, if it's null the only point it could be null or not null is here

#

unless you're doing something crazy in between

quaint garnet
#

no

#

idk

#

I checked if it's null as soon as I create it

#

and it is

#

so

#

wait

#

now it's not? I just checked it again and it didn't make it through the if statement this time

#

idk what happened, but I'm still getting the error

solar blaze
#

can you send the snippet of your code quick

quaint garnet
#
UnlockablesList WallFlags = bundle.LoadAsset<UnlockablesList>("Assets/Pride Flags/PrideWallFlag.asset");
            
if (WallFlags == null)
{
   Logger.LogInfo("Wall Flags is null");
}
if (WallFlags.unlockables[0] == null)
{
   Logger.LogInfo("WallFlags [0] is null");
}
TerminalNode val = null;
val = bundle.LoadAsset<TerminalNode>("Assets/Pride Flags/WallFlagNode.asset");
NetworkPrefabs.RegisterNetworkPrefab(WallFlags.unlockables[0].prefabObject);
Utilities.FixMixerGroups(WallFlags.unlockables[0].prefabObject);
Unlockables.RegisterUnlockable(WallFlags.unlockables[0], StoreType.Decor, null, null, val, 0);```
#

if it's in that order

#

wall flags is null

#

but if I switch the if statements I get the error thrown first

#

which I guess makes sense if it's trying to pull nothing for an if statement

solar blaze
#

So neither of those are logging or just wallflags [0] is?

quaint garnet
#

the first one is logging

solar blaze
#

oh I see what you mean

quaint garnet
#

wallflags [0] throws an error, yeah

solar blaze
#

ok so I mean it can really only be that your asset bundle just doesn't contain the asset at that path right? You're sure you didn't forget to replace the old asset bundle with the new one when you regenerated it with this new asset?

humble pasture
#

see if you can load it as an Object

#

just to see if the type is the issue

quaint garnet
#

I reopened the manifest and copy+pasted again, but no differences

#

I can't register an object

solar blaze
#

yeah but did you drag the freshly generated asset bundle into your plugins folder though?

#

like we're positive you're not just using an old asset bundle

quaint garnet
#

yes, I did that a couple times to make sure

#

here is the unlockable btw

solar blaze
#

oh hahaha

#

that's an UnlockableItemDef not an UnlockablesList

#

That'll still work but you just have to make sure you're loading that type

quaint garnet
#

should I just use a list? I've tried the other types and they give me more issues

#

I just couldn't find the list in unity to make and I thought it was just under a different name since I didn't see Unlockable Item Def in VS

#

a list might be easier anyway

#

and I found it in unity

solar blaze
#

Pretty sure there's overloads to support both

#

Nice

quaint garnet
#

I knew it was something simple I was missing

lofty nymph
solar blaze
#

Yeah it always is

#

The most frustrating things are always the tiny slips

lofty nymph
#

i mean UnlockableItemDef is custom

solar blaze
#

Yeah that's what I thought

quaint garnet
#

well thank you, I'm sure I'll run into another issue before I finish this update lol

grizzled fractal
#

i have little to no unity experience but i will brute force making a scrap item. speaking of are there any tutorials on making a scrap item with lethallib

grizzled fractal
#

thanke

quaint garnet
#

ok, new issue, anyone know why it's just not appearing in the terminal?

tender umbra
#

getting some errors when trying to make an enemy with LethalLib, appears in-game but breaks the terminal, making it impossible to leave it

#

discord formatted that weird but theres 3 photos there

prime mulch
#

any resources on making a custom enemy?

rain saddle
fresh folio
#

:(

#

this being the best resource hurts

grizzled fractal
fresh folio
wintry dew
#

Do I need to AddNetworkPrefab when using RegisterEnemy?

#

oh i found RegisterNetworkPrefab

  • is worked as well
west mica
#

when implementing customweather, what exactly is it expecting as WeatherEffect?

brittle marsh
#

@fresh folio @timid brook Please stop shitting on other people's work. Especially you, Noop. You have been the only person on this server who has been disrespectful towards me, and you've only been disrespectful. And for what, that I, a person who is new to modding, dare to work on making modding resources for things that don't have any?

timid brook
#

Apologies, my comment was purely toilet humor (aha) and probably heavily misinterpreted as toxic. I haven't the slightest clue how to make an enemy, I'm very new myself. I look up to the people like you making cooler stuff than I could

brittle marsh
fresh folio
#

The modeling side is helpful though I think the donut tutorial actually sucks for anyone wanting to learn blender and id suggest an alternative is used

#

Idk what the python script is for when evasia has the premade unity project already but if it works it works I suppose

#

It’s also quite simple but to be fair making resources on making a more complex ai is hard because once you stray from chase in a straight line and hit enemy it becomes very case by case

#

Overall sorry for coming off as rude towards you, I’ll try to tone it back and also lmk if you want any other input (I’ll try to word it better than I have lol)

brittle marsh
# fresh folio Idk what the python script is for when evasia has the premade unity project alre...

the unity project doesn't come with the plugins, or an automated way to copy them over, right? So it does that + generates you a csproj.user file to automatically copy over your mod files to your testing plugins path. So it's a few things done with one script, which is a nicer experience than having to do that yourself. I should probably also make it use the csproj.user file for the game file references, but for now it doesn't do that.

fresh folio
#

the idea is you make the plug-in separately usually

#

And move it into unity after you build it

brittle marsh
fresh folio
#

But workflows vary

brittle marsh
fresh folio
#

What do you mean open unity to build the project guh

#

You have a csproj in a solution somewhere on your pc and then you build it cause mod done and then you add it to your unity project so you can add the component to the bundled asset

#

I think it’s just a differing workflow that you use

#

Cause most people just work in vs/rider first

brittle marsh
fresh folio
#

Evasia’s project template comes with stubbed versions of the game scripts

#

If that’s what you’re basically doing

brittle marsh
fresh folio
#

Oh ok you’re just moving the assemblies over lol

brittle marsh
#

yeah

solar blaze
west mica
#

oh okay. so i can make that the custom weather object

hollow sorrel
#

My fork of lethal lib seems to be having issues regarding Registering Network prefabs. I have already confirmed that the mod I am testing this with works with the thunderstore version of lethallib

#

Not sure if I'm supposed to clone the main branch or the dev branch either

hollow sorrel
prime mulch
#

hey, i have my item set up and working for the most part. im struggling with adding functionality to it. Currently its set up to damage the player when leftclicking . i need it to add/remove particle system, lights and maybe change the material of the asset. What would be the best way to go about it?

undone brook
prime mulch
#

is there an example of changing an asset through code. i have no idea how i would acces/ change it once i have build it

lofty nymph
#

unless i never pushed it

#

oh i accidentally pushed changes to main branch instead of dev branch at some point i guess lol

lofty nymph
hollow sorrel
#

In the main branch this is how network prefabs are registered

#

and NetworkManager is null when you try to register a prefab on your plugins awake method

#

the dev branch had the working version, so idk

#

it looks like theres some discrepancy between the main branch and the dll thunderstore is building(?)

lofty nymph
#

lemme check something

#

oh huh, okay i guess i never actually built this version locally

#

lmao

quaint garnet
#

anyone know what's causing wall decor to be placed so far off the wall?

#

I thought it might have been default but then I say lethal things had some nice wall decor and I was wondering if there was a solution

viral palm
#

Is anyone familiar with how to add unlockables to the terminal menu? I'm really struggling here 😅 been at this for a few hours now

quaint garnet
viral palm
#

My goal is to have a ship upgrade for the teleporters that I can reference later to add functionality to them. I'm trying to make it so I can buy this upgrade from the store. It keeps juggling between not recognizing my keywords, saying there's none in stock, and saying I've already own it when I definitely don't

#

So I guess what I'm asking is what specifically do I need to give to the Unlockables.RegisterUnlockable function, and which parts do I not need to specify?

quaint garnet
#

Unlockables.RegisterUnlockable(unlockable, StoreType.Type, TerminalNode1, TerminalNode2, TerminalNode3, Price);

viral palm
#

This is what I've been fiddling with for a while now - is there anything I'm doing wrong?

#

I can't tell if I need the TerminalNode object at all, since LL's code appears to make one for me I believe. I also have a weak grasp on what exactly TerminalNodes are, so that may be adding to my confusion

#

So with this code here, it's telling me it's not in stock when I try to buy the upgrade. Where does it store what's in stock and what isn't? Should I be setting some value for my upgrade somewhere to stock 1 upgrade?

quaint garnet
#

unless you're setting that in unity

#

wait I see nvm

#

well, I have not messed with upgrades, you do have to set it's type

viral palm
#

It looks like the LL onAwake function overrides pretty much all the data from those terminal node object I pass in anyway, so not sure about what I can do differently

quaint garnet
# viral palm Which type?

I did it in unity, but buy unlockable id is in the terminal node and the unlockable item itself has to be set to 1 if it's not a suit

viral palm
#

I’ll give it a try, thanks

little timber
#

Hey there, i'm currently trying to add an item that is buyable through the terminal and delivered via the dropship (using LethalLib), all works fine for the most part, but it looks like the weight property of the item is not being reflected in-game for some reason, it should be 8 and somehow went up to 945lbs.

Has anyone ever ran into such an issue and fixed it ?
I might also just be missing a component or something, idk.

Feel free to @ me and ask for additional information about my item's setup.

hollow sorrel
#

itemweight being the float you put in the inspector

#

You can also do
(desiredWeight/105)+1
to get the itemWeight

#

so for your case 8 lbs would be 1.07619048

little timber
#

edit: the weight value like you said does work for a regular scrap item i find in the factory, but it does not seem to be working properly on the one that comes from the dropship THONK
(i set both to the same value)

little timber
craggy jackal
#

Hey guys, I'm using the Custom Enemy API to create a new enemy, and encountering a weird issue. When running with a single player, the enemy works fine. Last night I was using the mod with some friends with me hosting. I saw that the enemy had spawned, but nobody else in the game could see it. Any ideas as to why this might happen?

brittle marsh
craggy jackal
#

I'm not sure exactly what you mean. I used LethalLib.Enemies.RegisterEnemy()

fresh folio
#

you did not register it as a network prefab

#

register the enemy's spawn prefab with RegisterNetworkPrefab()

#

that way the transforms are networked

craggy jackal
#

thank you! this worked!

#

now I'm having a separate issue. the enemy can kill the host's player, but then not any other player, even after calling player.KillPlayer()

brittle marsh
craggy jackal
#

Did some debugging and isolated the issue, here's the Rpc I'm using to kill players:

`[ServerRpc(RequireOwnership = false)]
public void KillPlayerServerRpc(int playerId)
{
Debug.Log("Ping!");
KillPlayerClientRpc(playerId);
}

[ClientRpc]
public void KillPlayerClientRpc(int playerId)
{
PlayerControllerB player = StartOfRound.Instance.allPlayerScripts[playerId];
player.KillPlayer(Vector3.zero, spawnBody: true, CauseOfDeath.Unknown);
Debug.Log("Pong!");
refreshTarget();
}`

#

The host's log prints both Ping! and Pong!, the client prints neither

brittle marsh
#

well, that's fun

craggy jackal
#

yeah it's really weird

#

the Snail is moving around just fine on the client side, it even chose the client player as its target and paths towards it

#

it just won't kill the client player

brittle marsh
#

Is that your code or Zeekerss' code btw?

craggy jackal
#

that's my code

#

I know I must be doing something wrong, the Rpc isn't working at all, it's just executing entirely locally

brittle marsh
#

you could trust the client to kill themselves by just having something like this

public override void OnCollideWithPlayer(Collider other)
{
    if (timeSinceHittingLocalPlayer < 1f) {
        return;
    }
    PlayerControllerB playerControllerB = MeetsStandardPlayerCollisionConditions(other);
    if (playerControllerB != null)
    {
        LogIfDebugBuild("Example Enemy Collision with local Player!");
        timeSinceHittingLocalPlayer = 0f;
        playerControllerB.DamagePlayer(20);
    }
}
craggy jackal
#

how do I post pretty code like this? right now I'm just using `

brittle marsh
#

```cs
code here
```

#

like that

craggy jackal
#
public override void OnCollideWithPlayer(Collider other)
        {
            if (!other.gameObject.GetComponent<PlayerControllerB>())
                return;

            base.OnCollideWithPlayer(other);

            if (stunNormalizedTimer >= 0f)
                return;

            PlayerControllerB player = other.gameObject.GetComponent<PlayerControllerB>();

            if (player != null)
            {
                if (!player.playerUsername.Equals(targetPlayer.playerUsername))
                    return;

                KillPlayerServerRpc((int) player.playerClientId);
                Debug.Log("ImmortalSnail killed player " + player.playerUsername + "!");
            }
            else
                Debug.Log("Collided with a player but it was null.");
 }
```cs
#

thanks!

#

here's my current code for OnCollide

brittle marsh
#

the bottom cs isn't necessary, I accidentally copied it

craggy jackal
#

ok nw haha

#

anyway, any ideas as to what's wrong based on this code? I'd like to get the rpc working if possible

brittle marsh
craggy jackal
#

really?

#

I just figured I should since all of the EnemyAI classes in the base game use them

#

I'll try without and let you know what happens

brittle marsh
#

I have had an issue with a ClientRpc not working when called from HitEnemy() but it worked from elsewhere in my code. Really strange issue, so yeah idk.

craggy jackal
#

are there any potential downsides to not using Rpcs here?

brittle marsh
#

the DamagePlayer() method will call an Rpc to make sure everything networks

brittle marsh
#

KillPlayer() also calls Rpc methods (such as KillPlayerServerRpc(), so you shouldn't need to do that yourself

craggy jackal
#

ok I took out the Rpcs and now I’m just using KillPlayer() directly in my code for OnCollide(). same behavior 😦

#

so OnCollide() isn’t being called on client side

brittle marsh
brittle marsh
craggy jackal
#

sorry if I misspoke earlier, I’ve been using OnCollideWithPlayer() since the beginning

#

also I do have a collision detection script attached

#

the only thing i’m doing that’s a little weird is attaching my AI in my plugin, not in the prefab editor in Unity

#

I use ‘prefab.AddComponent(typeof(SnailAI))’

#

maybe i’ll put up a repo so you guys can just see all of it

craggy jackal
brittle marsh
craggy jackal
#

ok thank you!

brittle marsh
#

no problem!

brittle marsh
brittle marsh
brittle marsh
grizzled fractal
#

what happened with the update to obliterate everything

brittle marsh
grizzled fractal
#

it has made #1191847266777042985 consistently have massive desync, and some people in #1186884307332108339 have reported other issues

brittle marsh
#

Okay, just confirmed it with Toilet Leech: shit is busted. Toilet Leech did not spawn for the other client, and instead the console shat out errors:

[Error  : Unity Log] [Netcode] Failed to create object locally. [globalObjectIdHash=1992188955]. NetworkPrefab could not be found. Is the prefab registered with NetworkManager?
[Error  : Unity Log] [Netcode] Failed to spawn NetworkObject for Hash 1992188955.
[Error  : Unity Log] NullReferenceException: Object reference not set to an instance of an object
Stack trace:
Unity.Netcode.NetworkMetrics.GetObjectIdentifier (Unity.Netcode.NetworkObject networkObject) (at <895801699cfc4b4ab52267f31e2a4998>:IL_0000)
...

@lofty nymph you might want to revert the latest update to LethalLib

proper epoch
#

Might wanna revert @lofty nymph when you're online

wooden walrus
#

I hope I'm not too stupid when asking this since I'm new to the whole modding scene,
But it seems that I can't seem to get my scrap item to work as a shovel, sounds work and generation does too. but there are no animations on the shovel whatsoever

hollow sorrel
#

just as a quick check since in my pc they're the same. No idea how my PR would break anything network related unless if its related to the network prefab registration change

#

id be glad to know the reason

#

theres no way the function signature somehow changed right huhwuhguh

#

Ah I found the issue now

#

https://github.com/EvaisaDev/LethalLib/pull/57 new PR for fixing the issue. A complete oversight on my side of the PR. NetworkPrefabs.Init() got removed in Plugin.cs when Eba might've accidentally pushed changes to the main branch instead of the dev one when she made changes to NetworkPrefabs.cs.

GitHub

A mistake was made in this commit: 8469f19
which removed NetworkPrefabs.Init(); in Plugin.cs, causing Network Prefabs to never be registered.

This is the root cause of v1.4.0s issues.

#

my old pr reverted the change but i didn't look at plugin.cs to check if Init was called for networkprefabs

lofty nymph
#

I love pushing updates before going to sleep

#

:)

tough path
#

Any chance this log could get reduced abit?

[Info   : LethalLib] Added lightbulb_item to ExperimentationLevel
[Info   : LethalLib] Added lightbulb_item to AssuranceLevel
[Info   : LethalLib] Added lightbulb_item to VowLevel
[Info   : LethalLib] Added lightbulb_item to CompanyBuildingLevel
[Info   : LethalLib] Added lightbulb_item to MarchLevel
[Info   : LethalLib] Added lightbulb_item to RendLevel
[Info   : LethalLib] Added lightbulb_item to DineLevel
[Info   : LethalLib] Added lightbulb_item to OffenseLevel
[Info   : LethalLib] Added lightbulb_item to TitanLevel
[Info   : LethalLib] Added lightbulb_item to 13 Kast
[Info   : LethalLib] Added lightbulb_item to 74 Acidir
[Info   : LethalLib] Added lightbulb_item to 154 Etern
[Info   : LethalLib] Added lightbulb_item to 46 Infernis
[Info   : LethalLib] Added lightbulb_item to 112 Aquatis
[Info   : LethalLib] Added lightbulb_item to 43 Orion

eg.

[Info   : LethalLib] Added lightbulb_item to ExperimentationLevel, AssuranceLevel, VowLevel, CompanyBuildingLevel

etc.

#

and

Info   : LethalLib] Adding Shotgun to terminal
[Info   : LethalLib] Generating buynode2
[Info   : LethalLib] Item price: 600, Item index: 21
[Info   : LethalLib] Generating buynode1
[Info   : LethalLib] Item price: 600, Item index: 21
[Info   : LethalLib] Generated keyword: shotgun
[Info   : LethalLib] Adding Shells to terminal
[Info   : LethalLib] Generating buynode2
[Info   : LethalLib] Item price: 20, Item index: 22
[Info   : LethalLib] Generating buynode1
[Info   : LethalLib] Item price: 20, Item index: 22

to

[Info   : LethalLib] Adding Shotgun to terminal (Item Price: 600, Item Index: 21)
[Info   : LethalLib] Adding Shells to terminal (Item Price: 20, Item Index: 22)
lofty nymph
#

i have a lot of debug logs

tough path
#

yeeeee dont worry im fare from innocent myself

lofty nymph
#

well i like these because they can tell me at a glance if things are working

#

when looking at someones log

tough path
#

Oh absolutely, Just would be slightly more ideal if the lines were condensed

lofty nymph
#

the reason it logs every item individually is actually because when there is a stack trace it tells me what item it broke on

tough path
#

was reading this log someone had in another mod thread and lethallib was a little chunky, might just be easier to send here incase you want ref.

lofty nymph
#

but yeah i agree that doesn't come up that often

tough path
#

some of my functions have a debugbool to easily turn on/off per item logging

lofty nymph
#

could just add extended logging as a config option

tough path
#

yee

undone brook
#

you could also make them LogDebug, that way for most people it won't show up as it's off by default in bepinex config

#

and whoever needs them can still enable them

lofty nymph
#

@tough path done

#

most of the logs are behind a config option now

tough path
#

I owe you ❤️❤️

lofty nymph
#

i did not end up merging the logs because that ended up requiring more changes

devout creek
#

Oh I should update my reference for this too

craggy jackal
#

Hey guys, I'm sure you're tired of hearing about my syncing issues but I've isolated the problem and now I'm not sure how to go about fixing it. Here's some notes I took on the issue:

#

on spawn snail on host player:

  1. client and host called Start
  2. client and host called refreshTarget
  3. host called OnCollide
    3a. host called KillPlayer (host)
  4. host called refreshTarget
    4a. set client player as target

on collide with client:

  1. client and host call OnCollide
    1a. host calls KillPlayer (client)
    doesn't work because host doesn't own client player
    1b. client does NOT call KillPlayer because target is still set as host player
#

so essentially the issue is that initially only the host calls OnCollide which prevents the client from updating the targetPlayer

#

could it just be a latency issue? the host dies immediately after spawning the snail so OnCollide is called, the client doesn't call OnCollide because the snail doesn't exist yet?

#

or maybe I need to insert an RPC that updates the targetPlayer across clients?

brittle marsh
craggy jackal
#

I had the same thought. are RPCs fairly easy to implement? the base game RPC code is pretty confusing to me and I haven’t seen an explanation for it anywhere

craggy jackal
humble pasture
craggy jackal
#

amazing thank you so much!

craggy jackal
wintry dew
#

Is there a guide for creating enemies? When I tested it, I did it in local multiplayer, and it spawns in the vents normally on all clients, but online it seems to only spawn on the host.

humble pasture
#

ugg the dreaded "works in LAN but not online"

#

are you using the latest version of lethal lib? ik there was an earlier version that broke network stuff

wintry dew
#

yes people who reported the bug said they were playing with 0.14.2

humble pasture
#

@frank lotus sadChamp

#

(there's an obsolete attribute)

#

also @lofty nymph is lethal lib network registration (specifically weather & enemies) independent of mod load order? cause when I'm looking through the source, it doesn't seem so

#

and iirc that does matter between clients

#

though don't quote me on that

#

actually does it 🤔

#

no it doesn't

lofty nymph
#

considering globalobjectidhash is the set on the actual prefab

#

which is what is used for making sure 2 prefabs are the same

humble pasture
#

wondering what would cause a monster to spawn on host but not clients (when online)

lofty nymph
#

bad networking shrug

#

idk

humble pasture
#

you have to register the network prefab before registering the enemy right?

lofty nymph
#

as long as it is registered before being spawned

humble pasture
#

well I guess you have to do both yeah

#

@wintry dew sanity check, do you do both?

wintry dew
#

yep

humble pasture
#

do the users have the same version of the mod?

wintry dew
humble pasture
#

though if you don't remake the prefab, the prefab id should be the same 🤔

fresh folio
#

Network transform correctly set?

craggy jackal
#

is there any documentation for how the rarity actually affects spawn rate when using Enemies.RegisterEnemy()? I'm guessing it's more complicated than rarity = 100 => 100% chance of spawning

undone brook
craggy jackal
#

got it. any idea where I can see other weights?

undone brook
#

ingame, or make a patch to print the pools of all levels and write it to a file

#

you could also probably calculate it dynamically, like sum up each levels pool weights then calculate the weight you need to add to get to a certain percentage

#

but then it's mod load order dependent

fresh folio
wintry dew
#

It seems to be because of the item name

indigo orchid
#

My netcode patched enemy seems to be failing to send rpcs and idk why

undone brook
#

change it to TryGetValue if you're not sure what's causing the problem and check for false, that way if you have a missing value you won't cause errors

indigo orchid
#

no the code gets patched and makes my methods like if i built it from unity it self with the netcode [ClientRpc] public void SendOutScanClientRpc() { NetworkManager networkManager = base.NetworkManager; if ((object)networkManager == null || !networkManager.IsListening) { return; } if (__rpc_exec_stage != __RpcExecStage.Client && (networkManager.IsServer || networkManager.IsHost)) { ClientRpcParams clientRpcParams = default(ClientRpcParams); FastBufferWriter bufferWriter = __beginSendClientRpc(613653848u, clientRpcParams, RpcDelivery.Reliable); __endSendClientRpc(ref bufferWriter, 613653848u, clientRpcParams, RpcDelivery.Reliable); } if (__rpc_exec_stage != __RpcExecStage.Client || (!networkManager.IsClient && !networkManager.IsHost)) { return; } Scan(); } but it fails to find the keys that i think get generated from the patcher [RuntimeInitializeOnLoadMethod] internal static void InitializeRPCS_DroneEnemyAI() { NetworkManager.__rpc_func_table.Add(1032796482u, __rpc_handler_1032796482); NetworkManager.__rpc_func_table.Add(202708153u, __rpc_handler_202708153); NetworkManager.__rpc_func_table.Add(2378372690u, __rpc_handler_2378372690); NetworkManager.__rpc_func_table.Add(613653848u, __rpc_handler_613653848); }

indigo orchid
#

@lofty nymph I apologize for ping, I was just wondering if you know what im doing wrong.

lofty nymph
#

oh

#

nvm i think i know

indigo orchid
#

What is it?

#

i did register btw

lofty nymph
#

from the stacktrace it seems like you forgot this part

#

the generated rpc initialize function is not being ran when the game loads

#

this is in the netcodepatcher readme

#

it just runs any function marked with [RuntimeInitializeOnLoadMethod], because unity doesn't do that for mods.

indigo orchid
#

thats wierd its in my code "private void Awake() {
Logger = base.Logger;
MainAssetBundle = AssetBundle.LoadFromFile(Path.Combine(Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location), "droneenemyassets"));

DroneEnemy = MainAssetBundle.LoadAsset<EnemyType>("DroneEnemy");
var TerminalNode = MainAssetBundle.LoadAsset<TerminalNode>("DroneEnemyTN");
var TerminalKeyword = MainAssetBundle.LoadAsset<TerminalKeyword>("DroneEnemyTK");

NetworkPrefabs.RegisterNetworkPrefab(DroneEnemy.enemyPrefab);
RegisterEnemy(DroneEnemy, 50, LevelTypes.All, SpawnType.Default, TerminalNode, TerminalKeyword);

Logger.LogInfo($"Plugin {PluginInformation.PLUGIN_GUID} is loaded!");

var types = Assembly.GetExecutingAssembly().GetTypes();
foreach (var type in types)
{
    var methods = type.GetMethods(BindingFlags.NonPublic | BindingFlags.Instance | BindingFlags.Static);
    foreach (var method in methods)
    {
        var attributes = method.GetCustomAttributes(typeof(RuntimeInitializeOnLoadMethodAttribute), false);
        if (attributes.Length > 0)
        {
            method.Invoke(null, null);
        }
    }
}

}"

#

unless stuff is failing to call somehow

lofty nymph
#

strange, the error definitely implies that the rpcs never got initialized

#

try adding a log below method.Invoke(null, null); ig

indigo orchid
#

adding that log made everything work :| wat

lofty nymph
#

i don't think the log did that

#

lol

indigo orchid
#

uhh

#

idk then

lofty nymph
#

i bet if you remove it it will still work

#

i have a feeling it just failed to compile last time or something and you didn't notice, or it didn't get copied over correctly idk that kind of stuff has happened to me way too often lol

indigo orchid
#

probably

#

just an issue on my side sorry bout that

lofty nymph
#

no worries

craggy jackal
#

hey guys, what is the range of values for rarity when registering an enemy? I currently have my custom enemy at 100 rarity, and I have no idea if this is high or low.

brittle marsh
tough path
#

Could I be a huge pain and humbly request that your patches in Dungeon.cs stop running if LLL is loaded? would do it on my side but not sure how I can

digital briar
#

Okay simple question, im doing my own thing now (creating my script) my only question is what are the key differences between Door.cs and DoorLock.cs ( I want to inherit one of these two but dont know if there is a major difference)

meager thunder
#

Hi, I was wondering if there's any examples or documentation regarding on how to create custom weather with lethallib? I had given a look through lethallib's code but I'm still having a hard time understanding at how I could approach this

frank lotus
humble pasture
#

that, but also quite a few just don't understand how the csproj files work

wooden walrus
#

Is creating moons possible with lethallib?

craggy jackal
#

LethalLevelLoader is probably better for this, idk if LethalLib has this

meager plover
#

Yeah LethalLevelLoader is the lib for moons/dungeons, LethalLib is for everything else, like scrap and handles etc

elder trench
#

what is the proper way to make a scrap that works as a weapon? I read something about a shovel script that gets automatically applied if you mark the scrap as a defensive item but even with every combination of two handed + two handed animation + hold left click doesn't seem to do anything. would I need to make a new item prefab that uses shovel script component instead of physics prop on the root?

thorny plinth
#

I keep getting a null ref that doesn't tell me what is the issue! It must be with the prefab right?

west mica
#

is the assetbundle in the correct folder?

thorny plinth
#

dynamolight is the asset bundle

west mica
#

your plugin/mod folder for the game itself should have the assetbundle and the .dll

thorny plinth
#

oohh

#

that might be it

#

yup

#

it works

west mica
#

sweet

thorny plinth
#

how do I make my item play a vanilla animation?

#

this isnt working

thorny plinth
#

Like the view model animation

craggy jackal
#

Hey guys, working on a custom enemy, does anybody know what allows an enemy to climb on railings? mine doesn’t and i’m not sure why. already made sure the area mask on my NavMeshAgent is set to “Everything”

west mica
#

i don't think the railings have navmesh baked, but i might be wrong about that

glass frost
#

Heya, i'm trying to use the map objects API and when generating the dungeon it spawns 1 object (and its custom component Awake() fully finishes), but then throws this error

[Error  : Unity Log] NullReferenceException: Object reference not set to an instance of an object
Stack trace:
(wrapper dynamic-method) RoundManager.DMD<RoundManager::SpawnMapObjects>(RoundManager)
(wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition.Trampoline<RoundManager::SpawnMapObjects>?-512036168(RoundManager)
LethalLib.Modules.MapObjects.RoundManager_SpawnMapObjects (On.RoundManager+orig_SpawnMapObjects orig, RoundManager self) (at <4eedb4dc36094adcb65137cf81f2803d>:IL_009D)
(wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition.Hook<RoundManager::SpawnMapObjects>?1397977128(RoundManager)
(wrapper dynamic-method) RoundManager.DMD<RoundManager::GeneratedFloorPostProcessing>(RoundManager)
RoundManager+<LoadNewLevelWait>d__115.MoveNext () (at <af9b1eec498a45aebd42601d6ab85015>:IL_013C)
UnityEngine.SetupCoroutine.InvokeMoveNext (System.Collections.IEnumerator enumerator, System.IntPtr returnValueAddress) (at <e27997765c1848b09d8073e5d642717a>:IL_0026)

not too sure how to even debug this error, could it be a problem with the prefab? i've only got the fbx model in a parent gameobject, adding a custom component after loading from the asset bundle

#

wait i didnt add a network object, thats probably required 💀

#

it was lol

merry meadow
#

in the noisemaker script does this Trigger animator thing give the item animation?

wintry dew
#

Can RegisterEnemy only be used once? It seems that RegisterEnemy is only registered for Experimentation.

int[] numbers = shrimpSpawnWeight.Value.Split(',').Select(int.Parse).ToArray();
LevelTypes[] levelTypes = {
    Levels.LevelTypes.ExperimentationLevel,
    Levels.LevelTypes.AssuranceLevel,
    Levels.LevelTypes.VowLevel,
    Levels.LevelTypes.MarchLevel,
    Levels.LevelTypes.OffenseLevel,
    Levels.LevelTypes.RendLevel,
    Levels.LevelTypes.DineLevel,
    Levels.LevelTypes.TitanLevel };

for (int i = 0; i < numbers.Length; i++)
{
    Levels.LevelTypes levelType = levelTypes[i];
    LethalLib.Modules.Enemies.RegisterEnemy(shrimpEnemy, numbers[i], levelType, Enemies.SpawnType.Default, shrimpTerminalNode, shrimpTerminalKeyword);
    Plugin.mls.LogInfo("Shrimp spawn chance in " + levelTypes[i] + ": " + numbers[i]);
}

LethalLib.Modules.Enemies.RegisterEnemy(shrimpEnemy, shrimpModdedSpawnWeight.Value, Levels.LevelTypes.Modded, Enemies.SpawnType.Default, shrimpTerminalNode, shrimpTerminalKeyword);
Plugin.mls.LogInfo("Shrimp spawn chance in Modded Moons: " + shrimpModdedSpawnWeight.Value);
indigo orchid
#

this is all i do for my drone enemy and it works on other moons```cs
Logger = base.Logger;
MainAssetBundle = AssetBundle.LoadFromFile(Path.Combine(Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location), "droneenemyassets"));

        _harmony = new Harmony(PluginInformation.PLUGIN_GUID);

        InitializeConfig();

        DroneEnemy = MainAssetBundle.LoadAsset<EnemyType>("DroneEnemy");
        var TerminalNode = MainAssetBundle.LoadAsset<TerminalNode>("DroneEnemyTN");
        var TerminalKeyword = MainAssetBundle.LoadAsset<TerminalKeyword>("DroneEnemyTK");

        NetworkPrefabs.RegisterNetworkPrefab(DroneEnemy.enemyPrefab);
        RegisterEnemy(DroneEnemy, spawnWeight.Value, LevelTypes.All, SpawnType.Default, TerminalNode, TerminalKeyword);
        
        Logger.LogInfo($"Plugin {PluginInformation.PLUGIN_GUID} is loaded!");
wintry dew
#

thanks 👍

#

can't I set a spawn weight for each moons?

humble pasture
# wintry dew can't I set a spawn weight for each moons?
/// <summary>
/// Registers a enemy to be added to the given levels, However it allows you to pass rarity tables, instead of just a single rarity
/// </summary>
public static void RegisterEnemy(EnemyType enemy, SpawnType spawnType, Dictionary<Levels.LevelTypes, int>? levelRarities = null, Dictionary<string, int>? customLevelRarities = null, TerminalNode infoNode = null, TerminalKeyword infoKeyword = null)
{ /*...*/ }

/// <summary>
/// Registers a enemy to be added to the given levels, However it allows you to pass rarity tables, instead of just a single rarity
/// Automatically sets the spawnType based on the enemy's isDaytimeEnemy and isOutsideEnemy properties.
/// </summary>
public static void RegisterEnemy(EnemyType enemy, Dictionary<Levels.LevelTypes, int>? levelRarities = null, Dictionary<string, int>? customLevelRarities = null, TerminalNode infoNode = null, TerminalKeyword infoKeyword = null)
{ /* .. */ }
formal path
#

Hi all! Is there anyone who could talk me through the c# section of the LethalLib item video? I'd like to start porting items from LethalSdk but need some guidance the first time through. Any help would be appreciated!

frank lotus
# formal path Hi all! Is there anyone who could talk me through the c# section of the LethalLi...

The best way to learn -

  • Watch it yourself
  • If you don't understand something, pause the video + rewatch the relevant part until you figure out a search term / AI prompt
  • Google / ChatGPT your search term / prompt and read around.
  • If you don't understand something that comes up, google / chatgpt that too.
  • If at any point you spend more than 10 minutes on a single topic, ask about that topic in #dev-general

Once you're happy, try to follow the tutorial or the one on https://lethal.wiki - again, asking questions when you encounter specific issues or things you don't understand

brittle marsh
brittle marsh
neat rose
#

Changes look good to me. Thanks for making that PR!

lofty nymph
#

By the way if people want to take over maintaining lethallib i can add collaborators.
The repo has workflows for automatically building and making releases on nuget and thunderstore, and at this time I do not have the energy nor do i feel like maintaining it myself, because i have a lot of other stuff to deal with.

lofty nymph
brittle marsh
brittle marsh
lofty nymph
#

try to avoid making changes that break backwards compatibility

#

(things like changing function parameters/types will do this, but i assume you know that, this is not a call out, just mentioning it)

#

anyway i sleep now

brittle marsh
#

okay, thank you and good night!

lofty nymph
#

i hate when people give minimum context and no logs

#

i kinda just stopped looking at github issues a while ago

brittle marsh
#

yeah, I think there might have been a bug that for some reason now not having a ScanNodeProperties thing caused a crash (in Terminal_Start), but I don't know why it wouldn't have before

#

though, I think the crash they are talking about is different

lofty nymph
#

and said mod didn't have a scan node properties component on a object

#

shrug

brittle marsh
#

even then though, I have had an enemy that didn't have a scannode component and I don't think I had issues. And one person in #dev-general general also said it only happened now since the new update when they also didn't have that, and the enemies were being registered. Dunno

lofty nymph
#

yeahh i don't think i have ever had the issue either with enemies

#

scrap did have that issue

brittle marsh
#

huh

#

Yeah I wonder how it became an issue now

lofty nymph
#

if scan node properties are missing from scrap it throws an error i know that much

#

dont think i have ran into it with enemies

tough path
#

@lofty nymph I know you probably don't mind but figured id ask since your active here rn,
Any functional reason your using monomod for your patches? or just preference

lofty nymph
tough path
#

yeee ez

lofty nymph
#

i find it more intuative personally

brittle marsh
#

I have only modded LC, but I find Monomod cleaner and easier

lofty nymph
#

since post and pre patches are a single patch with monomod mmhook

tough path
#

im one of the only people it really affects but it sucks for mods that need to know what content is from vanilla and which content isnt because i cant easily slip my patch in before yours

lofty nymph
#

lol

tough path
#

weird edge case

#

doesnt help that harmony priority is barely explained online either

brittle marsh
#

Well, would it be a problem to make LethalLib do things slightly later?

lofty nymph
#

lethallib's execution of stuff is weirdly fine tuned iirc

tough path
#

if needed ill prob just push a event or something that i can use maybe

lofty nymph
#

you can always use monomod to hook my hooks

tough path
#

my ass dying because i need to juggle lethallib being too early for me (cuz of the monomod thing) and lethal expansion being way too late for me (cuz they use terminal start)

brittle marsh
#

I guess we could also write a BepInEx patcher to allow hooking to the first mod that ever loads or something, there are ways be first

tough path
#

oh yeah theres def routes

lofty nymph
#

generate an mmhook file for lethallib and ship it with the mod

#

:)

tough path
#

also would have been super convienent for unity to have a way to check if an asset came from a bundle or not but

#

¯_(ツ)_/¯

brittle marsh
#

it's basically done, just needs more testing

lofty nymph
#

lol

#

how would you know what file to generate the mmhook file from

brittle marsh
#

it reads every plugin's assembly to find the files they reference

#

so, pretty simple

lofty nymph
#

sounds efficient

#

lmao

brittle marsh
#

yeah that's why I made a cache system so it can do it in 20ms for me cus it doesn't need to do anything other than check the cache and when files were last modified

#

So it's faster than HookGenPatcher, which isn't very optimized because it reads all MMHOOK files

lofty nymph
#

that reminds me, i had a remake of lighterpatcher which was more dynamic

#

..somewhere

brittle marsh
#

huh

lofty nymph
#

lighterpatcher was very hardcoded

#

it was gross

brittle marsh
#

zamn

tough path
#

how did the item id stuff go in current lethallib btw

remember you being somewhat in the middle? of that before you stopped talking as much

lofty nymph
#

wdym? the fixing ids shifting in saves thing?

#

it kind of worked but it had a tendency to break a lot so i just have it disabled with a config option to enable it

tough path
#

yee

lofty nymph
#

i don't know how it broke but some people had issues with it

#

it was kinda jank lol

tough path
#

so valid

brittle marsh
#

Okay, it appears that there are more issues related to registering enemies

Issues:

  • LevelTypes.All overrides spawn values
  • LevelTypes.Modded is required to register enemy to any modded moon, if LevelTypes.All is not set
    • LevelTypes.Modded's rarity is never applied, 0 is used instead
    • To have a rarity other than 0, customLevelRarities dictionary must contain level name, and its rarity will be used
#

I can work on fixing these

#

I guess I'll try uploading the null check fixes to thunderstore by making the github release thing

...or maybe not, damn, the thought of breaking everything is a bit scary lol

brittle marsh
#

Okay, maybe I'll do it, and I really hope nothing breaks, and if everything breaks, I'll just fucking die 💀

#

I did it, and I'm scared lol

#

I don't think I broke anything yoiled

timid shell
#

has anyone run across this before?

[Error  : Unity Log] NullReferenceException: Object reference not set to an instance of an object
Stack trace:
GetMadEpic.Plugin.Awake () (at C:/Development/test/LC-ExampleEnemy-main/Plugin/src/Plugin.cs:156)
UnityEngine.GameObject:AddComponent(Type)
BepInEx.Bootstrap.Chainloader:Start()
UnityEngine.Rendering.HighDefinition.HDRenderPipelineAsset:OnEnable()

I only get it when I have these lines

156 NetworkPrefabs.RegisterNetworkPrefab(GetMadEpic.enemyPrefab);
157 Enemies.RegisterEnemy(CustomEnemy, BoundConfig.SpawnWeight.Value, Levels.LevelTypes.All, Enemies.SpawnType.Default, CustomEnemyTN, CustomEnemyTK);

I have the dll for lethallib referenced in my csproj file and the dependency attribute for it
hope it's not something stupid that I missed 🙃

#

NEVERMIND IT WAS SOMETHING STUPID THAT I MISSED
ModAssets.LoadAsset was loading assets with the wrong names 🙈

finite hill
#

[Error : LethalLib] An Enemy AI Collision Detect Script on GameObject 'TheDog' of enemy 'Shrimp' does not reference a 'Main Script', and will cause errors!

#

@lofty nymph

brittle marsh
#

do the enemies not cause errors then?

#

I guess they might apply the reference afterwards

brittle marsh
finite hill
brittle marsh
finite hill
#

yea its lc office

#

also is there a page dedicated to help?

#

trying to find the root of a problem

brittle marsh
#

Okay, so here is why that warning is triggering, the AI script is added afterwards LethalLib does the check

Enemies.RegisterEnemy(shrimpEnemy, shrimpSpawnWeight.Value, (LevelTypes)(-1), (SpawnType)0, shrimpTerminalNode, shrimpTerminalKeyword);
// ...
shrimpPrefab.AddComponent<ShrimpAI>();```
brittle marsh
#

I should probably make the warning be a warning instead of an error though

finite hill
merry meadow
#

How do i make a scrap have a two handed animation? i enabled the Two Handed and Two Handed Animation bools in the item component but its not working

devout canyon
#

Anyone ever had a bug where anything is independet from the prefab after using Instantiate, except the itemProperties. They're the exact same object for all of my GrabbableObjects i instantiated. AudioSource, NetworkObject, Collider, MeshRenderer are all unique like they should be

lofty nymph
#

that's just how things work

#

all instances of the same item share their itemProperties instance because that's a ScriptableObject

#

while components are unique

devout canyon
#

That seems perfect for most cases 👌🏻

In my special case it was problematic, because i wanted to change the itemProperties.weight at runtime (for a GrabbablePlayerObject), so that when someone grabs another player the weight is automaticly applied correctly.
Can Instantiate the itemProperties now or don't touch itemProperties.weight and do it manually with a NetworkVariable.

Thanks for the explanation :)

lofty nymph
#

just food for thought

devout canyon
#

good input, didn't knew about that and seen them as single properties rather than an "instance" till now. I will set it on the list of things to rework for the next version of my mod

zinc copper
#

How has the 🧙‍♀️🔮⛏️💎👾🪐🏹 mod been going

(Dome 🔑per)

lofty nymph
#

Its been going fine, massive headache tho because of how much the noita lua sandbox limits you

zinc copper
#

Understandable. Don't really follow really Noita modding stuff myself. I've seen a few crazy things, but this one really pushes the limits. Looking forward to it though.

And games with cryptic secrets are top tier

brittle marsh
sudden vector
#

we are a bit confused as to how to fix this

lucid mango
#

we're getting this error after creating a networkprefab and adding our network behaviour object as a component to it with lethallib. we then spawn the NetworkObject at StartOfRound.Start() but for some reason it's still null

sudden vector
#

we are completely new to networking and using lethal lib btw

devout canyon
#

Is the "IsMeltdown" variable a NetworkVariable? Some code for MeltdownChanceBehaviour.IsMeltdown or the Display.. method that calls it could help finding the cause

glass frost
devout canyon
#

Is it initialized with new NetworkVariable<>?

lucid mango
#

then in the plugin's Awake() we call this:

{
    MeltdownChanceManagerPrefab = LethalLib.Modules.NetworkPrefabs.CreateNetworkPrefab("MeltdownChance Manager");
    MeltdownChanceManagerPrefab.AddComponent<MeltdownChanceBehaviour>();
}```
#

and then as a postfix on StartOfRound.Start() we do this

        [HarmonyPostfix]
        public static void OnSessionStart(StartOfRound __instance)
        {
            if (!__instance.IsOwner) return;
            try
            {
                var MeltdownChancetManager = Object.Instantiate(MeltdownChanceBase.MeltdownChanceManagerPrefab, __instance.transform);
                MeltdownChancetManager.hideFlags = HideFlags.None;
                MeltdownChancetManager.GetComponent<NetworkObject>().Spawn();
                MeltdownChanceBase.logger.LogError($"Spawning MeltdownChanceBehaviour.");
            }
            catch (Exception e)
            {
                MeltdownChanceBase.logger.LogError($"Failed to spawn MeltdownChanceBehaviour:\n{e}");
            }
        }```
sudden vector
lucid mango
#

idk if it has anything to do with our mod, but this gets logged to console immediately after our override OnNetworkSpawn() is exectued:

[Warning: Unity Log] damageTrigger is disabled! Netcode for GameObjects does not support spawning disabled NetworkBehaviours! The InteractTrigger component was skipped during spawn!
[Info   : Unity Log] Client connected callback in gamenetworkmanager
[Info   : LethalLib] Found 0 prefabs to fix```
brittle marsh
glass frost
#

yep they are like the teleporter traps.
checked the PR and no changes to mapobjevts so I would assume they still don’t spawn on custom moons

#

I think it’s a load order problem from when I briefly looked at it before..? LethalLib registers map objects before LLL loads moons

brittle marsh
glass frost
#

yeah no worries, thanks for fixing it :D

brittle marsh
#

lol, yeah I could update LethalLib like right now, but it is a bit scary to do that 😅
But Xu has tested my changes, and it seems to work for them too so it should probably be fine, I hope :3

#

I wish there was an easy way to release beta versions (on Thunderstore) for people to test, it would make life so much easier lol

zinc flower
#

I just wonder what black magic the Scopophobia dev did to make shy guy spawn everywhere lol, I love how that's the only mod that doesn't need the fixes coming today

brittle marsh
crimson mauve
#

Also @raw fiber

#

Here's ur ping

zinc flower
brittle marsh
#

damn, why is git so hard to use 😭
I do one thing, and then I didn't do something, and then I want to undo what I did so it would let me do a thing, but I can't figure out how to fucking undo. This is of course partly a skill issue, but damn

crimson mauve
#

Just Google it baka

#

Feel my wrath

brittle marsh
#

eh fuck it, I'm gonna delete my repo from my machine and pull it again from github lol

#

git is too confusing 😭

crimson mauve
#

You're missing out on the opportunity of learning

brittle marsh
crimson mauve
#

Did you stage your changes?

brittle marsh
# crimson mauve Did you stage your changes?

bruh yeah I did push my previous changes (at least the code changes I did I pushed), then I tried rebasing and then I've missed some step or whatever and it doesn't allow me to do it and then I try to undo and I don't know what the fuck that does and then I can't stash my changes away (because there aren't any), I can't checkout to another branch, and I don't know what to do. Totally a skill issue though

crimson mauve
brittle marsh
#

okay, so what I did was I tried merging EvaisaDev:main into my main branch, but yeah I don't fucking know. I just used the sync fork button in GitHub to do that instead

#

yeah I really need to learn how to use git lol

raw fiber
#

but ty

brittle marsh
#

okay I remembered to write the changelog yoiled

#

the new version is now being uploaded, I sure hope nothing explodes :3

zinc flower
brittle marsh
#

haha, thanks :3
The new version seems to be up on Thunderstore now btw

zinc flower
#

Btw while we're here

#

@brittle marsh

brittle marsh
#

is this something that has happened before?

zinc flower
#

Yeah, it's rare but when it happens the ship won't land and gets stuck on random seed

#

I should state maybe you already fixed that cus that's happening with 0.14.4 lol

brittle marsh
#

huh, it comes from the game code, and for some reason tries to access a thing in the list which doesn't exist (Index was out of range). I dunno if that's because of a mod or if it is just a bug in the game, but I can look into that 👍

zinc flower
#

👍

cyan frigate
#

That bug happened to me when I tried to patch in adding something to the map objects array on my own before realizing LethalLib does it already

#

Although having a hard time figuring out how to make that work, documentation is still pretty spotty lol

cyan frigate
#

Is there a specific place or way I should be calling MapObjects.RegisterMapObject? When I use it and then land on a moon I get this error:

[Error  : Unity Log] NullReferenceException: Object reference not set to an instance of an object
Stack trace:
(wrapper dynamic-method) RoundManager.DMD<RoundManager::SpawnMapObjects>(RoundManager)
(wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition.Trampoline<RoundManager::SpawnMapObjects>?-1724232704(RoundManager)
LethalLib.Modules.MapObjects.RoundManager_SpawnMapObjects (On.RoundManager+orig_SpawnMapObjects orig, RoundManager self) (at <a195ca621c6e43699e5855ec3dd9dd63>:IL_009D)
(wrapper dynamic-method) MonoMod.Utils.DynamicMethodDefinition.Hook<RoundManager::SpawnMapObjects>?1359250684(RoundManager)
RoundManager.GeneratedFloorPostProcessing () (at <af9b1eec498a45aebd42601d6ab85015>:IL_000F)
RoundManager+<LoadNewLevelWait>d__115.MoveNext () (at <af9b1eec498a45aebd42601d6ab85015>:IL_013C)
UnityEngine.SetupCoroutine.InvokeMoveNext (System.Collections.IEnumerator enumerator, System.IntPtr returnValueAddress) (at <e27997765c1848b09d8073e5d642717a>:IL_0026)
#

Here's the code I call from the Awake function of my plugin

private static void RegisterMapObjects()
{
    var def = ScriptableObject.CreateInstance<SpawnableMapObjectDef>();
    def.spawnableMapObject = new SpawnableMapObject
    {
        prefabToSpawn = ShardPrefab,
    };
    var curve = new AnimationCurve(new Keyframe(0f, 2f), new Keyframe(1f, 6f));
    MapObjects.RegisterMapObject(def, Levels.LevelTypes.All, _ => curve);
}

ShardPrefab isn't null, which I've already checked for

raw fiber
obtuse burrow
#

Hi i was wondering if anyone knew what was causing this, I saw someone mention LethalLib does it. I get stuck on random seed screen after going to a LECore Moon > Orbit > quit to Main Menu > reload save > try to land again; it fixes itself if i restart the entire game or go to a diff moon.

brittle marsh
crimson mauve
#

it does say LLL not LL

#

@tough path fix ur game

cyan frigate
#

Seems like one of the mods you have has a faulty interior, hard to tell though

zinc flower
crimson mauve
#

i've seen good games with less code, just fix it batby

zinc flower
#

Lol

tough heath
#

@brittle marsh thank you so much again old_pleading

#

time to gather the gang and play lc again all day

brittle marsh
#

haha, no problem :3

zinc flower
tough heath
#

I havent really found it on the moon I was on unfortunately

#

so I cant say for sure

sudden vector
raw fiber
#

everything worked fine for me thanks

sudden vector
#

we figured it out mostly

empty obsidian
#

When registering scrap item rarities to override with the customlevelrarities constructor, it looks like we can't specify vanilla moons. Is this intentional?

#

i.e. if we specify a scrap item to only be on titan for example, and have a config setting to allow players to set spawn rarities, who want to make it spawn on experimentation, we can't do this via the customlevelrarities param

#

Are we supposed to adjust the enum parameter passed in for this, or has this use case been overlooked?

crimson mauve
#
 private (Dictionary<LevelTypes, int> spawnRateByLevelType, Dictionary<string, int> spawnRateByCustomLevelType) ConfigParsing(string configMoonRarity) {
            Dictionary<LevelTypes, int> spawnRateByLevelType = new Dictionary<LevelTypes, int>();
            Dictionary<string, int> spawnRateByCustomLevelType = new Dictionary<string, int>();

            foreach (string entry in configMoonRarity.Split(',').Select(s => s.Trim())) {
                string[] entryParts = entry.Split('@');

                if (entryParts.Length != 2)
                {
                    continue;
                }

                string name = entryParts[0];
                int spawnrate;

                if (!int.TryParse(entryParts[1], out spawnrate))
                {
                    continue;
                }

                if (Enum.TryParse<LevelTypes>(name, true, out LevelTypes levelType))
                {
                    spawnRateByLevelType[levelType] = spawnrate;
                    Plugin.Logger.LogInfo($"Registered spawn rate for level type {levelType} to {spawnrate}");
                }
                else
                {
                    spawnRateByCustomLevelType[name] = spawnrate;
                    Plugin.Logger.LogInfo($"Registered spawn rate for custom level type {name} to {spawnrate}");
                }
            }
            return (spawnRateByLevelType, spawnRateByCustomLevelType);
        }
#

this is what i use

empty obsidian
#

Ah yeah this looks like what I was looking at for an alternative

#

Specifically the last enum parse, thanks

shadow condor
crimson mauve
#
[15:08:19.2143667] [Error  : Unity Log] NullReferenceException: Object reference not set to an instance of an object
Stack trace:
SCPCBDunGen.SCPCBDunGen+RoundManagerPatch+<>c__DisplayClass1_1.<AddConversions>b__1 (Item x) (at <17c920b375414721a96e8ff8464ca52a>:IL_0000)
System.Collections.Generic.List`1[T].Find (System.Predicate`1[T] match) (at <787acc3c9a4c471ba7d971300105af24>:IL_000D)
SCPCBDunGen.SCPCBDunGen+RoundManagerPatch.AddConversions (SCPCBDunGen.SCP914Converter SCP914, System.Collections.Generic.List`1[T] lItems, System.String sItem, System.Collections.Generic.IEnumerable`1[T] arROUGH, System.Collections.Generic.IEnumerable`1[T] arCOARSE, System.Collections.Generic.IEnumerable`1[T] arONETOONE, System.Collections.Generic.IEnumerable`1[T] arFINE, System.Collections.Generic.IEnumerable`1[T] arVERYFINE) (at <17c920b375414721a96e8ff8464ca52a>:IL_0110)
SCPCBDunGen.SCPCBDunGen+RoundManagerPatch.SCP914Configuration () (at <17c920b375414721a96e8ff8464ca52a>:IL_0104)
(wrapper dynamic-method) RoundManager.DMD<RoundManager::SpawnSyncedProps>(RoundManager)
RoundManager+<LoadNewLevelWait>d__115.MoveNext () (at <af9b1eec498a45aebd42601d6ab85015>:IL_0129)
UnityEngine.SetupCoroutine.InvokeMoveNext (System.Collections.IEnumerator enumerator, System.IntPtr returnValueAddress) (at <e27997765c1848b09d8073e5d642717a>:IL_0026)
#

latest error was this

#

which is SCP dungeon

#

not related to LL

#

and other errors was calculatepolygonpath

#

which is probably from wesley's moons if you were playing em

shadow condor
zinc flower
#

@brittle marsh is a patch coming for v50?

brittle marsh
zinc flower
#

Oh wait LethalLib seems to work

#

Now to find out what mod was not loading

tough path
#

i could see some of lethallibs code breaking

zinc flower
tough path
#

oh LLL is super cooked

#

kinda

#

working on it

zinc flower
#

You got this

#

I'll disable my stuff that relies on it for now cus I wanna check out the new moon tn

tough path
#

the actual changes are fine its small changes to very crucial stuff lll touches

zinc flower
#

Ahhhh

#

I believe in you 🙏 if you can get a patch out tonight I will quite literally wait

#

lol

#

There is some mod throwing this error though

tough path
#

spent 10min trying to find a error

#

realise its from ll 😭

vagrant nacelle
zinc flower
#

Well bearer of bad news

#

😦

vagrant nacelle
#

NOO ARSON AND MAXWELL AND COOKIE FUMO

zinc flower
#

🫡

#

They will be missed

#

So will Boomba

vagrant nacelle
#

:((

zinc flower
tough path
floral rock
#

I really dont wanna play without that mod

vagrant nacelle
zinc flower
vagrant nacelle
#

NOOOO

zinc flower
#

other scrap mods and stuff are working fine

vagrant nacelle
#

Ruining my hopes and dreams like that xD

zinc flower
#

Sorry

floral rock
vagrant nacelle
#

np

floral rock
#

no joke

#

wasnt there someone doing mod commissions, or am I thinking of a dif server

#

wait @tough path you do comms right? although I dont wanna bother you now as you seem quite busy maybe sometime in the future

tough path
#

itll b fixed

#

if i get to it before Hamunii i do have a kofi link 🤠 but its no stress

floral rock
#

wanna support the good devs

brittle marsh
#

could help to send the logs to see what's actually going wrong, otherwise we can't really help

tough path
steep tusk
#

damn i though this was help and trouble channel my bad

#

💀

brittle marsh
#

💀

zinc flower
#

Yeah can confirm the bug with LethalLib right now causing enemies to not spawn

#

Lol

tough path
zinc flower
#

let's goooo lunxara_love_with_tail is the LLL update pushed?

marsh island
#

it looks like a MonoMod style patch to RoundManager.Start() in LethalLib causes it not to run, meaning that timeScript is perpetually null and causes error spam (and possibly also failure to spawn enemies)

tough path
#

huh

#

for v50?

marsh island
#

it claims to be caused by the dungeonFlowTypes field not being found, though that field does exist, so maybe something was changed about that and it causes a type error

#

yeah

tough path
#

yeah no that field is a different type now

#

causes most of lethallib to just combust

marsh island
#

that would make sense

#

so prob just relinking it would work

tough path
#

yeah

#

i ported lll in 3 hourz

#

changes are not that bad

marsh island
#

yeah this update isn't very invasive it appears

#

all my mods seem fine, even one where they fixed an issue that mine fixed also lol

#

doubled up null check but it's nbd

#

(also, your working on LethalLib to update it is much appreciated!)

zinc flower
floral rock
#

like few days

#

may be wrong lol

zinc flower
tough path
#

So the issue is

#

The version for v50 won’t work on v49

#

Not sure best way to even theoretically release it

vagrant nacelle
#

Hmm

tough path
#

Maybe just have it ready for v50?

zinc flower
vagrant nacelle
#

Yeah

zinc flower
#

and say to only use it if playing with v50 beta

#

then push changes to stable when V50 officially launches

vagrant nacelle
#

^ Like I suggested a bit ago

#

Just make another project for v50 lethal lib

tough path
#

actually hmm

vagrant nacelle
#

Deprecate it when the release comes out

tough path
#

I have an idea

vagrant nacelle
#

oo?

tough path
#

Ill get back to yall

#

It’s cursed tho

vagrant nacelle
#

?

zinc flower
vagrant nacelle
#

xD

#

Time to see what demon batby summoned with the idea

zinc flower
#

if the update is gonna be pushed I'll wait to stream again tn til after it's out

tough path
#

I gotta cook abit more lll stuff anyway cuz ideally i want lll in a position so if full release drops i can drop within 12 hours

zinc flower
#

I expect v50 will be soon tbh

#

With how little bugs there actually are

vagrant nacelle
#

I havent even started on making models for new scrap for my moons yet

#

I should start doing that soon so im ready to make the items quickly after LLL update gets released

zinc flower
vagrant nacelle
#

yepp

#

Sector-0 more like Sadness-0 :((

zinc flower
#

You got this

vagrant nacelle
#

im trying

#

fr

tough heath
#

sector-0 filled with || old birds || is gonna be fun

vagrant nacelle
floral rock
#

lemme put old birds inside

zinc flower
zinc flower
#

I want that LethalLib update for V50 beta

#

😭

floral rock
pearl dove
#

LethalLib is causing the game can't spawn the monsters and entities

crimson mauve
pearl dove
#

oh, okay...

#

at least I can find the alternate ways to enjoy the beta version so that's fine ;p

#

damn, want to try other moons which made by mods

crimson mauve
#

Patience brings happiness, trust

pearl dove
#

yeah, gotta wait then, thanks for info

finite hill
#

lethallib not being compatible with beta cut my modpack in half 😦

floral rock
neat rose
#

I think for LL that might also be a good idea because then modders can already download the library and implement it before the release and we can all publish our mods - almost - the moment the update comes out.

crimson mauve
#

that... sounds a like a really good idea actually

pearl dove
#

Nah, for me. I can find some more interesting of alternative ways to enjoy without it, so I ain’t worry about it.

grizzled fractal
devout canyon
#

Would it be possible to add a config option to seperate the loading of custom enemies & custom items in the future, so that in case one of the two is broken in a future release beyond v50, those mods who only have items / enemies may still be able to use it, if the other part is broken?

tough path
#

probably noty

#

can't really do that tbh

devout canyon
#

ah, sad. have you made any progress with the potential fix? :)

tough path
#

yeah its easy to fix

#

just difficult to redistribute

#

blame thunderstore

devout canyon
#

may it be possible to fix it from outside, e.g. another mod that only contains the fix?

#

or is it something that can only be achieved by changing the code inside LethalLib itself?

tough path
#

the latter

rough kestrel
#

dang, so the issue is easy to fix but Thunderstore is making it difficult to upload the fixed version? or am i misunderstanding?

pearl dove
#

The point is, this is still beta v50. If the game will be updated officially, will these mods work in official, stable new version?

tough path
#

eg. look at something like modrinth

#

you can release updates set to their own alpha/beta/release and target them on specific basegame versions

rough kestrel
#

i see, so how does targeting specific versions for a release work?

tough path
#

eg. if we used modrinth i could push a lethallib update that is explicitly marked that its for v50

#

so people on v49 wouldn't get it as an auto update

rough kestrel
#

ahh, but TStore doesn't have that option?

tough path
#

but now if i push an update to LL for v50 everyone using ll on v49 would get the v50 update and that would break for them

#

tstore has no options for these kind of things

rough kestrel
#

guessing it'd be a massive pain to get it to work with v49 and v50 too

tough path
#

you cant

#

afaik

rough kestrel
#

ah, lack of backwards compatibility sounds like a pain

tough path
#

the changes i need to make are super simple but just due to how this all works i cant make one that works on both

#

idk how programming pilled you are but one of the notable variables we look at changed its type (which isnt a bad thing)

#

but it means when lethallib looks at it its now seeing it with the wrong type

#

so it explodes

#

updating that is easy but then on v49 the same problem is happening in reverse

rough kestrel
#

hm, would it be possible to make a pop-up that appears when booting the game with LethalLib installed in a v50 updated version that says "if you are using LL on v49, please downgrade it to x version, as this version was made for v50" or something like that?

tough path
#

i mean maybe

#

but then its like

#

i would have to spend time on thagt

rough kestrel
#

it'd deal with the backwards compat issue by warning people that hey,k this version's borked for v49

tough path
#

which i dont mind on its own but i do feel that time could be spend working on stuff thats relevant after the beta yknow

rough kestrel
#

very true

brittle marsh
#

yeah, thunderstore is just bad

rough kestrel
#

but another thing is we don't know how long v50 will be in beta

tough path
#

depending on how LLL goes vs. how long 50 goes we could just jump to the beta yeah

#

just depends

rough kestrel
#

could be a week, could be a year

#

especially considering that latest patch, seems like Zeekerss very much isn't done with v50 yet

brittle marsh
#

if we really wanted, we could check the game version string or int and depending on that do the specific patches, which would make it compatible with 49 and 50, but yeah not a great solution

brittle marsh
#

because the referenced assembly is missing a thing then that we need?

tough path
#

yeee

brittle marsh
#

damn

tough path
#

i think it may explode early enough to where its hard to do that kinda thing yknow

#

i could be wrong!

rough kestrel
#

also wouldn't it then be considering things that are in v50 but not v49?

brittle marsh
tough path
#

yee

rough kestrel
#

unsure how things act when say, it's thinking of what ould be happening with Old Birds but since they don't exist in v49, the mod kinda explodes itself

tough path
#

the fact it is a change is not minor

rough kestrel
#

i see, mainly just really curious how these things work behind the scene

marsh island
#

only way to make it work on both would be with reflection most likely, but I saw that it was erroring in MonoMod hook generation so idk if even that is possible

#

also reflection is gross

marsh island
#

oh wait about what part?

tough path
#

lll replaced the need for the code in ll that was problematic

#

we can just kill it

marsh island
#

ah I see

rough kestrel
tough path
#

thanks for @brittle marsh and @frank lotus for the help

#

lmk if yall run into problems i didn't do super mega heavy testing

zinc flower
tough path
#

yeah

zinc flower
#

Let's goooo

#

Now if LLL could work on V50

#

D;

vagrant nacelle
#

:o
!!!!

zinc flower
tough path
#

see if it works now

#

Im suprised any of LL worked before

zinc flower
#

for V50 support?

frank lotus
zinc flower
#

If you are maybe you can look into why the current version causes some Networking issues and Hudmanager spikes

#

:3

frank lotus
rough kestrel
tough path
#

is that a good thing

rough kestrel
#

doesn't cause any compat issues

#

yea, earlier enemies wouldn't spawn

#

not even the mech army on Embrion would spawn

#

but now they do

#

indoor enemies and hazards spawn too, weather isn't broken, seems to be working perfectly

#

now to test LethalThings

trail violet
#

Is LL 0.15.1 compatible with v49? Do interiors work if we stay on v49?

tough path
#

it should be fine yeah

zinc flower
rough kestrel
tough path
#

any logs

rough kestrel
#

scrap items and hazards spawned fine tho

zinc flower
#

It wouldn't log anything

#

Strangely enough

#

Still no enemies spawning without LethalThings

#

So either LethalLib is still broken or an enemy mod is broken

rough kestrel
#

actually, what's your modlist?

zinc flower
#

Well I had to disable Locker cus it has the int for EnemyPower but

#

Ignore the Unknown-StarlancerAIFix I was testing a new build for Starlancer

tough path
#

are the enemies inside or outside

zinc flower
#

No

#

None spawn at all

#

Ohhh

#

SirenHead is outside enemy

#

GiantSpecimens is outdoor

tough path
#

ok better question

zinc flower
#

Shy Guy can be either

tough path
#

have you seen enemies that are meant to spawn inside, not spawn inside when they should

vagrant nacelle
tough path
#

i mean custom

vagrant nacelle
#

Ah

#

Then none

zinc flower
#

No I saw no custom enemies at all spawn

#

Or Vanilla

rocky cloak
#

When I was having enemy spawn issues a while ago Old Birds could "spawn" but they would never activate btw^^

zinc flower
#

Yeah I had that

vagrant nacelle
#

Ohh

#

Well maybe that was it

tough path
#

@distant flame soundapi goes crazy on the debug logs my lord

tough path
#

this hotbar mod too omg

zinc flower
#

Which one?

#

Xu's?

tough path
zinc flower
floral rock
tough path
#

yeah lethalthings is broken

#

i dont have access to fix that one

zinc flower
#

I took out LethalThings, and they still wouldn't spawn though