BananaPuncher714 / LethalQuantities

A lethal company mod
MIT License
5 stars 1 forks source link

Question about modded enemies #62

Open TheRealMrKam opened 7 months ago

TheRealMrKam commented 7 months ago

Hello, i noticed that some modded enemies can't be spawned with LQ sometimes(they do appear on LQ configs but don't spawn), for exemple "the fiend" can be spawned inside but not outside, same for the shrimp. The shy guy can't be spawned at all. So i wanted to ask is there a reason for that ?

(I tried to spawn they with something like dancetools and it works fine)

BananaPuncher714 commented 7 months ago

LQ only adds the enemy to the level's list of spawnable enemies, while it is up to the level itself to spawn them in. DanceTools grabs the enemy prefab and directly creates it in the moon. I don't know why the fiend and shrimp cannot be spawned outside though, that is something I would need to look into their code to see why.

As for the shy guy, this is sort of how they set their spawn rarity, etc. They set the shy guy's spawn rarity just before the level begins spawning enemies, which is much after LQ sets the enemies. I can't change this without adding specific code to disable their mod, so it is not something I'm going to do. I assume that they set it this way so it would be able to spawn on all moons. Ideally, they would add a config option to disable their spawning modifications, but without disabling the mod entirely.

TheRealMrKam commented 7 months ago

Ok thank you for the details, i'll ask the Shyguy's modder about that !

There is also the new ghost harpist that has the same problem as the fiend

BananaPuncher714 commented 7 months ago

I did manage to spawn the ghost harpist outside: image and I also happened to get jumpscared by the fiend inside the ship: image which was quite unsettling, because I did not expect it to spawn. That being said, I boosted the rarity up so that it was the only outside enemy, and changed the outside spawn amount curve to 0: 50.

TheRealMrKam commented 7 months ago

For the Harpist maybe the last version fixed it haven't tried yet with that one.

So do you think the fiend numbers were too low(like negative numbers ?) to spawn it without the 50 on the spawncurve ?

BananaPuncher714 commented 7 months ago

It could be the case. I am still not entirely sure of how the time calculations and are done for the game spawning enemies, so whenever I need to test if something can actually spawn, I boost the spawn curve and max power count incredibly high to guarantee something spawning almost as soon as the game starts. The vanilla spawn curves are really quite low for modded gameplay, especially with how many new enemies have been introduced, and items.

TheRealMrKam commented 7 months ago

Yeah this is the spawncurve i use for daytime 0:9, 0.18:9, 0.19:0, 1:-15 but 9 wasn't enought to spawn him at all i tried multiple times (his personal curve is 0:1, 1:1).

Thank you, i'll try boosting his curve more but will be hard to find the sweet spot where he is on the same weight as the other monsters.

TheRealMrKam commented 7 months ago

Well haven't succeded in spawning the fiend or the ghost even with you method, must have some other mod blocking that... tried multiple versions to be sure too.

edit : found out for this one that the preset i downloaded from the webui reseted infernis at default "Also tried with all other monsters at 0, and something wierd happened, default mobs started spawning while at 0 in config, i'm kinda lost rn ! "

BananaPuncher714 commented 7 months ago

If the UseLegacy option in the global advanced config is enabled, then the exported presets will always be reset to whatever is in the configs. If it's false, but overwriting existing presets, then that's definitely a bug.

I'm not sure why the enemy still spawns with a rarity of 0, but if you don't want them to spawn, you can just remove them from the list entirely.

BananaPuncher714 commented 7 months ago

It is also entirely possible that another mod is partially changing whatever LethalQuantities had set. LethalQuantities runs before most other mods(in the case of something like events) so if another mod is adding/removing spawning entries then that could be an issue.

TheRealMrKam commented 7 months ago

Yeah i didn't use UseLegacy option so it was not a bug and definitly that.

It is also entirely possible that another mod is partially changing whatever LethalQuantities had set. LethalQuantities runs before most other mods(in the case of something like events) so if another mod is adding/removing spawning entries then that could be an issue.

I use BCM but i didn't use it on my testings so i don't really see what could be happening here.

BananaPuncher714 commented 7 months ago

Do you have a profile code or modlist which I can use to test/reproduce this bug?

TheRealMrKam commented 7 months ago

Sure ! Mods.log

Sorry that i don't have a code would be way easier but i don't use a mod manager.

BananaPuncher714 commented 7 months ago

When you were testing your mods, were there any errors in the console? They might not have to be related to LethalQuantities, but may contain a message like System.FormatException: Input string was not in a correct format.

TheRealMrKam commented 7 months ago

I'm not sure, it'll do it again edit this message and send you the logs !

edit:

This is for the fiend with old LQ pre-WebUi : LogOutput.log

Ok so i do have a bug with the UseLegacy : LogOutput.log

BananaPuncher714 commented 7 months ago

Right, this problem will be fixed in the next update. It is related to #64 where if your locale uses commas instead of periods as a decimal separator, it can't parse the AnimationCurve properly.

TheRealMrKam commented 7 months ago

Ok ! so i'll keep using my old version for now, but then i don't know if the fiend will spawn when i'll swap to WebUi since he doesn't spawn in old version either

BananaPuncher714 commented 7 months ago

I've done some repeated testing, and despite the fiend being added to the spawn list, it does not seem to spawn consistently, unlike other modded enemies. This seems to be more or less a problem with how they implemented it, and I'm not sure that it works outside properly either, since when it did spawn, it was bugged because it was unable to find a door.

Edit: Of course, with a high enough rarity(9999), it seemed to spawn consistently.

TheRealMrKam commented 7 months ago

The fiend dev stopped working on it and is kinda unfinished, there is bugs also and they are not being fixed so i don't think the spawn problem will change sadly :/

Thank you for your time and the testing !