#[EXPERIMENTAL] Lethal Intelligence + MaskedInvisFix
1 messages · Page 2 of 1
the error has to do something with the flies that spawn on dead bodies, as they are being spawned on masked while they are still alive. Unfortunately, the config doesn't work, and so, you can't disable this feature.
I just disabled it in cfg and was searching for mimics to check it
cant find destination i beleive, something im working on xD
in piggys code, it set a destination and ddint check the path, im changing it so if it cannot route to where it wants to go, it changes what is wants to do.
Fair
btw i dont know what checks you are referring to btw
Probably almost any tbh
it seems that the masked enemy crouching/emoting is not synced
i had a masked dance on my screen but he was crouching for my friend
and it also seems that masked enemies get stuck on terminal while in company building
there is no nav mesh in the company building by default.. so i cant really say the mod supports the company building XD
i have the navmeshincompany mod
ill add it to the list of known issues, currently re-writing a lot of the code (137 changes, removed 225 lines, added 589 lines, still more to do :() relating to how the masked select what they do, once ive done that.. i will look at those issues. 🙂
good luck with the rewrite
i have a question
not related to the mod
why does everyone who joined discord early, (before 2020) have extremely small bios??
well, as i said, there isnt really support for the company, maybe after the re-write there is.
if its a "terminal using" masked, its logic tells it to go to the front entrance after using the terminal... the company moon has no front entrance.
for the re-write.. im basically giving them something extra than a personality.. im giving them a focus.
focus terminal = go to terminal
focus breakerbox = go to breaker box
focus items = go for valid items
will add more as i go on (thats how im re-writing cunning)
and if something "isnt reachable".. then it goes "i cant do that" and selects something else.
so, i hope that will fix the routing issues where they just stand still doing nothing juddering along.
because discord wasnt what it is now?
back when i joined discord, discord was a place you add your friends for playing games.. so i guess your friends knew who you are, you didnt need to say much.
my profile was actually edited since 2020, but once again, i put what i put for a reason, not to describe a lot, and so its short, i want people to read the little i have wrote... I even forgot it said that xD
thanks, i had a tired moment last night where i went to undo one change.. and everything i changed vanished... i almost had a heart attack, then realised i had it saved already.. xD
Has there been work done on deceiving?
or like, a general theme? Have a suggestion for it but don't know if there's a direction already set for its development
i did a fix on "picking up items" and when deceiving uses the terminal now, they actually do something. Deceiving was seemingly completely broken in MaskedAIRevamp, or at least it was based off the code i started work on xD
Deceiving isnt complete id say.. but he has a rough "trajectory".
your welcome to suggest stuff
I was thinking since cunning likes using the terminal alot, and so will the insane I assume, the deceiving AI would act more like a working scavenger. It would go around and lurk around loot rooms or the entrance and ignore the player.
Normally Masked stare at you, but the deceiving would be minding its own buisness and require you to stare at it instead for it to become aggressive
Could have a similar "aggression" or agitation meter based off the bracken's that triggers its kill mode. Of course it raises on its own naturally by just being around players, but it'll rise MUCH quicker if players are actively looking at it.
ill look at it, not seen that one before xD
i played with my friends 2 hours ago again on the newest released version and they indeed seem to always crouch (even when walking).. everytime we encountered a masked it was just crouching
i didnt even know ppl cared about bios tbh
ive never had one and never really cared about it either
Pinned post?
already ignores the player, so does cunning to be fair, havent reworked "attacking" the player back into cunning yet as getting the semi-scripted logic working for them has been a pain, then re-writing everything on top xD
but yeah, deceiving already ignores the player, also uses the terminal
meant to reduce the terminal time of all masked.. but, now ive done the re-write, what i can do is try to get it so if ONE masked is using something.. it tells all other masked its in use, so they dont queue up.
because how the rewritten code works so far is..
masked randomly picks a focus... for example.. "terminal".. they then "use the terminal", it then forces them to change focus.. and doesnt allow them to use the terminal again for their next focus... so then they have to choose another focus.. likewise.. if they are supposed to only use the terminal once.. i tell them "no more terminal".. so they never can focus terminal again..
so i can hopefully apply the same to other masked so only one tries to use the terminal/etc at a time, because it is really silly 😄
and when their personality runs out of focus.. they resort to "no focus", which will mean they do basic actions (like running around, looking for players to kill, picking up and moving random items, etc, so they are not just standing idle, or doing the same things as each other)
and i guess the aim is (based off what ive done with cunning) for each personality to have 3 focuses, which lasts most of the day, if not all, so unless they spawn right at the start of the round.. 3 focuses will hopefully last them until they die.. and then a bit of basic mask isnt the end of the world.
#1240985198485573743 message @patent swift hey there. what can you tell me about this?
? the post isnt pinned, i beleive they are suggesting it should be.
I was referring to this message @patent swift
oh it didnt show me that message when i clicked.
Yea discord is sometimes funny like that. You have to click it several times. This always works for me
in v0.0.7 i removed a lot of logic that forced the masked to crouch for no reason...
in v.0.0.8 im doing a massive rewrite.. removing some logic. and fixing all logic as much as possible.
from what ive seen in 0.0.7.. masked RUN more than CROUCH.
in 0.0.8, im going to have to put limits on running, because they are basically burning their stamina 24/7, and i feel they need to use their stamina when they are "close" to their target.
but yeah.. if i see something telling them to crouch, when really they shouldent, ill be removing it, the main thing before was tbagging. i forget if that occurs still in 0.0.7, but if i find more, ill be fixing it.. imho.. only "decieiving" should be crouching a lot.. and that should be around DOGS, but that will come in 0.0.8
oh and stealthy should probably be crouchmaster.. xD
i was thinking stealthy should be able to fast crouch walk imho.. because he is "stealthy".
for us in v.0.0.7 they were just always crouching.. idk. maybe we were just lucky getting deceiving masks all the time.
well it depends on what they were doing as its certain actions leading to crouching.
picking up items, they always seemed to crouch and stay crouched.. this will be fixed after the re-write for sure as they now crouch, pick the item, then stand up.
in some areas of the code.. they would start tbagging, and then stay crouched.. ive currently disabled this code.
im not sure if they were fixed in 0.0.7, or if i only fixed them since i started the re-write, but it should be fixed after the re-write, or at least, lessened.
the biggest issue im facing right now is in relation to picking up and dropping items, sometimes they dont want to pick up items, sometimes they dont want to drop them, makes no sense, im sure ill get a handle on it.. but it all stems from me re-writing it so ill just have to take the time and grin and bear it xD
but once the items issue is re-sorted, i can add the "focusing" for the other personalities, as well as sorting out what happens when "no focus" exists, fix the bugs reported.. and of course.. stop them crouching at random times (if that still occurs) and put a limit on their running 🙂
not a clue, once the rewrite is done, ill look at that xD almost done with the re-write, so will be uploading an update within the next 4 days, then we can see if it still happens, but i will try to fix the "two masked doing the same thing" issue as part of the re-write, i think im just going to set a global variable for the masked, so other masked can see that value.. and so ignore the terminal.
edit: i did write 2 days, but forgot im busy for the next 2 days after today xD
Yeah they do love camping terminals
Good luck with the rewrite!
My antivirus just deleted LethalIntelligence.dll when I launched the game (with R2Modman), saying it was infected by a malware named Gen:Heur.Bodegun.1
I don't know if it's a false positive or not, but I prefer to warn in case the file uploaded on thunderstore and maybe even your computer is infected @patent swift
False positive.
VirusTLNR.LethalIntelligence = positive in some virus scans
VrusTLNR.LethalIntelligence = negative in all virus scans
So yeah.. imho, its a sign of a dumb antivirus.. but bitdefender (an antivirus I kinda respect) also does this false positive. -.-
In 0.0.8 I'll be changing it as its an internal hardcoded value which represents the mod, my apologies for using this name for 12 years xD
Thanks, in 2 days when I can resume doing it, I think I will need the luck as currently I have them stuck at the main entrance.
I'm really hoping the changes I am making leads to what I'd like to consider "constant movement" so they aren't just hiding (unless stealthy) and they appear everywhere.
oh, I see, the antivirus provided by my ISP happens to be a variant of bitdefender
Fair, I just can't believe in this day and age the word "Virus" is picked up as a virus lol, but yeah , I will see what's exactly causing it and fix it in 0.0.8 either way, I was hoping before it was an isolated case (it's only been reported since 0.0.7) but seem its more widespread.
#1200695291972685926 message
Does this mean cunning can steal from the ship, or is it just outside of it?
So in the mod, it looks at all grabbable items.
For cunning, it looks at all items within 15 float distance of the terminal (or something like that), so he is specifically only going to take "your items", then hide them in a Bush outside the ship.
This has always been how cunning was supposed to work in MAIR.. but before 0.0.7 in this mod they were looking at all items, which I found led to them bringing items to the ship, then stealing the same item, defeating the point.
I did originally set it to just look at all items in the ship (and I may redo this).. but when I tested, if you brought an item to the ship on "this landing", it didn't seem to count as "in the ship".
And all items around the ship will be moved there by players anyway (ignores bee hives, the sigurd post it note and the clip board)
For Deceiving it looks at all items 30+ float distance away from the terminal (I think)...
In both cases.. they ignore the same items (for bugs and because they are worthless).. plus all masked will ignore the loot hidden by other masked (or at least that's how its supposed to be but I do need to test that)
Imagine not getting your results from doctor online due to system thinking "virus" is virus
Or some other stuff like that lol
I bet not a single actual virus has Virus in it's name or signature or anything like that tho
Haha, well to be fair though, it's the assembly name, and I'm the virus being positive used the word virus in its randomised name. Kinda perfect camouflage. The virus that hid in plain sight.
Fair but you get my point
Totally.. ngl I should sue antivirus companies, they want to delete me 😦
I mean u can try for fun
For fun xD you mean like a millionaire hands out bands of $1000 to random strangers who make them laugh.. cause that would sure be some expensive fun 😄 and I'd lose I'm sure.
Discord didn't ping me, but thanks for clarifying.
Didn't use masked ai revamp so was unaware
I mean i bet you aren't the only one
Maybe call it AntiVirusTLNR for fun?
No worries, as I said, I've tweaked how it works, I do aim to explain details, but frankly, I've used masked ai revamp for months, it's only now I'm doing the rewrite that I understand how it all works, or most of it 🙂 so hopefully now I can do a write up on things like that.
Also btw
In my mod packthere is apparently one single type of mimics that do be causing more lags than i would want to
Is there a way to check which type of mimic is being spawned?
Yes, check the text log, it will tell you which masked spawned, just search for "personality", it should tell you the masked I'd, and the personality.
Every time the personality changes (which right now is only when they spawn) it will provide a similar line.
If you give me a minute I'll find the exact debug line.
I'm searching one sec
I do plan to make it info going forward as I have a new debug line which gives a full status on the masked, and the personality is important.
this is the line you are looking for
"Masked '" + maskedId + "' personality changed to '" + maskedPersonality.ToString() + "'
so it will say for example
Masked '-3467364' personality changed to 'Cunning'
Mhm
I see
I ain't having no logs atm cuz i already have them replaced with the ones without lethal intelligence, damn xd
yeah, no worries about having no logs, happens to me too xD, in my re-write, with "debug mode" turned on, its like this.. and should show in the console too, will make life easier for you guys to tell me whats going to poo, and for me, because ill get the information i need to solve it 🙂
`[Error :LethalIntelligence] [!!!NOT AN ERROR!!!] Masked '-174956' personality changed to 'Cunning' (shown in red to be easily seen)
[Debug :LethalIntelligence]
===== MaskedStatusReport() Start =====
MaskedID = -174956
MaskedPersonality = Cunning
MaskedFocus = None
MaskedActivity (Focus=None) = None
isDead = False
isOutside = True
isInsidePlayerShip = False
MaskedGoal = selecting new personality
noMoreTerminal = False
TerminalReachable = True
noMoreBreakerBox = False
BreakerBoxReachable = True
breakerBox.isPowerOn = True
noMoreItems = False
nearestGrabbableReachable = False
nearestGrabbable = null
heldGrabbable = null
===== MaskedStatusReport() End =======
`
? You said my mod was disabled lol, if you have it running you will get the first line, the rest is new.. not in the version on thunderstorm, sorry if I confused
I got it in these logs
Yeah, so now you just need to know which is theone active when you had the lag.
Feels weird tho
It showed slight lag after spawning third and severe one after spawning last mimic
What did the masked at the time do? Did they go to the ship? If so, what did they do in the ship?
Yet apparently the both are repeated already
Just their existance kinda caused it
Also yeah, i am using version from thunderstore
yeah, so wont have the status report i just sent.
well.. afaik, the update interval is instant.. probably why, but MaskedAIRevamp was always like that, my computer drops 20fps just because MaskedAIRevamp was running, no masked even spawned, so its probably the sheer amount of masked you have in the game.. i will try to lessen how often the AI update, but, i have no clue on the effect that may cause until i try to change the situation, i will probably have to redo all my timings on everything, because they dont run on "time", i beleive they run on "update count". (or well i guess thats ticks)
github version is thunderstore version.
Ah fair xd
I have relatively good pc and yet it sometimes does frames for me but only from some Specific mimic
So for example i spawned 3 and started experiencing lag and until i kill that 3rd one - lag won't disappear
THat's why i thought it's related to mimic personality
i dont push updates to github master branch unless its going on thunderstore... the re-write is only on my local pc rn xD i want to push it to github.. BUT.. frankly, i did put it on a branch, tried to move it back and almost wiped everything.. so as im almost finished, i cba to put it on a branch xD
r7 7700, 32gb 6400 cl30, rtx3060
your pc is better than mine, sometimes I also get lag.. but its rare... so i think its the sheer amount of masked spawning.
So i am scared to put it into my mod pack as my friends will have really bad time on their pc if it lags even on mine
mine is 9350KF, 32gb, with a GTX 1660 super... really old rig
Yeaah
but yeah, i think you will find its the amount of masked, like
Well.. Not sure about if it's just due to sheer amount since as I said if i get unlucky just third one can do this
On the other hand - i have a lot of other mods
lets say you play with 6 people.
if 2 masked spawn.. its "fine", but if people start dying, and becoming masked, you suddenly could have 4-6 masked.. then its putting a strain
4-6 masked is relatively normal situation tho
yeah but maybe even 3 is too much xD i d k, it would be the same with masked AI revamp
Hmm
when i play and test solo.. ive spawned 3/4 masked, no real lag.. so its hard for me to know
Lemme try spawn and kill them then?
yeah, if you got imperium.. try spawn 1, then another, then another, til you lag.. i dontthink you will lag.
i think its the RPCS going to clients, thats making the lag.. constant updating being sent to clients.
that's kinda what i do rn
But not from imperium tbh
I am using cheat menu as it had some other additional convenient features
And i did "catch" this weird moment
Only one mimic exists
But it is the laggy one
and its in a wall?
on sewer, ive gone into a room and been locked in.. because of an invisible wall that closed it off.
so sewer may just be broken
THen picked up lamp and now chilling in the corner
ok...because i dont know the personality.. i cant help... BUT... i can give insight.
But fps ain't happy seeing him t all
they grabbed a lamp.. if DECEIVING they should be going to the ship.. was that door locked?
ah that old chesnut 🙂
But he could not open it still
Which is odd
He went to exit but didn't help the fps after he left there
".unlockarmsfromcamera".. dont know what causes it... havent seen it in a while
He seem stuck xd
yeah the low fps = because its constantly going "what should i do".
yeah.. that may just be sewer period
Well
try sewer, without my mod, do they move normally?
ok..
I only had stamina and esp
try again, use imperium, set invisble, muted and make sure you cant be locked in position (means you cant use ladders), put yourself in that scenario again.
it maybe that the masked stopped moving.. because it was looking at you.
Actually not the first time i see this type of behaviour - can't exit while i'm inside
Only if i'm outside
cause in all instances, except the main entrance.. he was staring at you
Yeah he was, idk why he stopped
because your there.
well.. this is all "old logic".. so probably broken stuff ive not fixed...
giosuel.
but yeah, ngl, all of my testing, unless im testing their reactions to ME, is invisble/muted
because otherwise the player, influences what they do, which, in old logic.. is a mixed bag.. in the re-write, i need to work on that still, once the masked are doing as they are told.. i can set what misbehaving they can do when they see players, etc xD
How do i use imperium
erm, i cant sadly, i shouldent even be sat here now.. in 15 mins i have to go out, then im busy until tomorrow night. 😄
f1 = settings
f2 = spawn menu
thats the basics.
One message removed from a suspended account.
f-ing hell i killed myself with K when typing spawn masked
And f1 is for control company xd
i traumatise people daily.. so thats just normal process.
true, but control company isnt needed, its similar.
That was an accident i forgot to turn off
thats fair, was just saying can turn things like that off xD
anyway, gtg!
Now that just run around this place lol
Ain't far from the exit but lol
Also not really laggy either somehow
And one dude chilling on the side lol
So it's either stuck in there, going back and forth out of and into facility or that dude stuck alone with engine xd
They don't try to get to ship really, they just get back inside lol
One dude coming almost to the ladder on titan at most and that's it
Funny lil fellas
busted logic 😉 what my re-write aims to fix.
Amazing, spawing 50-100(not sure how much) obviously caused lag but spawning about 10-20 here wasn't as problematic as that one broken lil fella
Maybe some other mods may cause issues?
Might do. The only way to know is mods in isolation vs mods combined.
How many mods?
I wish thunder store had folders for mods in there so i could separate some stuff
Like libraries, sounds, monsters, maps etc yk
139
Dang
I mean... Like... 15 of them are different optimizations
Anotehr few are fixes for ai
NiceChat, some stuff for UI, terminal yk how it goes
Sounds(LethalResonance mostly)
That's why it would be nice to have folders that you could copy into other mod packs
Just copy "QoL" and be happy with this part of stuff, then "Optimization" but instead kinda gotta do it as separate modpacks(mods that are dependant on these)
Also relatively a lot of just libraries that are used by other stuff
Three is the first start to look at.. things that do similar things.
You can.
I have an uploaded modpavk for qol, an uploaded modpack for vanilla+, one for light mods, one for masked tweaks etc.
So I can easily install a set of mods, usually though my group just plays with all the mods (122) so haven't updated them in ages. Lol
Mainly these
Diversity may be
Other masked stuff is MEOF and mirage
Btw how to do it

Only one I don't use is nav mesh in company, but that's not really an ai mod, it just adds a map for ai to navigate in the company.
I also don't use diversity.
Same as making a mod, you just don't include any dll in your zip, and instead list "dependencies" in your manifest. If you don't know how to do that, either thunderstore or here should have an example of what's needed.. or you can download another modpack and use as an example to follow
huh
also idk if its in your scope of things but the masked have some noticeably louder footsteps
yeah, still issues with items exist, actually working on that right now in the re-write, will hopefully be fixed in 0.0.8, but thats caused by an item being "deleted" while the masked is trying to find an item. like a key being used which uses up the key.
id have to look at that.. but, afaik, the footstep sound isnt changed by the mod, it maybe something to look at though, but i dont like to tamper with mimicking players ;o
it may just be because the masked RUN a lot (at least i think they do now)
oh I don't believe it's caused by any specific mod I just believe that masked have louder footsteps than it should be
they also feel "too quick" to me, which is comical, because ive not changed that at all compared to before.
yeah, well if i can change it i will, but yeah, im not here to mimic players xD so if another mod did it id remove that so its not a priority.
@patent swift
I am out of the loop will this work with StarlancerAI and StarlancerEnemyEscape?
no reason why not afaik, i use StarlancerAIFix, but not enemy escape, dont see any problems arising from that per se.
I will do my best to break this mod for you! 😄
EnemyEscape doesn't touch Masked iirc
haha, my group likely dont want thumpers in the ship 😉 thats only reason why not. 😄
hahahaha.... do it. Teach them to use the terminal!
@patent swift
I keep getting this spammed
[03:23:31.4132745] [Error : Unity Log] NullReferenceException: Object reference not set to an instance of an object
Stack trace:
LethalIntelligence.Patches.MaskedAIRevamp.MaskedCunning () (at ./Patches/MaskedPatches.cs:2134)
LethalIntelligence.Patches.MaskedAIRevamp.Update () (at ./Patches/MaskedPatches.cs:578)
thats a new one... i can only assume the breaker box didnt exist or something? (as that line of code was checking the breaker box distance)
idk it was just getting spammed and I heard a masked but I could not find it
what interior were you playing on?
bunker
ah, does the bunker have a breaker box?, i feel like it doesnt, either way, if i havent done already, ill put a check in to see fi the breaker box exists, if it doesnt, ill make sure to solve the error that occurs 🙂
I don’t think so
well ive just tested in my re-write, and the issue does seem to be that the breaker box doesnt exist.. the error should stop popping up going forward.
Ok
what do you mean the silliest items?
in my rewrite for v0.0.8 they were picking up 2 items at once and dropping one, ive fixed that.. i hope... but yeah, led to them holding 15 items at once.
so.. going to be honest... this has taken me a LONG time, ive had a lot of delays.. and issues... I think its ready, but being honest, some things may just break 😄 and for that reason, i genuinely have a knot in my stomach, because I dont like releasing things unless they work! 🙂
but uh yeah.. i truly hope my worry is for nothing, and i truly hope this fixes a lot of issues and causes none! if you do have an issue, or want to help debug, turn on "debug mode" in the config.. (its defaulted to off because of log spam..).. it defaults to a status update rate of 100... lower = better for debugging, but may cause fps drops, put as high as you need, as even 1 status report should help :))
https://thunderstore.io/c/lethal-company/p/VirusTLNR/LethalIntelligenceExperimental/
Experimental v0.0.8 - Masked AI Revamp Coding Re-Write patch
-Rewritten a big chunk of the Masked AI Revamp original code, we have gone from "Personalities" only, to include "Focuses" and when there is no focus.. "Activities"
-Potentially added integration with Wendigos_Voice_Cloning by Tim_Shaw (please do test and let me know how it goes :))
-Removed some code branches which I could not fit into the new code logic branches of Personality/Focus/Activity.
-Fixed masked loving to linger at the main entrance, they should now "reposition" themselves between the MainEntrance, The ShipLocker and the BreakerBox.. I plan to add the "Apparatus" and the "FireExits" as other options in the future.
-Potentially fixed a bug where more than 1 masked will use the terminal.
-Masked now have a random chance to change focus to a nearby detected player (depends on the personality what the chance is, from something like 20% to near 100%)
-Fixed an issue where the mod would flag up as a virus on some Anti-Virus scanners due to having the word "Virus" in the AssemblyName.
how to see personality in logs:
[Info :LethalIntelligence] Masked '-201902' personality changed to 'Aggressive'
1 full status report, i would most likely want to see this if possible (if debug mode is on):
`===== MaskedStatusReport() Start =====
MaskedID = -201902
MaskedPersonality = Aggressive
MaskedFocus = Player
MustChangeFocus = False
MaskedActivity (Focus=None) = RandomPlayer
MustChangeActivity = True
Moon = 41 Experimentation
Interior = Level1Flow
isDead = False
isOutside = True
isInsidePlayerShip = False
heldGrabbable = null
MaskedGoal = trying to be aggressive...
noMoreBreakerBox = False
noMoreTerminal = False
noMoreItems = False
notGrabClosestItem = False
===== MaskedStatusReport() End =======`
if you changed the mod guid, do you know how thunderstore and any mods using it as dependencies will react?
I didnt. 🙂
sounds like a solid release though
hopefully it doesn't cause too much of an issue
if this is always being logged, this might cause performance issues? what's its frequency?
previously..
AssemblyName = VirusTLNR.LethalIntelligence
ModGUID = AssemblyName
now...
AssemblyName = LethalIntelligence
Authors = VirusTLNR
ModGUID = Authors.AssemblyName
so its identical afaik.
oh this fixes it?
its not always being logged.
personality is set just after spawning, once set, its never set again, it only sends that WHEN its changed... so it sends 1 time per masked.
yeah xD its so dumb.. its just "Virus" in "AssemblyName" = antivirus go brrrrrrr
i basically.. just copied the bepinex props thing... to make my own plugininfo class.. so i could use "Authors" instead of AssemblyName for the VirusTLNR bit.
but yeah, going back to "log spam".
the status reports can be delayed to whatever any slow speed people want by increasing the number.. but they only send to logs either way, if there is a change..
so if its the same 50 times, it doesnt do anything.
the "slower speed" just means, it checks the change less often.
I'd like to test this when It's on a "stable" version with my friends!
well i can only report as "stable"ish once ive played with my friends too, sadly, i only get to do that at weekends, from my testing it works, but, the problem with this (and masked AI revamp before too im sure) is.. not every scenario is going to be covered, there will always be issues to iron out.
unless ive made a MASSIVE screw up.. (which is possible), it shouldent be "broken", except an issue with items.. for some reason, items sometimes bug out.. i gave up on "fixing" items further, because i got it to a "normal" state.. but, the part that was bugging out, was not related to what ive changed.. it was i think related to people picking up items while the masked were working out which items they can take.
the only other issue ive come accross is due to the breaker box being in stupid places it shouldent be... which leads to the masked not understanding how to route there, or for example , being on the wrong side of a thin wall.. lol.
yo are you gonna add like more config options
just had an interesting thought... not sure what enemies id put this on if it was possible.. but.. a "personality" of an enemy.. that was "chameleon"...it would basically.. just try to hide somewhere... and if a player walked by and didnt look at them.. it would try to kill them.. and while its not moving... it would be very invisible.. and "standing/leaning" against a wall (think like Metal Gear Solid style...?)
not sure if that would be gimmicky.. or truly terrifiying... maybe a variant forthe bracken? doesnt chase you, but hides in plain site waiting to ambush you...? i d k.
config for what?
turning off individual personalities will not be a setting any time soon, if ever.
is there a reason for this?
Just simple configuration fatigue (in the sense that I don't want to have people looking at the configuration and being overwhelmed by having too many settings.) And in the sense that I can't do it right now.. I'd have to rework the personality system selection process before doing that.
Currently it accesses the enumerator and pulls out a personality based off random number.
I'd have to find out which is wanted in settings, remove the ones that aren't, put them into a new list, and use a random number on that list... which is fine, but having to do that.. plus the fact I don't want there to be an overwhelming configuration list.. just makes it not a priority for me. If people really want it, I'll do it.. but.. when we have 10.monsters, each with 5 personalities, and each with 5 features that are a bit over the top... that's 100 settings to turn on/off depending on preference.
So yeah, I was just planning to add configuration for the more extreme stuff, like there is already for pulling the ship lever, using the terminal, etc.
fair enough I guess, people like control though (even when they shouldn't have it lol)
control company
well yes but wasn't referring to that lol
I noticed, but, it's all about how much control is feasible.
The games I used to play, I'd set up config for my group for the 2 hours before we played, 2 hours configuration, for 2 hours game play.
Once I've added fire exits and apparatus as "activities", I may just add in personality configuration for now.. and later once settings become too many, I can always get rid of that configuration settings.
to be clear, I wasn't asking for the configs myself; rather just trying to get insight on your mindset
So Author virus is fine but AssemblyName u go blasted?
No I understand, I just tend to be like "no I won't be doing that" then think about what I could or would do.
Yes, exactly, I tried changing everything except the assembly name.. and it still flagged as a virus, now it does not.
Amazing
Even better than before xd
Can't wait for a game about a virus...which gets deleted by antiviruses.. so dumb xD
Just wanted to confirm that the last fix of this changelist is indeed working as expected, thanks!
i know it does, scanned it on www.virustotal.com xD thanks for confirming though!
Plague Inc be crying
probably why they called themselves Plague Inc tbh, Virus = easier to say than Plague from my pov
I mean
It ain't about Viruses, Virus is just one of scenarios
no i know xD ive played it
Figures
no 😦
you were right with figures, just yeah, its not cause im virus
So, a very sad update (for me at least).. my motherboard seems to have died, getting a replacement, but that will apparently be a week (as its a really old mobo they are hard to find :() so I won't be able to work on anything for at least a week.. luckily I got the rewrite done before this happened lol.
How are people finding v0.0.8 btw? Hopefully no bugs?
Short question, i wanted to try this mod again after the rewrite, added it to my modpack today, but for some reason it only spams this error once a masked spawns:
Stack trace:
LethalIntelligence.Patches.MaskedAIRevamp.<setNearestGrabbable>b__146_1 (GrabbableObject item) (at ./Patches/MaskedPatches.cs:1229)
System.Collections.Generic.List`1[T].FindAll (System.Predicate`1[T] match) (at <787acc3c9a4c471ba7d971300105af24>:IL_0013)
LethalIntelligence.Patches.MaskedAIRevamp.setNearestGrabbable () (at ./Patches/MaskedPatches.cs:1229)
LethalIntelligence.Patches.MaskedAIRevamp.CalculatingVariables () (at ./Patches/MaskedPatches.cs:686)
LethalIntelligence.Patches.MaskedAIRevamp.Update () (at ./Patches/MaskedPatches.cs:991)
[13:13:59.0158801] [Error : Unity Log] NullReferenceException
Stack trace:
LethalIntelligence.Patches.MaskedAIRevamp.<setNearestGrabbable>b__146_1 (GrabbableObject item) (at ./Patches/MaskedPatches.cs:1229)
System.Collections.Generic.List`1[T].FindAll (System.Predicate`1[T] match) (at <787acc3c9a4c471ba7d971300105af24>:IL_0013)
LethalIntelligence.Patches.MaskedAIRevamp.setNearestGrabbable () (at ./Patches/MaskedPatches.cs:1229)
LethalIntelligence.Patches.MaskedAIRevamp.CalculatingVariables () (at ./Patches/MaskedPatches.cs:686)
LethalIntelligence.Patches.MaskedAIRevamp.Update () (at ./Patches/MaskedPatches.cs:991)```
And the Masked keeps going inside then outside then inside then outside, until it finds a target
I tried disabling General Improvements, Mirage, TooManyEmotes, since i thought their Masked features might conflict but the error still stays
Well, the issue with the masked running in/out is because of the error, its not about other mods.
Basically.. the item list being gathered from the game is causing an error. I thought that was fixed, but I guess not. When it occurs, at least the masked getting the error is breaking.. but maybe also all the masked are (haven't had a chance to check)
But yeah, if that's the error being spammed, it's an issue with the item list...
I got that issue after using a key while a mask was spawned...but I don't know what else causes it. As soon as I can I will focus on fixing that.
But yeah, when that error occurs, it's like the masked instantly break completely as this occurs right at the start, so everything else breaks afterwards :/
Aww, that's unfortunate :c , also i forgot to say i spawned them in with Imperium because i tend to test mods before actually playing with it does that make any difference?
I hate it when its a mobo issue cuz its one of the last things I'd check for 😭
Are you altering the items using imperium?
I also test with imperium.. with imperium installed you will get log spam (as "debug mode" is enabled by default.), but yeah, if your spawning in items.. that may break it.
If your spawning in a masked, it shouldn't be an issue.
Yeah, well, I blame valorant, updated my pc to Windows 11, suddenly valorant needed "secure boot", turned it on, and the stupid mobo is basically stuck on those settings for life, so isn't usable or fixable xD so dumb haha.
As far as i remember i just landed on Vow, teleported to entrance, went inside, spawned a masked and the errors startet appearing, just in case i will try it without imperium the next time i have time to test, just in case i somehow did accidentally do smtg wrong
i would provide the log when it occurs, the full log usually tells all, but afaik, the issue as i say is related to "keys", once you use a key, or "delete" an item, broken, but that was my experience, and i thought i fixed it
Finally got around to try it in a normal play session without Imperium, happened right after the Masked spawned
idea - bracken type:agression
it goes after EVERYTHING, and i mean that
lootbugs, thumpers, spiders, hell it'll rip a coilheads head off as a trophy!
when this type of bracken spawns, it brings all entity and player corpses created by itself to the bracken room, to display them as "trophies"
when you look at it, it wont retreat, but instead dart around a corner, being much more sneaky about its pursuit, hiding behind walls and sometimes lurking near exits if locked on a prey going towards one
OMG YES
WE NEED ENEMIES TO ATTACK EACH OTHER
LIKE REALLY
nutcracker attacks moving enemies
coil heads stop moving when in sight of other enemies
MASKED GET ATTACKED
BLOBS CONSUME all
it feels sooo weird that enemies just wont go after each other
sounds cool in theory, but i think what’ll happen is ur just gonna find dead monsters all over the dungeon interior without having seen what happened
so then there’ll be only little bit monsters alive to chase you
maybe make them only attack after a certain amount of time has passed?
or just liek a random chance for specific monsters
idk i just feel liek turrets should shoot everything, mines should explode everything, and nutcrackers should detect everything (and maybe some enemies go after masked)
in terms of hazards targeting enemies there’s already a configurable mod for it
FairAI
then nutcrackers and masked
its still sucks to have them trigger mines and turrets though because they’ll die before they see you
easier scrap collecting :)
so personally i configure it to allow them to take damage from mines and turrets but not trigger them
but it’s boring if it’s too easy
it’s fun seeing friends get chased by something
Oh that's not vanilla?
the bracken is hyper aggressive to counteract that however
i think they do take damage from explosions, but not stray turret bullets
oof gl with that replacement 🥺
ok well..
thats with a decieving and a cunning, apparantly the way i list the items they can pick up is causing an error for them, all other masked should be fine, until my pc fixed, i cant check what item is causing it, or fix it, so i can only apologise, all im doing in those lines is selecting all items that are either close to the ship or not close to the ship, or are a walkie talkie.., it maybe related to the "ships status" or something else, i will certainly have to check when im able xD
exactly. my group run mods to sell bodies, and make everything killable, sometimes we make more loot from killing things than looting, all it will mean is free loot xD but certain personalities of certain monsters, as long as they are not an "always" factor should be fine, but i think in most of those cases, the body should be forced to vanish, would actually make people going for "sell bodies" loot... kill things themselves quicker
first time for me tbh, so if i screw it up, ill have to pay for a new pc, id rather just fix my pc 😄 but at least its cheap practice for my next computer 😉 i normally pay someone to build mine because "motherboards are scary" ;D (im not delicate with my hands , so me breaking a motherboard by touching it wouldent shock me)
i just worry ill press too hard, or snap snmething off thats all ;o oinbe of my older pcs from 10ish years ago, i think when adding ram, i pressed too hard and broke that mobo, it didnt die, but rhe performance got worse some time period after, lol.. so yeah, just wary of touching mobos
aww that's unfortunate, i hope everything goes well with your motherboard replacement 🙏 ❤️
Man valorant getting worse and worse xd
They should be pretty resistant btw, and clipping ram (especially DDR5) does require some strength xd
Natural selection
I'm aware, just I'm also quite strong.. talking stronger than I realise strong, so, I can easily go from barely trying to snapping it in half knowing me, we shall see tomorrow 😉
so, back on my pc, will work on fixing the item list bug asap, probably within the next 2 days.
edit: and yes, this does mean i didnt snap my new motherboard in half, though i did break a locking piece for my CPU cooler 😄
its the turnable knob, the plasic broke off, cpu was hitting 100 degrees earlier, seem to have got it back to normal, but im hesitant to not have my pc laying on its side, lmao, i worry that it being on its side, it will "fall away" from the motherboard, i may have to switch the holders around (if thats even possible without breaking them more), so the ones at the top are the ones that are 100% secure, its only one broken really.
i dont intend to, just for now, it means i have a working pc, til i can get a new cooler xD
Fair
From not expensive good air coolers I think I can recommend peerless assassin 120
hmm, bloody internet.. i wrote a bit more, but it didnt send as apparantly my internet went down for 2 minutes xD
i was saying, my pc is really old, just hanging on to see what 15th gen intel is like, and 50 series nvidia too, then this pc can die a happy death as i will buy a new one anyway.
and tbh, i would just rebuy the same one, as frankly, i only got it like 6 months ago, and its done an amazing job.
re:- turning personalities off.
when the suggestion was made, i didnt really want this functionality to be a thing for various reasons, but as some people seem to want it, and ive since debated it in my mind about the benefits (turning off buggy personalities, mainly, from my pov) vs the negatives.. ive started work on it.. and think i have it working..
I just have a question..
Without the personalities, the "experience" would be more bland than vanilla, afaik.. so..
my initial test.. (tomorrow), will be.. when personalities are all turned off for a monster.. -> completely turn off all AI changes (ie, make them back like vanilla versions).
my question is... is that ok.. OR.. are people wanting the basic ai functionality features of my mod, without personality differences?
the reason i ask is, for the masked, at least currently.. i really think the "no-personality" route will just lead to masked walking around doing nothing in particular, so maybe better to head back to vanilla masked instead in that case.
so yeah, i just thought id ask, as id have to make further changes to make "no-personality" a thing as currently "no personality" makes the mod change the personality.
i have idea
is it possible to make a personality that is aggresive maxxed?
like, aggresive but the masked attacks everything
just doesn't care anymore
i could probably try adding that as a setting for "aggressive" itself, but id have to look into that, and see how it goes.
maybe like
once he is aggresive for a certain amount it's just like
"And then something just snapped. Something inside of me.. I didn't care anymore!"
and starts killing everything
nah, it would just be a setting.. "Aggressive attacks everything?", on = he attacks everything, off, he doesnt, hosts choice.
but i should add, i think for that, if thats a thing, then, other AI should react.. so maybe its something for when ive done a lot of different AIs.. maybe then, it should target AIs that ive worked on, so there is a reaction to the masked attacking them, not just sit there and die.
actualy
it would be so sick to see your 'team-mate' gunning down/beating to death a lootbug or thumper, and then boom they got a mask on and shoot/grab you (and if you have mask removing mods, it creates a lot of confusion and chaos which is awesommee)
that was my thought.
yeah it would be funny to be like "DUDE WTF! WHY DID YOU SHOOT ME??" and then your friend is like "that.. wasn't me 😳"
i guess, if "insane" was targetting a monster, he would have to magically find a shovel or something... so they dont just "death grab".. because then you would know they are a masked... and there wouldent really be a beat down.. or maybe insane should death grab, and aggressive should find a shovel then attack other things... hmm
they already have one, i just havent really worked on aggressive.
if there is a shotgun, its their #1 priority, after that, a shovel, or use a shovel to get a shotgun.
here's what i'm thinkin, list of priorities from least priority to greatest:
stop sign
shovel
yield sign
shotgun
modded weapon? (since they're sometimes real overpowered
it would have to be looked at, but tbh, im quite.. bored (well frustrated i guess because items are a pain :P).. of working with items xD, i will fix the bug with items atm.. but beyond that, my main goal right now, is to work on things that arent working.
namely..
FireEscape usage (i was close.. but lost all my progress thanks to my pc going poof)
Apparatus Pathing. (not started)
Insane Personality Features (has a lot to do still)
after that, i d k what im going to work on next, probably fixing more bugs with masked xD
already used by aggressive, most vanilla purchased weapons are.. except stun gun maybe.
FireEscape usage
ah yeah, they apparently can (?) but i've never seen 'em do it before
they cant, they dont know what a fire escape is.
lol,
the game registers the main entrance as an "entrance" for masked, the fire escapes are also entrances.. but not registered.
maybe just slap on the main entrance code and make it a bit less.. used? maybe make the main entrance a priority but the fire exit less so. but ofc still if they wanna they can use it
so i basically need to get a random list of fire escapes... and for each masked, make them choose 1 of the fire exits... and then.. they will use that, like a main entrance.. 😛 but yeah, gotta re-do all of that code.
also, un-related, but.. i just had a thought, what about their interaction with objects? specifically doors maybe make 'em stop for a second before opening them
oh also, maybe make them not instantly leave and enter so it's less sus when you see them leave or if you're following em
they do tend to stop at doors already, but i think thats just how long it takes them to open them.
yeah, maybe i just haven't noticed but i've only seen 'em just walk into the door and it opens
cuz all enemies auto-open doors when they collide with them
(i think)
xD
my code tells them to "go to the main entrance", it doesnt tell them to go inside, or outside. I dont actually know what controls that atm.. from my basic understanding... the masked walk to the "place", and they just teleport inside, but i havent looked into that code yet,i assume i willneed to do so for the fire exits.. xD
nah, i mean, whenever they exit or enter they instantly do so. making 'em stop for a moment to simulate how it takes a sec to get inside
ah, in my testing they seemed to walk up to the door, open it, then move through, no delay.. but they do "stop" for the door to open.
interesting...
no i know, i just dont know anything about how that works 🙂 but once ive done the fire escapes, i can fiddle with that.
yeah.
just overall polishing how they like.. interact with stuff, and how they go about their business should be polished a teeny bit
ofc, only after all the big stuff is finished
well going about their business, is what ive been working on with the re-write, but, i dont think the re-write's changes are being fully seen, because of the bug with items on cunning/deceiving, hopefully when i update after doing some testing, it will stop erroring and be completely fine.
but yeah, stopping them crouching, stopping them running everywhere, etc, those sorts of changes are things im trying to fix.
yeah
cant remember if ive already put it in the code.. but.. i was aiming to set it so..
if masked are FAR away from their target, they walk, if they are medium distance.. they can run... and if they are close to their target, they walk
so masked dont "sprint" at you at close range.. and they dont "sprint" to a target that is miles away, only when they are relatively close.
so, little questioon
do they have any like, triggers for emotes?
like, they emote when doing a behavior, or is it just in response to players emoting
deceiving will emote if they see a player emote.
i got a silly idea
for insane and aggresive
for aggresive:
random chance that when they see you, they'll point somewhere behind you, and once you look away they'll make a move to get you
for insane:
same thing, except when you look away they'll either make a move, or do smth else (cant think of anything lol). if they make a move to get you, if you turn around and they see you see them try to get you, they'll back away like "nah i wasn't doing anything"
maybe a lil silly laugh to cue when they make a move?
arrghh anyway
sorry to cut it off short but uhh
gn
(goodnight)
lmao, i was going to say the same, needed to sleep hours ago, just too happy to have my pc back working ;o
i wonder if the masked laughing can be used in this mod at all
when they spawn they laugh/cry like normal.
LethalIntelligenceExperimental v0.0.9
-
Added some basic background coding to help debug issues quicker while using Imperium. (for my benefit really).
-
Potentially fixed an issue with item log spam due to errors with the list when a masked spawns (usually due to items being "removed" from the game completely i think))
-
Made it so personalities can be turned on/off, if you turn off all personalities, the whole "Masked AI" functionality will automatically be disabled.
Note:- on the changelog on thunderstore, the bold bit is wrong, should say whole, says who, oops :/
Just tried the new update in a normal round, and this error seems to be spammed as soon as the Masked can't see me anymore, reproducible by being seen by a masked then closing the ship door. I think leaving by the fire exit and possibly even by main entrance caused it as well, but it's gone as soon as the Masked sees me again.
Also, for some reason, each Masked lowers my FPS significantly the first one lowered it from 144 FPS to 47 FPS
Stack trace:
LethalIntelligence.Patches.MaskedAIRevamp.MaskedAggressive () (at ./Patches/MaskedPatches.cs:2320)
LethalIntelligence.Patches.MaskedAIRevamp.Update () (at ./Patches/MaskedPatches.cs:1009)```
lower fps will be due to log spam i assume, im guessing fixing the items, allowed for this to occur.. SO.. suddenly we have an error.. wahoo.
line 2320....
if(Vector3.Distance(__instance.transform.position, pt.transform.position)<5f)
so the issue is.. it cant find the closes player.. so.. throws an error (because closest player is null) 🙂 bad coding on my part, didnt check if the closest player is null.. will fix this asap, thanks for letting me know.
actually, wait, the masked spawning = 144->47 ?
i may try to add to my masked status report.. the player FPS.. so i can check this truly xD
it might have something to do with the fact the game un-renders things outside the ship, if the doors are closed
closing ship doors im not sure about...
but fire exit/main entrance... is a different case.
when you use the main entrance/fire exit, you are effectivly "changing map", the masked afaik, cant track you when you change map.. they just by default.. are drawn to the main exit, so you go through, and they will follow by default because "main exit".
either way, the issue is, once the player is "lost", the target closest player = null = error.. so if i check if closest player = null, then, should be fine, although this probably leads to an issue where, the masked wont follow you through a fire exit 🙂 so i may have to fix that too (once fire exits are working properly.. currently have them teleporting through, but no audio.. and they keep going in/out super quick :D)
ahhh yeah
mhh, tried again but didn't seem to get that huge fps loss this time maybe only 5-10fps per masked tho i don't think i had a Agressive one, so... it's probably just the error messages
can see in logs which you had.
when the masked spawn, you will get a line like this.
[10:38:17.8900600] [Info :LethalIntelligence] Masked '-168408' personality changed to 'Cunning'
and uh yeah, 10-20 fps loss, sounds about right, i think its about the way in which the mod works.. for other monsters, i will be trying to do it a different way, because otherwise, every monster = -10 to 20 fps xD not good.
so, just tried to fix the issue you were having.. its not changing focus correctly (something i need to look at) but no error spam 😛 it just currently sets focus to none and moves on. so i guess i have a fix for it 🙂
I see that there's a 0.1.0 update
are you planning to add integration for mirage?
waiting on qwbarch
yeah i still have quite a bit to do before im ready to make an interface for virus to use
if we're talking about the walkie talkie integration at least
nicee
thats what i assumed was being questioned 🙂
Ok... I tried the 0.1.0 update
I still had the huge FPS decrease, but I think I found why. This FPS seems to happen when a Masked goes outside. I attached the log, just in case, and a video
https://medal.tv/de/games/lethal-company/clips/i4BeIT7p9bCaCTHRj/d1337lC48PcX?invite=cr-MSwyTmIsMjExOTUwODQ5LA
Tested a bit further, this time using Imperium. As long as a Masked is inside, the FPS is fine, but as soon as it goes outside, it drops a lot. I also made a video for that test: https://medal.tv/de/games/lethal-company/clips/i4C8rWApOhtfnMKr3/d1337OZkUxUi?invite=cr-MSw4cEssMjExOTUwODQ5LA
is there a way to set the maximum amount of masked that can spawn? around 8-12 my pc is hating me.
i think there are a bunch of mods that u can config enemy spawnrates with
if u got mirage of MEOF then they come with a built in config
for masked spawns
Found a setting in the MaskedEnemyOverhaulFork config! Thanks very much 😎
no problem
although, if you have mirage or any other enemy config mods, you need to set the spawn amount the same.
or else lke
thousands of maskes will spawn
i speak from experience
alright, will check it out. I think mirage didn't have a option for amount
just rarity
altho i don't know if this option in mirage will overwrite MaskedEnemyOverhaul setting
if you set 'em to the same amount, it should be fine
shouldn't right? SpawnChance and spawnAmount isn't the same
oh also, i suggest setting the spawn amount to just a little bit over your crew's size
like, 5 or 6
(if you're playin' with 4 people)
naah i think it's okay with 3. There can still be 4 masked if one player get possesed, so i think it's cool
aight
i just don't want my fps to be 3 lol
actually, yeah that sound reasonable
thanks for the info, i will have to look later at the log and see what maybe causing it then x.x
also, i use mirage with a cap of 2 masked spawning and i use vanilla spawn rates.. we usually get 3/4 masked max with people dying (group of 4)
forgot to mention, i had a look, and in the log both were aggressive, was that the imperium testing or the live game?
Oh, my bad that one above was the one without Imperium, if i remember correctly this should be the one with Imperium
thats cool, in the log you showed, all times, masked were deceiving, and were "outside" and "heading for the breakerbox", so its probably related to my issues of locating the breakerbox.. and the breaker box being in weird unaccessable places, i will have a look at it.. but if your saying it happens with other masked too, it maybe also when they "repostion" to the breaker box, as that likely suffers the same issue.
ok so replying to this (and this https://discordapp.com/channels/1168655651455639582/1240985198485573743/1251650135277178962)
umm.. i tried spawning multiple masked, 8 masked dropped the fps from 120 to 55, i then went outside, it dropped by 10fps.. so the change from in to out, is around 1.1 fps per masked on average, and its a drop of around 8fps per masked at spawning inside on average too (20 for the first, less as you have more or less as the fps drops)
imho though, 8 masked is an insane amount, and really.. if your running my mod, you probably would want 5 max (1 of each personality of masked).. i know for sure the dropship called in by masked cunning in the current code, cant be called in more than once.
also, i think really its always been an FPS drop thing in MaskedAIRevamp, its just the nature of the way its been originally, to which im still following that way of doing things.
so i dont think inside/outside matters much (aside from outside meaning your pc has to render a lot more..)
either way.. i will be updating the check for the breaker box and the pathing, so hopefully something isnt getting stuck there then causing some fps drop in future.
I don't mind an FPS drop of 10-20 for each masked, I usually have mirage set to 2 which should be fine, but that would still leave me with 60 FPS in the worst-case scenario, which is totally fine ❤️
By the way, the issue that the FPS dropped from 144 to 40/50 only appeard when a masked went outside the facility not when I went outside and the masked is still inside
Thank you for listening to my weird FPS problems with your mod. Honestly, I was starting to think that maybe my CPU, a Ryzen 5 5600X, is too slow or something like that.. Since I seem to be the only one experiencing such a huge FPS loss. x.x
That's a decent CPU, probably isn't what should be changed here
I can also jump in and say that i have noticed the huge fps drop for masked going outside and i'm using a Ryzen 5 7500F. But i have also a ridiculous amounts of mods
The huge fps drop seems to just happen to a specific personality of masked. I think atleast.
I tested by spawning around 8-12 masked on black mesa (big heavy mod moon). Each masked dropped the fps ofc, but when some masked when outside it didn't jump down drastically or more the usual, until one particular jumped outside
could also just be me overthinking that aspect
Also, i'm wondering one thing. I'm fine with playing on low fps because i'm old and used to 30fps of gaming. But my friends are like it optimized. If i'm the host, will it affect me more than others or will everyone see the slowdown?
cant say tbh, a lot of stuff comes from the host afaik, but some is client side.
ah i misunderstood, i figured you are outside, because you could see the masked is outside.
all i know is i tried and it was a minimial difference them going outside, so i really need to know what the masked are doing, when they go all laggy, as its probably "what" they are doing when they go outside, thats causing the lag.
also np, i want my mod to work great for everyone and fps drops make me sad, im also an old gamer, so i completely get you on that ;o
well that was the logic behind me adding my "debug status report", people can turn on debug mode, and then logs tell all the info needed, which personality, which focus, which activity, where they are, etc, so i know what the issue is because i know what part of code is running when it occurs 🙂
Alright! i will turn it on and check if i can recreate the issue again soon
I think you are onto something with the deceiving personality trying to find the breaker-box outside
Gotta say, you have made alot of great improvements compared to the OG maskedRevamp. Glad to see it!
probably, tbh, the way the "in/out" works is tacky, they walk "in", go "im inside, lets go to the breaker box", then instantly walk outside before "going to the breaker box".. i need to sort that out as it maybe part of the issue xD
thanks, but, i feel like its 1 step forward, 2 steps back, 3 steps forward, 2 more steps back half the time, i really want to get masked to a stable position so i can work on another AI
That sounds just like the struggle of life man
But i understand! I can't say so much cause i don't got alot of experience with development/coding. But it a really nice mod! Makes the mask alot more dynamic
but i can imagine that it's really complicated behind the scenes
atleast i don't got a bunch of masks hogging the terminal anymore 🫨
as soon as the outside fps drop is solved it's going to be on the main-pack again
===== MaskedStatusReport() Start =====
MaskedID = -228822
MaskedPersonality = Stealthy
MaskedFocus = Player
MustChangeFocus = False
MaskedActivity (Focus=None) = RandomPlayer
MustChangeActivity = False
Moon = 11 Twins
Interior = Level2Flow
isDead = False
isOutside = True
isInsidePlayerShip = False
heldGrabbable = null
MaskedGoal = trying to be stealthy...
noMoreBreakerBox = False
noMoreTerminal = False
noMoreItems = False
notGrabClosestItem = False
===== MaskedStatusReport() End =======
so wait, it was the stealthy mask who is in the video? i dont know what map that is xD i will look in depth at that tomorrow, but i dont know if my mod caused that or not.. some weird stuff going on today, a few mods updated since 2 days ago...
and today..
coil heads attacked me when they were being watched.. -> bug (not related to my mod)
coil heads also shoved me OUT of the interior into the void, i fell off the level... and glitched out the whole game
ghost girl was bugging out.. 2 people could see them at once.. only noticed it was bugging out after i looked at console.
so i feel like some mod has broken shit today... but i d k what.. if you were only using my mod though, then i guess i have something to investigate.
also, did you have some godmode enabled? or were they just not killing you?
well thats one thing ive done that i know works xD
the big problem im finding is.. a mask walking from A to B... its hard to know whats causing them to do that walk... so if i dont know whats driving them to do that.. i cant understand whats going wrong, but thats the purpose of the report.. it means any code in my mod can be diagnosed, the only problem beyond that is, the vanilla code still runs, and sometimes overrides the mod code, i will be patching vanilla methods more with other monsters, and maybe that will give me an insight into how to change the masked code to be done in a similar way.
hmm, your log highlighted something unrelated to me..
[22:37:14.0746394] [Info :TooManyEmotes-2.1.19] Calculating if the masked enemy (MaskedPlayerEnemy(Clone)) should emote: True
[22:37:14.0746394] [Info :TooManyEmotes-2.1.19] Pre-performing emote on MaskedEnemy. Delay: 0 ExtendedStopAndStareDuration: 0
this means toomanyemotes interferes with the masked, i may have to look at that very soon, incase its causing the issue x.x i dont use that mod so wasnt aware it makes masked emote.
so i assume you were seeable, killable... it maybe that they went to kill you... and they were also told to emote, and bugged out?
may also be my coding for that part sucks.. i do need to double check it.. xD
the logic checks out for me!
Awh man
as for complexity..
Activity.RandomPlayer makes the masked chase a player.. until..
1 - the player is dead
2 - they lose the player and x time passes.
so its nothing different from for example.. heading to the main entrance.. BUT... the fact you went inside to escape, may have caused the error actually.
it may have just been targetting you while you went inside, so when it tried to kill you... it broke the game XD
maybe near the main entrance/fire exits.. i need to do something special, to avoid that issue. ill look at it tomorrow.
Is that so??? Was unsure if it was even related to this mod, but that would make sense
Well, broke the game in relation to that masked, it shouldn't break anything else, but I guess if the error was such a big deal, it could cause that I guess.
I get huge fps drop with this mod 
what was occuring when the fps drops happened?, Brus was also getting fps drops, but, i need to know what the masked are doing, or logs with status reports from debug mode being turned on so i can work it out myself, as i realise knowing what the masked are doing via visual observation likely wont lead to much.
but yeah, if there is any information about what the masked were up to when you got the lag, then i can work out what personality, and look into it from there.
I spawned two masked enemies and my fps went from 70 to 10
so as soon as they were spawned? can i get the log file?
Oh right! Forgot to answer. I'm pretty sure it was a either a steathly guy or a insane guy that i aggored
The moon is a new map by Widerstein called Twins. Used that cause that was the one i recently got the fps drop on
but i also get it on black mesa and other moons. But it was more visually clear on twins in this circumstance
i had godmode enabled! thats why a few were dead maskes were around. Had to make sure the right personality was there. Altho might be hard to tell which one is alive in the logs by doing so
i got alot of mods, but the fps drops still happens on my debug-modpack. Just not as pronounced
so if i disable this options in toomanyemotes config, i might get less fps-drops and crashes?
Feel ya, today some mod started to make giants and nutcrackers legs to spaz-out. The legs are like reversed when walking, going up into their butts. Think it might be ColorfulEnemyVarietyWIP, but i'm too lazy to look atm
i dont know.. all i know is i dont use that mod.. and i dont get such extreme fps drops..if you get the same outcome with ONLY my mod.. then its my mod, but if your testing with 50 other mods, its hard to say the cause.
alright, alright
i will try it later tonight and update if the huge fps is still there
totally unrelated, but, as you make a mod pack, a quick question... a mod, that could help identify conflicts in patching so you can easier see which mods might conflict with each other.. would that be helpful.. for building a mod pack? it wont tell you where problems are, it would just say "you may have a problem because these mods change the same code"
that would definitely help. But i also look alot in the logs
And also this does a similar thing but is also "supposed" to prevent conflics
https://thunderstore.io/c/lethal-company/p/DBJ/UncaughtExceptionCatcher/
atleast for exceptions
i think some of my log reducers and other mod-fixes are helping. Cause i have about 257 mods atm, with minimal bugs
And also some moons that crashes for other people works fine in my modpack
Alright so i tested again without the config from TooManyEmotes. Made a marginal difference, but i know it's the steathly personality going outside that makes the fps-drops now
yeah i saw that, was just thinking for modpack creators... i make modpacks too, but, something AUTOMATICALLY fixing a mod, sounds like a its going to break one mod, or another, it just prevents that mod from breaking every mod, i think xD
my idea was a mod that tells you what might conflict, so if your having issues, you know what mod to test.
ok, so ALWAYS stealthy, ill have a look at stealthy then, as i havent touched that code aside from putting it into the same structure as the other code.
comical.. as soon as the stealthy masked dies.. the fps instantly goes back up xD
ok.. so i did a similar test.. with stealthy...
im invisible, spawned them inside... turned them off a sec, walked outside..
110 fps
turned them on 90 fps
they walk outside.. 50-70fps
they walk inside.. 80-90 fps.
so indeed, the stealthy masked going outside seriously has some issue... >.> thats crazy.
they steathily sabotaging your fps
indeed, sneaking around between frames.. with every frame.. there is a stealthy masked hiding behind it.
they are quite the devious fellas
may have found the issue.. xD
MaskedPersonality = Stealthy MaskedFocus = Items
they dont have any code for "items"
so that shouldent really be a focus of theirs atm.
rip, sadly that isnt the cause of the issue, ill look into it further :/
ok, its not only stealthy masked, its ALL masked, as soon as they exit the facility, im getting the same fps drops... so its something related to masked going outside.. but what.. i have no clue...
maybe ask for help from the optimization nerds on this server?
maybe they can pinpoint the issue
isnt there a way to analyze what’s going on in unity and see what’s sucking up system resources?
well, i have a theory first.. i think its due to view distance.. on the interior.. the view distance is limited.. its possible that ive set somewhere to check an unlimited distance 😛
ok, i know the cause of the issue.
I added in some variables calculation that runs constantly.. it seems that, and that alone, is causing the fps drops.
I will do something to stop that from occuring, either by stopping it being a constant thing (which is kinda required :S) or by splitting it up to where it needs to be.. was just trying to give the masked up to date info, never imagined such simple calculations would to fps drops xD
ok.. i think ive got a fix for 0.1.1
i had 110 fps.. spawned masked inside, 105fps.. they walked outside, 100fps.
I basically added a delay on the calculations, and stopped them running until they are needed.. so the calculations only run every 1 in 10 times.. and only if they are changing focus, or are focusing on the focus that requires the calculation.
have 8 masked running around, still getting 70fps.
what’s ur fps without lethal intelligence in the first place?
also i remember some modder on here saying that when an enemy targets someone, their AI switches over and gets handled on their target’s pc.
i assume by default it’s usually handled by host.
so did that mean the fps drops only affected targets?
cool that performance is a lot better not though 👌
right it was bongo who said that
that was interesting to learn about
that all makes sense.
after all, the player the masked is targetting, is usually the closest, so.. if your miles away from a masked, why would you be calculating it.
let me disable it, go to the same spot,. and tell you, but my max fps is usualyl like 130, tops
its 120 without LI.
so LI is 10 fps loss for me.. and with 8 masked, i lose a total of 50.
to be fair, in reference to the screenshot above..
only 96.. so 8 masked = 20 fps drop?
all the AI stuff is cpu-sided right? what kinda cpu u got
i3 - 9350KF
so not modern (5 generations out of date), and a low i3... probably better than others. but.. like, i have a friend who gets worse FPS with a better cpu so shrug xD
do u know if all the AI stuff only uses a single thread or has already been made to run on multiple?
imma attribute that to weaker gpu
i swear if u say ur friend has both better gpu and cpu and still worse fps than u. then there’s some strange tomfoolery going on.
well.. your a genius.
being honest, i never thought to try and get the mods code to run on multithreads... which.. comically.. is how i work irl (i split stuff on to multithreads to speed up processes), i just figured the game handles that, and i cant circumvent that.. xD but maybe i should just "try".
nah, their GPU is worse.
its like 9350KF + 1660 super vs 10XXX cpu and 1050TI
but while i was getting 100 fps, they were getting 30fps lol, it made no sense.
not enough memory? some mods are real memory eaters
i don’t gotta sweat it tho with my 32g ram and 16g vram 💪 (flexes)
but my poor potato pc friends 😩
maybe, all i know is i had a look at thier PC, and it made no sense to me. they were having other issues, specific to LC, once i got them to a slightly better fps, i didnt look anymore.
amen, same for me.. well.. 8gb vram on this 1660 super >.> but my pc is on its dying legs, so shrug
lunx was talking a lot about lethal resonance unfortunately taking a lot of ram for some reason
we dont use that xD but it doesnt surprise me, its loading a lot of audio files, which i assume then sit in ram... unless im forgetting what that mod does.
still keeping it in my pack. don’t think anyone in my friend group has had too serious of an issue yet.
so if u got ur code to actually run multithreaded, then better performance? more masks with even less performance hit? that is if you were to successfully “try”
yeah, it should be, but imho, i should just get each "AI" to go onto a new thread... or something... because splitting up 1 masked, onto multiple threads.. hmm
or maybe just each time an update is run.. it goes onto a new thread..
i will just have to test.. and see the ramifications of that.
question about programming in general: do asynchronous programming and multithreading relate to each other?
btw.. i d k whats going on with thunderstore rn.. but changelog updated.. but actual version update isnt appearing on there <.<
v0.1.1 released
-attempted to improve the pathing to the breaker box
-prevented "Stealthy" from focusing on items as they have no logic for items.
-potentially fixed an issue with fps drops due to heavy calculations, hopefully this fix doesnt cause other issues 🙂
sort of.
multithreading is the process of putting "work" onto multiple threads instead of the default (1 thread)
1 thread goes through one logical processor (1 core basically)
"aysnchronous programming" is more in relation to running the same "process" on different threads, at the same time.. so.. one bit is running on thread A.. while another bit is running on thread B.. and when thread B is done, it tells thread A its done.. and if thread A reaches the point where it needs to wait for B, then it waits for B until its done.. the "async" part is where B is running at the same time as A.
ah okay thanks for the explanation
its np, i was actually a bit wrong...
multithreading = seperate cores
hyperthreading = seperate logical processors
(new CPUs can have multiple logical processors on 1 core, old cpus.. like mine... cant)
totally. im going to update my computer as soon as i can afford.. love my pc, but.. uh.. yeah, its old. xD
my girlfriend had like 3110... lol
9th gen isnt that old tbh... its perfectly fine, but you hit the nail on the head with the i3.
back when i got my pc.. video games were 99% single thread.. multithreading in games wasnt really a thing... which is why i went with the cheaper I3, with the higher processing speed.
nowadays.. games.. actually use multithreading.. x.x
a real multi-threat to ur pc frfr
the bigger thread is me throwing it in the trash xD
omg, thread <.< love making stupid typos
🤣
THIS IS SO FREAKING GOOD
Minimal fps-drops with over 3 masks (shouldn't spawn more than 3 mask thu vents anyways), even on a heavy moons such as black mesa
I got a new pc thats ok
AMD Ryzen 5 7500F CPU
Sapphire PULSE AMD Radeon RX 7700 XT
32gb ram
SSD
but i also got a ridiculous amounts of mods (256). With that i get around 30-40fps consisently on black mesa
even better on others
altho without anything lethal normally runs at about 200+fps lol
but i rather have more fun gameplay mechanics than 60+ fps. I mean comeon, halo 2 and zelda ocarina of time run at 30fps and are still bangers
okay OoT ran at 16.66 FPS in europe (pal-format)
laughed alot at this comment
i thought aysnchronous loading meant that it lets things show before everything is loaded. For example, if i need to load a enemy, on a normal load it loads the full enemy, that includes it's skeleton, hi-res texture and low-res texture. Instead of waiting for everything to load it let's it thru anyways.
if virus manages to get multithreading working. it could be even less performance hit.
So for one second you could see the enemy with low-res textures until the hi-res texture has loaded
thus circumventing lag-spikes by not waiting for the whole thing to load
when we talking asynchronous, we talking about the computer being able to do two separate tasks at the same time without the tasks needing to wait on another task to complete
aah yes
idk if this a good analogy
me and my buddy marcus will go home after we finish drinking.
synchronous: i finish drinking a bottle, but now i’m waiting on marcus to finishing drinking 10 bottles before i can finally leave to go home. marcus and i leave at same time once he finished drinking.
asynchronous: i finish drinking a bottle, i immediately go home. marcus takes longer to finish his 10 bottles, then he goes home.
hahaha that is a example
with synchronous, there’s a moment where nothing’s really getting done. wasted productivity.
i’m just sitting there waiting for marcus to finish 😠
yeaah exactly. I'm alittle familiar with it due to i had to have that setting on a switch-emulator to be able to play Zelda breath of the wild
had a shitty laptop back then
visually it was clear what was happening
didn’t the emulator get nuked?
yuzu is gone
i think also ID-software uses alot of asynchronous loading in their games
rip
dunno if ur already using it, but #1242303311793885317 is interesting
asynchronous dungeon generation & more
yeaah, have that already, but the nightly-version
Works really great now
Normal loadstone is still alittle weak. Breaks alot of stuff and load-time is actually longer
But nightly works great. Even tho it might break alot of mods, but in my modpack i was lucky
gotta have labrats report back to adi. pave the way for a faster moon loading future.
lol, i will try to, but i mostly lurk if i don't find anything major
"interesting" is the word.. and this is why i think "aysnc" doesnt truly work.
like.. it does speed up loading, and i do use it.. but at the same time.. the "fps lag" while it does so, is irritating.
the point to "async" is that "what you see" is running normally.. while things work behind the scenes.
when you have no async in a windows form, the form locks up while heavy processing is working.. which is basically how loadstone normal works.. the game slows down.. to process the data quickly.
if loadstone was truly async, it would do the processing on alternate threads and not slowdown the normal thread.
we call them that in our friendgrupp, but thats because worm means mask in swedish. So it's hella confusing
hmmph, interesting
but what is the word for "masked" is it like "wormed"? XD
hahah yes
ah.
welll i mean
the problem for you guys then is..
Masked = Masked
Mimics = the fire escapes that eat you
so to use the term "mimics" for masked, is confusing in itself xD
doppelgängers
DUBBELGÅNGARE
noo, doesn't have the same umpfh
well i hope adi figures it all out
lot of promising things in that thread recently
well, i tried doing a simple thing to get update to run on its own thread.. game instantly crashes 😄
ladyraphtalia was talking about how dungeon generations uses an inefficient sorting algorithm
and explaining to adi how they got a better one working for their own custom interior and i think that helped with performance
so, was just looking at asyncloggers.. uses a similar method to how i was using, to put stuff on a new thread.. i get the feeling when i put update on a new thread though... it instantly re-runs update.. there in making the game crash.
u mean like the update gets looped?
oh another thing that maybe a problem is, updating things on the "normal" thread from the "update" thread, as thats usually a hassle.
update runs constantly... im guessing it runs, as soon as the last update ends... so its always a loop.
but just now.. i put the whole of update on a new thread.. so i think its going ...
update 1 start -> on new thread -> update 2 start (but update 1 is still running)
that.. or.. it crashed when it tried to update values, but is on the wrong thread.. 😄
all i know is, masked spawned.. 1 second of game play... poof, crash.
the main fps drop is the variable calculation.. if i can get THEM on their own thread.. then, there should be no fps drops visible.
🙏 hope u can get that working
that would be a gamechanger, would never play with the normal mask again
maybe call in these async nerds on this server for some advice if you reach the end of your rope
nah, i think i found the issue
any variable updated on another thread, needs locking before updating on the main thread, and vica versa.
just not sure it will be of much benefit, i d k, may also cause problems, xD
by locking, u mean can’t be touched by other threads?
i’m curious what do the variable calculations relate to for you to need them to constantly update
basically.
its not that i need them to constantly update, its that the "Update" method runs constantly, and MaskedAIRevamp used "Update" to do everything.
ive added in some variables for checking positions of objects, as well as checking the distance, if they are reachable, etc
in the case of for example.. the terminal.. this can be checked ONCE.. technically.. but, what if a DOOR is close that the masked then cant open?.. then it would cause errors, or lag. by trying to route to the terminal, when it cant access the terminal... so i check that.. and make it "unreachable" when that happens.
items are worse.. items move, can be used.. so removed from the game.. and new items can be added (store)
then there is the breaker box.. which isnt present on all interiors.. sometimes it spawns inside walls and isnt accessible.. etc..
if the "10" delay on the update variables is fine... then i may just lower it to 100.. or 1000.. im not sure "1000" is 1s.. but if it is.. that should be fine.. but i dont think it is, i think its 1000 updates.. which.. 1000 updates could be a few minutes.. lmao.
and the problem with the updating of all those variables is.. if i put them on an async method, thats a LOT of variables i need to lock..
i see so it really isn’t as simple as just tossing those variable calculations to another thread
because u still got code on main thread that use those variables .. but they get locked away on another thread.. something like that?
sadly, no, when i do multithreading elsewhere, im usually throwing the kitchen sink on the alternate thread, and leaving it there, the only thing that is called back to the "ui thread" is a status update... not 50 million variables XD
yes, thats correct.
dang. no way u can divvy up the stuff that use those variables on the main thread to separate threads?
another thing, u mentioned earlier about running this stuff on Update. that runs every frame right? so the more fps u have, the more checks. like i can get 200 fps.
but isn’t 200x checks a second kinda overkill and will make the pc work more since ur checking for so many things at a faster rate.
i heard FixedUpdate updates 50x a second. would that help performance or would that be negligible?
i have no clue on this xD i dont know how often "update" runs, but as far as i can tell, it doesnt run, until the previous has ended.
so i looked, and fixedupdate doesnt look like the best idea, update looks correct, i probably just need to work out if i can make it run slower.. im not sure it runs "once per frame"
oh ignore me, it is called once per frame xD
hmm, there is a timing i do using update.. i guess i should change the way that timing is done, i didnt realise it is affected by the fps ;o
i thought fixedupdate is always better for physics
Hello readers, I’m no longer posting new content on gafferongames.com
Please check out my new blog at mas-bandwidth.com! Introduction Hi, I’m Glenn Fiedler and welcome to Game Physics.
In the previous article we discussed how to integrate the equations of motion using a numerical integrator. Integration sounds complicated, but it’s just a way to...
better for physics, but who said it’s only just for physics.
i was just thinking it might be better for the AI coz does it really need to be updated every single frame when 50x fixed updates per second might do the same job without overly taxing the system. especially when virus is checking for so many variables at once.
at least that’s my thought.
AI is game logic
which is part of that
idk if unity devs just follow different standards, but typically it's better to have game logic run at a fixed interval
enemy ais means you move an entity around = game physics
yeah that’s why i was suggesting something else other than Update since that’s not fixed interval updates. it’s updating every frame.
i thought FixedUpdate was similar to like the game ticks u see in Minecraft. where pretty much everything is done within the 20 game ticks per second. block updates, mob AI, redstone logic, physics.
yeah i meant to reply to this, just realized we were agreeing on the same thing 😛
yeah, i was sort of working that out last night, there is also a way to do timing using "update", by setting a time and then constantly checking the time with update and if the right amount of time has passed, then "perform whatever"
from what i understood though, fixedupdate's timing, comes from LC, so if thats set at a bad rate.. then it could be bad.. also... the actual way it works.. is if it needs 2 updates per frame, it will just run 2 update instantly, it doesnt actually update on perfect timing either, but i will certainly have to look at it.
maybe it uses unity's default of 50 updates a second. (executing every 0.02 seconds)
i bet someone on this server actually knows for sure
#1242303311793885317 message
asked some other folks about it and got some interesting answer
but oh well. i think i might be pestering u too much about the whole thing btw. sorry if i am.
anyway just hope performance is under control since i really wanna run this mod smoothly in a fat lobby.
not pestering me, but some days im not interested to write code outside of work, and sometimes im working xD
regarding performance.. 0.1.1 should have resolved the fps drops, i guess the other issue is the "timings", they dont matter that much, but, people on like 50fps.. will have a significantly different experience to people on 200+ fps for example, due to the speed differences between actions being 1x vs 4x.. so people on 200fps will have things occuring 4 times as fast, really, this doesnt matter much.. the timings are on the breaker box (the masked switches it off quicker/slower).. and the terminal codes are entered quicker/slower, the delays between signal translator messages is slower/quicker and the dropship is called in slower/quicker.. so that issue is minor (hence why im not rushing to fix it)
helpful information thanks, the interesting thing though is.. if its run "every update" fps drops are present... if its run every 10.. they dont seem to be, or less pronounced, so i can only imagine, it being run once every 10 frames, means the frames catch up, and that 1 frame running it, is slowed down.
so i just tried doing a coroutine, just for the variable calculation.., and the fps drops are back xD it maybe i need to go deeper into it than i am now.. but, it doesnt seem to help.
ok i think i get the issue with the coroutine now..
what i WAS doing.. was..
if (calculationDelay > 0) { calculationDelay--; } else { calculationDelay = 10; //calculate variables here 1 //calculate variables here 2 //calculate variables here 3 }
with the coroutine, i instead need...
//calculate variables here 1 yield return null; //calculate variables here 2 yield return null; //calculate variables here 3 yield return new WaitForSeconds(1f);
but thats still leading to fps drops.. hooray 😦 but better than before i added those yields... but weird because 1 in 10 frames at 100 fps = every 10 frames.
every 1 second at 100 fps = every 100 frames.. so im getting better performance from 1/10 than 1/100, which is the opposite of expected.
actually i maybe just.. speaking bs.. this message basically says i was getting 70-75ish fps with 8 masked.. im getting 75-80, so maybe it is better.. but only marginally.. not really worth putting on a co-routine for "fps reasons". now for TIMING... maybe.
nevermind, im stupid 🙂 maybe it does help >.>
so it seems in this instance at least, coroutines wont work for me.. can look back at multithreading though ;o
"One of the biggest differences between Async and Await functions and Coroutines is that they can return a value while, generally, Coroutines can’t do that."
if u wanna check the #1242303311793885317 thread again. adi talked about LC’s usage of fixed update and enemy AIs using DoAiInterval (but zeekers sometimes inconsistently using Update instead)
you can set whatever update interval u want for DoAiInterval 😮
apparently all the vanilla enemies got differing update intervals
yeah i guess coroutine really just good for executing actions rather than returning values like u want
if you don't have to access Unity API. using jobs is the Unity approved way of doing threading 😅. that's all the help i can give you w/o knowing the code.
i did a lot of testings with threads, and AsyncLoggers works because i'm specifically overriding Unity functions and generally touching low level methods
also IJob are intended to be used passing primitves as input and receiving primitives as output
im already doing similar...
renamed my update to "UpdatePointOne"
then called this in start()
InvokeRepeating("UpdatePointOne", 0, 0.1f);
havent checked that it gives a steady timing, but i assume it does.. performance is around what it was before...
ngl, found like.. 5 different bugs in the last 30 minutes x.x so in a rush to fix them all, but this "timing" update will be in the next version too as its working... so far.
thanks, will look at it in time, finding a few "completely mod breaking" bugs is my priority right this second xD
i just followed where my answers were going to as depending on the use the answers might change
in your case i guess the corutine method did not help either because your computations between the yields are still too heavy or you're starting mutiple corutines at the same time without noticing
but if you do not need to act on your computations until they are complete then using jobs/threading will give you better results
well..
calculations were checking the accessibility of..
1 the terminal
2 the breakerbox
3 the nearest item on the floor
if they were false, it would tell the code to not focus on that area of the code.. otherwise it "could" focus on that area of the code relating to that object.. basically there to stop masked staring into space unable to route to something they cant reach.
but, the fps drops which were occuring, ive already resolved afaik without threading, but i will look at what you suggested after ive fixed the bugs i found just now, any performance improvement will be great.. the main issue i had with co-routines was, it was not updating the variables that were being calculated within them, but.. that may have been a seperate issue (as i found the variables were just not updating anyway after i removed the co-routine 🙂 which is one of the bugs im fixing).
Experimental v0.1.2 released.
- switched from FPS based timing to a fixed update timing of 0.1s and fixed all relevent timing issues related to this change.
- fixed some variables not updating since v0.1.1 leading to masked being unable to perform some tasks.
- fixed masked "sight" parameters to correct the sight they have so they are not seeing through the back of their skulls (well almost..)
- fixed a bug where a masked dying on the terminal prevented all other masked from using the terminal for the rest of the round
^ if huge fps drops have come back, do let me know, it didnt seem like they had.. but i wasnt getting my usual fps.. started at 95 instead of 105, and it was dropping to 65ish (with 8 masked) at its low point...but i feel like that was due to my pc having a lazy day in bed.
is there anything wrong with using Task.Start instead? i've been using that equivalent in f# all this time and it seems to be fine for me
it's fine until you use unity api
curious how you made your own update method with custom update interval. i think testaccount could piggyback off ur homework since he needs to a way for his fix mod to not check every frame.
#1220488542585753631 message
i saw u necro
in that thread, diffoz doing a deep dive on lunx’s modpack and seeing what’s hitting performance
I mean you could just early exit the update function if you don't want to process that frame
My message didn't send because of train wifi 

can u elaborate what it means to early exit without processing the frame? the mod’s TestAccountFixes btw. it seems he’s checking for stuff every frame in Update.
When you don't want to process (based on a counter or condition) you literally just add this as a condition to exit at the start of the function
if (shouldNotProcess) return;
What that condition is, depends on what they want to achieve
yes, but it will still run EVERY frame.
the way around it is to do "coroutines" that split up the work over multiple frames, but what happens in coroutine, stays in coroutine (fight club ;))
Sure but it'd do that anyway
It would do the base update function instead
yes, but ive got mine running on time, not frames
There's not much cost in effectively calling an empty overridden update
so.. if you have 200 fps vs 30 fps.
Update() would run 200 times vs 30 times (per second), meaning higher your fps, more load on your pc = fps drops at high load
what im doing = no matter your fps, it runs 4 times a second.
Then your condition would use a counter with deltaTime to check if 1/4 second has passed?
i could probably increase it to 50 times a second (the same as FixedUpdate) but i was trying to see how high i can get fps to go, without hitting functionality.
I don't see the issue
Well actually I don't understand what you have to make the timing that bad, I'd need to look at the code
So I can't really comment more than what I have
i think the 4 times a second thing was just an example
Start() { InvokeRepeating("UpdatePointOne", 0, updateFrequency); }
and
public void UpdatePointOne() { //do updates }
updateFrequency = 0.1f
and yeah, i didnt mean 4 times a second.. its 10 times a second, forgot i changed it.
but yeah, i just renamed update to whatever i want then called that function in start.
^ I'll see if I have time to look over and spot anything that stands out
But I see what you're doing and am still questioning if you're targetting the right optimisation essentially
being honest, its just a looping calculation.
when i was running it every frame at 200fps... then 1 masked would drop 20fps.. 2 would drop 30, 3 would drop 35.. decreasing losses.. because the fps was dropping... but lower end of the scale was going from like 70 fps to 20 fps by 8 masked.
when i ran it at 1 in every 10 frames, the fps drop was 20fps for 8 masked.
Well yeah it would help but is that solving the underlying issue is what I'm getting at here
and that was fine... then i had a stupid thought.. "what about the timings?" because i didnt realise update was every frame.. so i changed everything, not realising most of my timings are covered anyway xD
how does InvokeRepeating work behind the scene to get the timing?
well i changed to a fixed timing because im an idiot, but i figured lessening the frequency of everything is better than lessening only part of it, im still reducing the small part of it too.
before it was updating once every frame, with the calculations running 1 every 10 frames.
now, its updating 10 times a second (at 200fps, thats 1 in every 20 frames... plus also the calculation is running 1 in every 50 updates? = 1 once every 1000 frames?
i d k, its just calling the method on repeat on an interval of updateFrequency.. its not something ive made, its a normal function.
i should add, at 30fps.. thats 1 in every 3 frames.. so people at lower fps are getting a similar experience as before, this just "potentially" stops fps drops at high fps.
the method causing the fps drops (which i have also improved the efficiency of) is this
u mean like updating in fixed time intervals within Update by using a condition to check how much time has passed? i wonder how the performance of that compares to virus’s way
well... this is why the way im doing it isnt so successful.
im running 10 times a second, but afaik, taking a performance hit because of "invoke"
using FixedUpdate, i wouldent get the performance hit, but would be running 50 times a second.
Using update and doing a "calculation delay" like in the function above.. so it runs less often, would likely not have a performance hit so would probably work better... as i said, the main reason i changed, was because im an idiot 🙂
if this way isnt working.. ill try "FixedUpdate" because i like the idea of fixed timing being honest.. and if thats not working also.. ill change back to update and make it run once every X frames.. my concern with that though is.. lower FPS players will suffer.
like.. 200 fps running 1 in every 10 frames.. gets 20 frames of updates per second.
30fps running 1 in every 10 frames gets 3 frames of updates per second
but that one function is a lot of heavy load on that one frame its updating, the rest of the frames just.. "compensate" i think.. which is why it worked..
for all i know, the way im doing it now, and i beleive also fixedupdate, do the same.. if they do, im wasting my time and might as well use update.
either way, my goal is just to eradicate fps loss... which i think i already did.. so i could go back to update, if it just isnt working 😛
on other news.. bracken's
Angry Bracken = quicker to anger
Calm Bracken = very slow to anger
already have the basics of this working..
I was thinking angry bracken should maybe move a bit faster... make it very lethal.
on the flipside.. the calm bracken should be more like the "snatchin bracken".. either has a chance to just "carry you away" to their stash spot to kill you.. or just doesnt kill you but kidnaps you and only kills you if you leave the room they put you in or something.
I was then wondering the possibility of a bracken.. thats invisible unless your looking at its eyes... for a "Stealthy Bracken".. and also maybe invisible completely if its not moving.
any thoughts?
i like the idea, but any plans to visual indicate the personality? like idk they slightly different colors. like angry bracken would be tinged red or something
here’s an idea for snare flea btw. instead of camping in random spots, they intentionally camp above items.
that way people are likely to get distracted by the item on the ground and not look up.
well.. thing is, if i start doing that... it makes them readable.
the full plan of the collection is..
1 - angry
2 - calm
3 - stealthy
4 - friendly
the aim was.. they all terrify you in different ways.. friendly doesnt sound terrifying.. but they are more the "stalk and dont kill" sort of guy.. so you still get the "turn a corner and jump at the sight of a bracken" ideas.. but they wont kill you, they will kill things that target you.. but they will still run when you look at them.
so.. they are like your guardian angel, who.. will run when you look.. and they will run..stopping themselves from protecting you, that was the thought...
if we add in colours, that makes that too easy to know which is a friendly bracken.
saying that though, if i make stealthy invisible.. its basically adding a colour.. so i d k
ah ok so that’s what ur going for
make enemy AI seem unpredictable
well thats how masked ai revamp was i thought.. you dont know how they will act.. because the personality is different.
but saying that.. could do colours.. (if i knew how).. and just make "friendly" be a friendly version of the other 3... so they could use a random colour.
think of it like.. friendly fell in love with you.. so they maybe an angry mofo.. but.. they want to protect you, so tinged red, but kill things that are attacking you.
hope u account for compatibility with other mods like diversity since they got their own stuff that touches the bracken
i would just reccommend that "bracken personalities" are turned off if diversity is installed, etc.
the "normal" personality will remain either way.
like if i disable bracken revamp to use ur brackens, would it be all good
Sorry for the late response; at work. I'm wondering the same thing since this is closer to what basr game does
New ideas sound good
i would have to look at how diversity works tbh, but in my head.. this mod likely wont be compatible with other AI tweaking mods that affect the same monster.. but as im adding in switches for personalities.. i would hope that if a monster was "disabled" in my mod, then other mods could tweak it freely.
as for what those mods do, i d k
probably works better.. as that was effectivly what was being done before, it was just a bit janky. If i had of understood how deltatime worked, i probably could have just gone that path, as i said, i am an idiot and wanted to make sure timings between things matched for all players 😄
on that thought... i should really disable the patches if the AI is turned off i guess?
diversity dev did add compatibility for other bracken mods like snatchin bracken. it’s a toggleable compatibility tho.
so what like.. "if other mods patch these things... turn off functionality"?
if so, i could do that.. i was already working on a mod for "modpack compatibility checking".. not a 100% guarantee.. but i could just put in a checkbox for "be compatible with other mods" then if another mod touches certain functions.. then.. "disable" that part of the mod automatically i guess.
just gets tricky if i delve into monsters interacting with monsters.. lol
im actually not sure how it works since i’ve never used it
yeah sorry, i was more farting out thoughts on how it probably works.
honestly the diversity bracken is pretty much like ur angry bracken
a sensitive fella
pull the apparatus? angry
flip the breakers back on? angry
and he stays angry for a whole minute iirc
ah thats not how mine was going to work.
there is an add anger function as part of the flowerman AI.
when it adds anger..
its like +0.02 anger
i was making "angry" add 2.02
and calm add "0.005"
so you so much as gaze at the bracken for more than 1 second, they will likely instantly anger.
bare in mind, its "per update" i think.. and 6ish anger = angry mode engaged, i think..
so 3 "updates" and the bracken would be angry.. which is the blink of an eye.
and the calm one, just would never get angry.
the pulling the apparatus/breakers on, i could technically make the bracken angry then too, but then they would be hating on a masked, as i planned to make "insane" pull the apparatus.. and if the breakers are OFF, the "cunning" masked will turn them on.. so both masked would then be a target for the bracken.. lol
huh that does make me wonder how diversity bracken would react to ur maskeds pulling flipping the breaker
normally it targets the player who flipped it
well.. thats the problem with multiple mods targetting the same areas, imho, only one should get used at once, its likely the diversity bracken would just error if a masked turned on the breaker box, or do nothing.
they probably look for a PlayerControllerB to target, as the masked isnt a PlayerControllerB, it would be null.. or it would choose the player closest to the box.. which would work, but would be wrong.
i’ll prob test it out
also any plans for those maskeds to be able to drive the new vehicle?
that’d prob be complicated to do i bet
since i’m guessing the vehicle’s only meant to take players and player input. not some enemy AI.
can’t wait to run over the homies .. 🙈
vehicle? havent been paying attention clearly x.x lmao
i think the most complex bit would be getting them to drive. masked are closer to players than one would think.
I assume could probably setup a player controller, just for the masked, so when the masked want to drive, it puts them in the right animation, then uses an invisible fake player or something to actually use the vehicle.
i say this because for example.. im pretty sure the animation for "terminal" is just for the model.. so there will be an animation for the player, that should also work for the masked..unless i dont truly understand animations at all.
and actually.. probably dont even need the fake player.. there is probably just commands for controlling the car.
or whatever the vehicle is
but.. as for complex... sure no "rules" for how its used.. but.. look at FSD by tesla.. complex as f.. on version 12 and still a buggy mess 😄
i can see Zeeks add that feature to them honestly
but we have to wait for v55 to see
I just can't stop thinking about how funny it would be if a Masked pulled the apparatus that makes the Bracken angry at them, causing the Masked to run away from the Bracken.
The player just standing there, witnessing it, not realizing it's a Masked, and getting killed by the Masked followed by the Bracken, lol.
even if the bracken could chase a masked, there’s nothing in the maskeds code for it to run away from a bracken
yeah, imho, masked should be "scared" of spiders, thumpers, brackens, worms, dogs, giants.. at the least.
im sure i will put a "fear" aspect into the masked eventually, i know for sure i want them to "crouch" when dogs are around.. so I assume i want dogs to target masked... i guess also in that same vein, i want other monsters to target masked as well... like they are players... but thats a tricky balance, as if the masked are targetted by everything.. then they have no function, they are just running away from everything.
or maybe i dont want dogs to target masked, but i want masked to behave like dogs can target them?
(ie, backing away from dogs, crouching, etc..)
Aside from the formatting and a few optimisations in initialising the NavMeshPaths, the docs mention that CalculatePath is expensive and shouldn't be done a lot in a single frame:
https://docs.unity3d.com/ScriptReference/AI.NavMesh.CalculatePath.html
I see you only do that when the masked enemies are close to these objects though so I guess you could at least do the simple cleanup until more things pop up
Ah I see you tried DetectObject and it didn't work; I did the exact same thing. What wasn't working there?

so, little bit of an update, kind of changed my mind on what the masked do with the apparatus, i wasnt quite sure what i wanted them to do with it after they pull it... so.. ive decided not to pull it after all.. but rather "sabotage" it. I may change it in future so that they "eat it" (as they are insane :P) and i was thinking i may make the masked glow.. to show they ate the apparatus.. but for now them "sabotaging" it is enough as it means it triggers the normal "meltdown" (or apparatus pulled) scenario.
i also think this is going to kickstart insane's "i want to leave the planet" focus, so probably going to make is to they dont focus on the apparatus unless its between 2pm and 6pm or something.
well it was just a thought.
I can make the apparatus disappear, but it breaks the "meltdown" side of things... so for now im accepting disabling it in the next update.
every time i blink, u have a new pfp
every new pfp is a different iteration of me
and i'm never satsfied
i am always on the lookout for a profile picture that fits my personality
and just like that boom i have a new one
that’s a lot different sagey’s
there are many
which one is the real one?
i'm still the eigth version
which are the frauds?
whichever one currently existrs
they must be eliminated
the previous iterations
so was just looking into this suggestion..
i tried getting rid of the navmeshpath's so there is only one.
[Error :LethalIntelligence] NEW Calculation = 08:02:44:4802306 | 08:02:44:4802306
[Error :LethalIntelligence] Calculation = 08:02:44:5682594 | 08:02:44:5682594
whether i have one, or multiple NMP's, it takes 1 millionth of a second.. so either ive already optimised it enough O.o or.. it doesnt matter that much, i ran it for a while, and every time i stopped to check, the start time and end time were the same.. for both.
if you have 1millionth of a second to do a frame.. thats fine up to 1million FPS??? or is it 10million??? f it was just that part of the code, im guessing the full "update" function will take longer, but ill have to check that now as apparantly this section of code isnt actually taking that long 😮
I did see it take an actual amount of time when they walked from inside to outside, but i think thats because its suddenly processing the change of inside to outside.. lol
the item checking is part of that xD
But a path to every single item per masked per frame is heavy lifting
did the same start/finish timing on the whole update method while outside (Where the worse fps seems to be..) 0.001 to 0.002 per "update".. so.. if running a normal update, thats fine up to 1000? fps?
[Error :LethalIntelligence] Update = 08:12:48:4382231 | 08:12:48:4392203 [Error :LethalIntelligence] Update = 08:12:48:5337667 | 08:12:48:5357612 [Error :LethalIntelligence] Update = 08:12:48:6530600 | 08:12:48:6550548 [Error :LethalIntelligence] Update = 08:12:48:7405552 | 08:12:48:7415521 [Error :LethalIntelligence] Update = 08:12:48:8508977 | 08:12:48:8518895 [Error :LethalIntelligence] Update = 08:12:48:9365722 | 08:12:48:9380742 [Error :LethalIntelligence] Update = 08:12:49:0427501 | 08:12:49:0437468 [Error :LethalIntelligence] Update = 08:12:49:1520843 | 08:12:49:1535877 [Error :LethalIntelligence] Update = 08:12:49:2412586 | 08:12:49:2427627 [Error :LethalIntelligence] Update = 08:12:49:3482372 | 08:12:49:3492288 [Error :LethalIntelligence] Update = 08:12:49:4381829 | 08:12:49:4391802 [Error :LethalIntelligence] Update = 08:12:49:5380474 | 08:12:49:5400374
if its so heavy, why is this timing coming back so low? :S
Not the instantiating part, the actual calculation
I did think it was the former before but that was clearly wrong like you've shown
no no, you misunderstand, im timing EVERYTHING.
start -> 48:5337667 | 48:5357612 <- finish
bloody emotes..
Oh, that is weird then
it maybe that, it is HEAVY, just not time consuming.. :/
which means checking how long it takes it pointless 😄
I guess you could profile with and without the checks to be sure?
well, the simple fact is all the calculations + item checking = less than 1 millionth of a second.... and disabling that, improved FPS massivly.
I think i need to go back to the old update, and check how slow it was.. and remove the thing stopping the calculation occuring every time as well.
then i will see the real heavyness maybe
Well good luck, inspecting what changed seems like a good idea
i think.. tbh..
going from 200 updates a second... calculating every update
to 10 updates a second, with 1 calculation every 50 updates
i think that oversolved the issue.
thats from 200 calculations per second -> 1 every 5 seconds.
well, reverted it back..
[Error :LethalIntelligence] Calculation = 08:27:03:2223329 | 08:27:03:2223329
[Error :LethalIntelligence] Update = 08:27:03:2223329 | 08:27:03:2248375
[Error :LethalIntelligence] Calculation = 08:27:03:2584264 | 08:27:03:2584264
[Error :LethalIntelligence] Update = 08:27:03:2584264 | 08:27:03:2604214
nothing changed xD
dropped 15fps though
yeah, not much change no matter what on the timing, but its defo heavy as f on the fps.
I guess i will have to look at eradicating those calculations if i can, but the whole point of them was to give an understanding on what options the masked had when it made its choices.. rip xD
had a look at the calculate path page you linked, it actually says you can only do a few of these per frame, so maybe heavy, but i am only doing 3 max per frame, if i was calculating per frame, so that may actually be ok, its probably the item checks that are heaviest, i was trying to limit that before but it was causing errors, maybe ill just have to work on removing that part.
Maybe limit the items checked by range (Vector3.Distance) and/or by specific type (Apparatus) to help there. Seems like some kind of rework is needed at least
thats what i originally did.
deceiving looked for items no where near the ship, cunning looked for items only in the ship, and everyone else looked at all other items, but that led to errors, so i had to abandon that, and then later filter to remove from the full list.
and the "biggest" dilemma is, the code is there to find the "nearest" item.. so it checks through all to see which items are valid, and which one of the valids is closest... and as the masked moves around.. this item changes, so it needs to be re-calculated.
but, i have limited it all a lot now..
before
calculating paths to terminal/breakerbox/something else constantly as well as checking all the items constantly.
now.. it only checks them either.. when a new focus is required.. or when that specific item is being focused on (so, if changing focus (once every 5 mins ?) then it calculates.. and if its for example, focused on the terminal, it checks the terminal constantly
but that there in makes it check the items multiple times.. so perhaps what i need to do is.. once its focused on items.. and selected the item it wants.. it should not check the items again, until that item is invalid.
That is an alternative solution yeah
Could maybe make use of a data structure like a heap somehow to prioritise those known to be close, and update the item ordering randomly/periodically
How far you wanna go down either route depends on how much of the issue this causes and how much of that functionality you want retained
tbh, i dont really want to touch the item system at all... changing it before mentally destroyed my soul... items are the devil.
what can i say? masked have sticky fingers, wont leave items i tell them to put down alone... instantly picked them back up xD
but uh yeah anyway, i just tried making changes and being honest, im not sure the fps has improved.. 30-40fps drop with 8 masked, pretty sure it was better before xD
i think u mentioned twice the fps before with 8 masked
@patent swift whats the mechanic your trying to do?
just reading up on the fps issues
well, i calculate a few paths, and i check also what the nearest item is, and the path to that, and i do this now, whenever the masked change what their "focus" is, and if they have a focus... then the "target" of that focus is checked over and over.
back a few versions ago.. it was causing 20fps drops for the first masked spawned, now its like 10 for the first masked spawned, and the subsequent masked are less drops.
of those 20, 10 were from the item check, 10 were from the other path calculations.
ive since made optimisations and mitigations to reduce the fps loss, but seems the item check is still a problem.
how are you doing the item check?
well its old code from masked AI revamp.
in MAIR.. when a masked wanted an item, it would "grabitem()" and loop through all items, and then find the closest valid item.
since mair, ive put in pathing improvements that check a path is valid, if its not, then it rules out that "focus", because i found masked juddering around not knowing where to walk.
to do that, id id the same "grabitem()" loop through all items, but i did it repeatedly so if the nearest item was not accessible, then it would not focus on "items".
i did try to limit the list of items using linq, but errors started occuring when people picked up items mid-check.
whats problematic right now? finding the closest item or confirming a valid path to it
the checking of paths and the checking of items are run together, but i found that checking the items is half the loss, and the checking the non-item paths is the other half.
in the current version, i beleive ive already mitigated most of the drops, I was just checking out the suggestions by @twin epoch as using an invoke to run updates instead of a normal update() is likely also "heavy" on things, not as much as the calculations, but, more than a normal update() should be, was checking out "fixedupdate" instead as i know that is lighter than invoking.
CalculateVariables() is the method which contains all the "fps dropping" checks, feel free to check it out.
the code in place right now as i say though, is the already improved code, im sure it could do with more improvements though.
might be worth having a coroutine where you have a physics sphere only looking for items via layermasking
then until you get those you slowly expand the sphere
tried co-routines before my current improvement i beleive, didnt improve the situation, if i remember right the overhead made it worse than invoking for overheads.
I will look into physics sphere and layer masking though, thanks for the suggestion as that sounds like it will solve the problem if it sounds like it does what i think it would 🙂
btw when it paths to the nearest item.. it’s able to know where it is without seeing it?
it’s not like hoarding bugs, which i think just randomly path around in its roaming state until it stumbles upon a item?
correct, because the deceiving masked, and the cunning mask, potentially need to grab the nearest item, that is actually far away, they kinda need to know where said items are, i tend to limit them actually focusing on items only when they are in range, but to know if they are in range, they need to know if a valid item is in range of them.
i guess you can also say, my mod/masked ai revamp is a bit more scripted than the AI in vanilla LC.
i give them choices, but once they have made a choice, they are following a script, until or unless something (usually a player) derails them from said script.
beyond that, the choices are unscripted and are chosen based off location compared to other objects in the game, there in leading to variation.
meanwhile vanilla AI has "states", and each state has various tied in actions for that state which define how it behaves with no clear focus or direction. (i think)
also in masked AI revamp.. the masked used to try to walk to an item, and if that item was the nearest one, and was through a door, they would just stand at the door forever unable to go through because its locked or w/e, it was this "standing still" things that led to me putting in the path checks for everything.
comically, masked AI revamp had FPS drops before i added in all these calculations/etc, so i will be surprised if i can truly get rid of all the fps drops.
so my numbers were a bit wrong before, which is why FixedUpdate wasnt working as i hoped.
if memory serves..
-- Update originally dropped my FPS from 110-120 to 70 when 1 masked was outside,a nd with 8 masked, it was like 40-50 fps... as 100 fps this is 100 updates a second, with 100 calculations per second.
-- i tried coroutines, but they didnt work, i remember now.. the coroutine would not update the variables 😦 but this is also heavy.
-- InvokeRepeating.. was running this at 1 update per 0.1s.. making 10 updates per second, with 1 calculation every 5 seconds... this had big overhead (supposedly) because invokerepeat is heavy.. was getting 80ish fps with 1 masked.
-- FixedUpdate.. got my math wrong here, thought it was every 0.2s, but its every 0.02s.. so updates 50 times per second... ive set this as 1 calculation every 5 seconds, like i did with invoke repeating.. and im seeing a drop from 110 to 95fps.. the best result so far i think.. unless my pc was having an exceptionally good day or something.
so yeah, even before looking into the item search function, fps is looking better going forward in the next update unless im very much deluded. xD
you’ve changed the update rate of FixedUpdate?
does that not affect other things in LC that use it on its default update rate?
that does look promising so far
but yeah FixedUpdate is normally 50 updates a sec
@patent swift you know you can make your own frame based timer and only run the code eg every 60th frame
You can even do it with InvokeRepeating I guess
theres no reason not to use update or fixedupdate
no, im using fixed update.
maybe, but i switched away from frame based timing for a reason. I was already trying to limit it so it ran every 50 frames etc.. but the simple fact is, when your fps is 200, vs your fps is 30, your computer will have bigger frame drops when your load is heavy, so i figured making it so both 30fps and 200 fps have no frame drops is better, so I had it running 10 times per second on invoke repeat and made the calculations even less often. but invoke repeat is heavy, so actually causes some fps drops..
so.. weirdly...
invoke repeat @ 10 updates per second
has more fps drops than
fixedupdate @ 50 updates per second
which is why im now using fixed update.
so yeah, im using fixed update as is.... what im changing is this.. before the calculationdelay was 50, but now the updates are 5 times more frequent, i made it 250 to keep it the same for the calculations. it basically loops through this and does nothing 250 times, before actually doing something.
if (calculationDelay > 0) { calculationDelay--; } else { calculationDelay = 250; //calculations go here }
you can make it frame independent
coroutines? they dont work for my scenario.
fixedupdate is already kind of frame independent as it doesnt run every frame.
I have a project that uses, in many instances, a simple counter in the Update() method. Here's a typical example:
public class Spawn : MonoBehaviour
{...
thats what i was already doing, it didnt achieve as high an fps as im getting now.
that would just depend on how long your waiting
ah okay so that’s what ur doing
admittedly, i didnt do it 1 every 5 seconds.. BUT thats because its harder to calculate 1 every 5 seconds when your fps changes per person, which is why i switched away from fps based timing for the update, i know i can use delta time, but i didnt know that at the time.
u didn’t try out DoAiInterval?
either way, unless fixedupdate proves to be too slow an update, happy with that atm.
That’s fine homie, that’s why I was letting you know about it 🙂
and considering its quicker than my invokerepeat that i was doing.. it should be quick enough.
Performance of Update & FixedUpdate on it’s own won’t be a concern. Only thing that you may run into is that FixedUpdate runs before Update, nothing particular im pointing out but worth keeping in mind incase anything comes up
thanks, i learned about delta time 10 minutes after changing away from using "update" xD but the simple fact is, 200 updates per second for someone on 200fps, may just be too much to prevent frame drops, if i am going to delay everything using a timer, i might as well just use fixed update.
Absolutely
something like this probably only needs to run once every couple seconds at most
yeah i know that, but ill cross that bridge if it comes to it.
but-but what about DoAiInterval? 🥺
the calculations? yeah.. 1 in 5 seems to be fine. the rest needs to run more often.
why? 😛 why do i need DoAIInterval?
from what i heard it’s what LC enemies use to update their AI and the update interval is customizable
someone said the worm’s AI is like 10 updates a second using it iirc
zeekers uses update, and doaiinterval.
i could put the calculations in "doaiinterval", but i just see no need as of now, im not a fan of fixing whats not broken xD
true
now performance is better, so that means more room to do more ambitious things with the AI right? 🕺
i mean... im already adding in the masked taking your player ship away... what more ambitious do you want? o.o
but uh, yeah, working on things that arent working as intended, stops me adding new things.
Last update.. i hope, is working fine, no reports of breaks yet..
Next update.. adding more features to insane which seems to be 99% working..
got some bracken stuff in the pipeline already working, but very basic.. not sure how im going to do some of my ideas there
also got plans to make deceiving more.. "human like" than the other masked..
crouches around dogs.. runs from giants..
im going to make the masked actually jump as well, the code has always been there.. but they just levitate over gaps like other monsters do right now xD
the masked actually jumping across gaps would be huge
it’s so obvious when they just slide across lol
yeah i know.. as i say, already knew the "jump" animation.. but, it was just never linked to anything ever. now i just need to understand how to make them know when to jump, then implement it into their movement animation selection so they can both run+jump and walk+jump correctly at the right time (no bunny hopping madness)
besides the jumping thing
i don’t remember exactly, but i also think maskeds don’t have a climbing animation for ladders? or am i wrong?
forgot about that tbh xD but thats a bit more complex. as the masked dont just jump up them 😛 i assume they have an animation to grab ladders like players do, but im struggling to get the masked to grab the ship lever, once ive done that, ladder willbe next i guess.
well finally got the masked to jump over a gap instead of just teleport.. BUT.. they bunny hop on mid air now.. so this is going to be fun..
I feel like this can be an addition to all monsters in general 👀
im not sure all monsters have a jump animation xD
Metarig is players/masked 😛 so if a monster is based on the masked model/metarig, then it sure can xD
but if people wanted to develop animations for the other monsters for jumping, then yeah, using the same could would work.
ok.. thats wild... put in some random numbers.. and the masked jumped PERFECTLY from ledge, to beam, to ledge.....................................................................but then bunnyhopped for the rest of existance..
i dont have any way of recording right now.. but... seems i might have it working... (jumping over anything the navmesh register as an empty space/jump spot.)
i dont think they jump over the fence though...
W
what if they just have a chance of jumping randomly when sighting u
cuz masked "can't jump"
probably something to add to "deceiving" when i add in things to make them seem more like a player... like jumps in shock.
still needs a bit of tweaking + it doesnt really account for stamina.. i just have it pausing to simulate recovering its stamina before jumping.... + it jumps backwards/sideways.. cause its a weirdo..
1 step at a time + i also need to sort out licencing because law.
Once you do some tweaking
This will be peak
unfortunately, the way im doing this... may not always work x.x
the gaps are usually marked as a mask of 0. (nothing).. so i was checking for the mask of 0.. but i just went to test and a mask floated accross.. mask was not 0.. (or 4, which is jump).. so it seems the possibility of this is limited by the map generation assigning the right mask.. which apparantly.. for some reason.. is flaky.
so u still gotta figure out a more reliable way to detect gaps
obviously it isnt perfect in that video, but wow thats good progress! ur getting closer
better way to detect gaps.. if even possible, only ways i know exist, i think.. is the navmesh mask, or detecting for a "navmesh link", which i dont even know if those gaps count as a link as i havent looked into it.
the mask does work.. just.. for example.. the masked just floated accross a gap, then AFTER the gap found a 0.. so jumped.. on a normal walkable area.. lmao.
its just all making diagnosing if the jump looks normal/correct.. a lot harder.. because i cant just see the masks as i walk around, i have to log the mask's and check the logs afterwards..
but yeah, it is closer.. but i may just have to put this on hold. spent a lot of time on this, but want to get an update out before the weekend as im away for almost 2 weeks due to a work trip out of the country.
starting to get a queue of things i want to do but cant finish 😦
comically.. looked up the link way.. and found this.. which mentions "activatejump".. should have known people would need similar.. lol
https://stackoverflow.com/questions/40963955/detect-an-offmeshlink-without-using-an-agent
agent??
agent = NavMeshAgent, which allows entities to move.
good answer. u almost outed urself as an fbi agent.
i cant out myself as an FBI agent, then i would also be outing myself as a double agent.
i am outing myself as an A.A.H.W agent
I think it was a game, am I right?
MADNESS: Project Nexus is a third-person Run n' Gun / Beat'Em Up filled with arcade-style action and button-mashing brutality. Shoot, stab, bash, chop, and slaughter your way through over 16 hours of intense combat. Your wits will be challenged. Your nerves will be tested. Blood will probably get all over everything... what a day to leave your r...
$21.24
12889