#Model Replacement API & SDK

1 messages Β· Page 6 of 1

median rain
#

Maybe take a look at the model transform hierarchy.

#

I've seen some models that were designed to work with blender rigidbody physics that were full of random garbage.

long briar
#

well what do you consider random garbage

median rain
#

Everything other than the armature and model.

#

You know the armature is the set of all a model's bones, and the model itself has a skinnedmeshrenderer and perhaps an animator, but sometimes there's other stuff attached to the bones other than other bones.

long briar
#

can things become wonky if there are too many bones?

#

because the model is stupidly overcooked

#

it does have like 19 vertex groups/bones per leg

#

same thing for the arms

#

it is super cluttered

median rain
#

It's just the first thing that came to mind. It's really hard to say since they have so much going on behind the scenes.

#

If you can get rid of those without ruining it, it might be worth a try.

#

Supposing it's worth the effort, anyways

long briar
#

well i already had to modify the rig to get it to work for lethal to begin with

#

so ye i could do that

median rain
#

Also if you hadn't already, I would recommend looking for a possible duplicate in unity explorer.

#

Or if not, you can go into the model and disable things until you find what causes the lag

long briar
#

i did delete the shape keys and i do disable animations when exporting it to fbx and i have no idea what else it can have

median rain
#

Well, give disabling things a shot.

#

Actually that's probably going to be way faster than just looking for random things to cut out

long briar
#

well, what do i disable? just random parts of the model or what do you mean by that

median rain
#

I would start by disabling the entire thing and confirming that the lag goes away, for one.

#

Then you just go down the hierarchy until you can isolate what causes it.

#

Like, start at the waist, then do the lower body, then upper body, then head, etc..

#

With luck it's not just the whole thing that's cursed. I've tried out tons of models and never got anything close to performance issues without physics.

long briar
#

well, i can do all of that but probably not this week anymore lmao. ive spent 3 days with this model, running into issues everywhere, at this point almost the entire model is custom weight painted, some textures are custom made and the rig is modified too. i kinda feel a bit burned out on this thing rn

#

im doing something where i actualy get something done for a bit

median rain
#

I really feel you on the taking a break part, except my break has been months now.

long briar
#

i mean

#

i dont do modding anymore outside of my vacation

#

when i get home from work i have like no motivation for anything lol

median rain
#

Real.

elder hill
#

You can have a life outside of modding?

long briar
#

if you consider work a life

elder hill
#

fair

long briar
#

dahell is the problem here

#

unity keeps selecting the thump bones for the index finger and the index bones for the thump wich is just wrong and looks broken, manualy changing them to be correct also makes them look broken but now shows them red

long briar
#

ok i found the enforce T-pose button

#

dunno why it didnt just do but whatever

#

but it still doesnt fix the pose

#

theres still something off

#

now it does

#

i hate everything

full hollow
#

could you fix the shadow having this weird extra head?

grim scarab
median rain
#

@full hollow I don't really mod anymore. Life got busy, and I also work in software full time, which makes my desire to mod even less. If you hadn't noticed, basically all the updates for the past several months have been from PRs by extremely generous gigachads.

delicate glade
#

not sure where else to ask this but theres no solution to this happening with jiggle physics yeah? when the model moves a lot in a short timeframe (ship leaving, entering facility, etc)

#

i assume its just a funkiness ill have to live with but figured id ask anyways

grim scarab
#

Because the jiggle physics still account for movement while the player is being teleported to another spot

#

(Teleported meaning any time the player's position is set specifically, not actually using the teleporter)

delicate glade
grim scarab
#

Best solution i can think of for stopping it is turning off the jiggle physics components during teleports but there isn't really a unified way to know when you're being teleported

#

And its a lot of work for something you'll see 1% of the time you play

delicate glade
#

yeah makes sense

harsh cosmos
#

any idea on what causes this error on a modelreplacement when starting the game?

delicate glade
#

im going off of memory here and i forget if its already been fixed but there was this bug i remember seeing where theres a vertically stretched employee head over the model replacement head, anyone recall that or know what causes it? ive seen it quite a few times and always forget to screenshot

little sandal
#

has there been any large auto generated project changes over the past few updates?
updating femmployee and having lots of strange issues with the mod in game.

my project was generated a good while ago and has been built on since then, so wondering if that could be why.
no direct errors in code though, just some new unity errors when building my asset bundle, unsure if its that or not but cant get the error to go away though so just looking elsewhere.

#

ah,, old build works just fine with latest model API, so no not that nvm

median rain
median rain
median rain
#

Honestly I wish I knew enough about unity to fix that one, but the SDK is basically a black box at this point, and I 100% know that I'll break everything if I touch it again.

little sandal
#

Yeah I know it was something being stupid lol, the issue went away without warning and the things that I thought were symptoms are still present

#

The issue persisted on both unity projects too, so whatever cased it, caused it from my old untouched project all the same as the new one. So something really wacky I think on my pcs side went down

harsh cosmos
little sandal
#

hey howdy!
dunno if you remember but a while ago i came here about my mod having a frame drop when my MRAPI suit was on, about 15~20 fps.

with lots of help i was able to track it down. from what i understand its code in ModelReplacementBase.LateUpdate() and ManagerBase.Update() causing my drops.

figured i would let ya know!

grim scarab
little sandal
#

im not sure, @limpid pebble was helping me. from what they said just stuff running every frame.

#

they had me prefix return patch out LateUpdate() as a test and that made the FPS better with the suit on. and i did not test it but was told ManagerBase.Update() was the other half of the FPS drop

grim scarab
#

wouldn't patching out lateupdate stop your model from following your body

little sandal
#

dont know, was just doing profiling

#

you can look in #dev-general thats where they helped out

#

if they pop in here at any point i am sure they can explain it better than me, they were looking at source

limpid pebble
#

point was to test what components cause the most performance reduction

#

I can't say I know what specifically causes those methods to run so slow, but I have a number of critiques for them that would likely improve things if they were addressed

little sandal
#

could be worth chucking an issue up maybe?
something more proper than discord i guess

limpid pebble
#

I think people are more likely to see it here tbh

little sandal
#

yeah fair nuff

limpid pebble
#

I don't think Bunya has any interest in doing a deep dive to optimize it, but the more people that see it the more likely someone will be to decide to make a pull request

little sandal
#

thats what i was thinking

limpid pebble
little sandal
#

mh that was a msg i was looking for lol

grim scarab
limpid pebble
#

what I would do:

  • Think about the complexity of the methods that are doing these searches, try to use dictionaries or other O(1) operations wherever possible
  • Make sure that all Unity runtime properties (especially active state) are only changed when needed, rather than every frame
  • Cache components
  • Stop using linq!!!
grim scarab
#

since mrapi seems mostly maintained through prs anymore

limpid pebble
#

yeah

little sandal
#

well if this gets a PR i would love to be alerted!

#

that would be a huge win lol

limpid pebble
#

if I get especially bored at some point I might think about doing it myself, but for now I'll leave it to anyone else feeling adventurous

little sandal
#

its not a super huge FPS drop for a high end rig, but someone running a semi large pack on a mid range pc, would for sure cause issues. at least in Femmployees case

limpid pebble
#

if I did though, my PR would probably be massive lol

#

it's definitely nowhere near insignificant on my machine, and it's pretty high end (for 4 years ago at least)

little sandal
#

i mean even mine its about a 25 FPS drop at its worst

#

so yeah ig it can be bad

#

but i dont mind low FPS, 15 is fine to me, just a lil chunky lol

limpid pebble
#

it was about 16% reduction for me

little sandal
#

oh wow

#

thats a lot

limpid pebble
#

kinda unacceptable imo for something so insignificant

#

gameplay wise

little sandal
#

yeah

#

i do agree

#

thats why i was so sad i never could seem to find the cause lol

#

if it could get a PR that would be super neat for all mods that run the API too. and thats a lot of mods at this point

#

very cool mod imo, would 100% not been able to help out tilted with the femmployee mod without it ❀️

long briar
#

Some suits that have some kind of custom code sometimes reduce my fps by like 40

#

Very basic and simple suits are usually at this 10 to 15 fps drop range yeah

median rain
#

Very good critiques. Personally I have never experienced frame drops, even when I used to play with 100+ mod modpacks so I never bothered with optimizations. If there's a lot of people with issues then I could look at optimizing some of this stuff.

limpid pebble
#

it's more of a death by a thousand cuts situation I'd say

#

plus probably some unoptimized models undoubtedly contribute to it too in some cases

#

but that 15% probably compounds for each person that equips a custom model, and in a larger lobby it probably makes quite a large difference

#

15% is a lot for something that should in theory be able to be nearly free (except for mesh skinning cost)

limpid pebble
#

it would probably be worth putting some profiler markers in to see where exactly the biggest slowdowns are, since my lists above are only hypotheses for the cause

grim scarab
#

My own experience running large lobbies with people who basically exclusively use modelswaps shows some big fps drops

limpid pebble
#

it's probably not near the most significant cost, but I avoid it wherever I can in the interest of reducing overhead

#

except when I'm doing things that are especially concise with linq and don't have to run every frame

#

also I should probably expand on my

(especially active state)
from that message, the reason I say that is because I've seen multiple times that toggling active state is incredibly slow, presumably because it has to walk the tree to notify every single child component that it has been disabled/enabled

I've found that caching the actual components I care about, even if it's basically all child components, and using that cache to toggle the enabled state instead is much much faster

little sandal
#

most people that have come to me about my mod have been people with lower end systems, or people that play with more than 4 people. it does really seem to compound the more people that have MRAPI suits on

#

would be nice to get some benchmarks from people with mid range/low end setups

harsh cosmos
#

can custom shaders outside of lethal company be used with a model or can i only use the builtin HDRP ones?

spiral cargo
#

liltoon works with Lethal, which is how you get anime/toon shaders

harsh cosmos
median rain
#

Use it on the model in unity, it should compile into the asset bundle.

#

Make sure you use the hdrp wizard to correct your model's shaders before you apply liltoon, though.

harsh cosmos
feral dawn
#

Hey folks. I'm running on terrible sleep, trying to set a gift up for a friend - custom player model etc. My issue is that when I use unity to generate the files using the API, it fails to generate the template bundle and templatebundle.manifest

I'm so tired and my laptop is so slow. Anyone just yell what version of unity you're using and I'll try a clean install with the most recent mrAPI.

In other news, the project I was using was giving compilation errors like 'Assets\Plugin.cs(1,7): error CS0246: The type or namespace name 'BepInEx' could not be found' Which I know is a critical component but I assumed that was primarily on the mod manager. I've clearly fucked something severely and just starting over. Got this working once two years ago and struggling to get back into it

grim scarab
#

and must be in hdrp if you weren't already doing that

feral dawn
#

Was in HDRP, but will try that unity version on the next attempt, thanks

feral dawn
#

Update: Had to delete and reinstall a couple things, but managed to unfuck things and get back into the groove. Bless

median rain
#

That's so frequently how it goes. Just another reason to hate unity

fickle raptor
#

hey! i was just curious if anyone knows how to do camera height for playermodels, and how one would do it?

median rain
long briar
#

It sucks anyways because every time I tried some of these models they had like an additional -10fps and the camera wouldn't reset to default if you swapped to a model that didn't have any camera modifications

grim scarab
#

When I worked on modelswaps I got the height changing camera to work and mostly be compatible with everything else, frame drop was cus the models were too detailed

#

Basically models have a delay of like 10ms before applying height change, and ondestroy resets the height change

nova fjord
#

Anyone know how to fix this? I’m making a character mod using the Maria Kanellis model from Smackdown vs Raw 2010, but when I test it in-game the model comes out all twisted. Even the default Lethal model looks the same, both end up broken. Any ideas?

grim scarab
#

for starters are you on the correct unity version 2022.3.9f1

long briar
#

Can you show how it looks ingame

earnest matrix
#

does anyone know how can i add black mask/alpha texture to models? need to apply transparency to her hair and lashes

elder hill
earnest matrix
elder hill
#

Well a couple things, surface type needs to be opaque, you need to turn on alpha clipping, then go to the texture settings and enable alpha

earnest matrix
#

is there any way to select all these hair skeletons at once? it's a little bit annoying selecting one by one

fierce crescent
#

Hi guys! Could someone tell me what is the correct mod packaging structure in order so submit my custom model to the thunderstore?? Thanks in advance

grim scarab
#

If you have a suit texture to assign the model to, add plugins/MoreSuits/yoursuitname.png

#

The lethal mod wiki i think has info for formatting manifest

fierce crescent
#

Sorry for late reply! I was able to fix it. Everything regarding that was okay, I just commited an error while taping something in the code, but now works fine. Thanks anyways!!

solid trout
#

I dunno if this is the correct thread for it, but there's this weird thing now with Masked enemies using suits where the Employee badge is showing up recently. Not sure what's causing it

old field
fierce crescent
#

I have added jigglephysics to my modelΒ΄s tail, but it doesn't collide with the ground and it goes underneath the ground. Is there any solution for this?

grim scarab
#

No

#

You can curve the tail and reduce gravity in jiggle physics component but there isn't a good way to make it collide with the ground

fierce crescent
#

Solved, thanks!

delicate elk
#

Hello

Me and my friend are trying to import models from Fire Emblem Three Houses but we've been running into a lot of issues regarding them (eyes not having their textures, origin points being off, etc.)

It may be a long one since me and her are both trying to figure it out and we're both on the server so do any of you want me to move this into a thread or something else?

eager mural
median rain
fierce crescent
#

i am having a little issue with the thumbs in this model. i have seen this in other suits. Does anyone know how to fix it??

#

this is the rig

eager mural
fierce crescent
#

where should that be??

long briar
#

The way it is in that picture

#

Since that's in unity just do what unity wants

fierce crescent
#

ohhh ok

#

thanks!

upper dagger
solid trout
#

Could it be that it was always a "thing" and I only noticed recently?

delicate glade
#

anyone experienced textures not carrying into ingame? ive got a bunch in the same mod where the textures work just not this one, not sure why

#

material, and texture

#

though i doubt its an issue with the material/texture itself

delicate glade
#

wait no it is??? i tried putting materials from one of the other model replacements and those worked??

#

thats so bizarre

#

ill try remaking the materials

#

wtf is going on remaking the materials still didnt work

#

😭

#

is it somehow the textures?? though that makes no sense

delicate glade
#

maybe they have a strange encoding..?

#

ill try saving them through photoshop under a diff name

#

what the fuck

#

😭

#

welp that uh... fixed it

#

my bad yall my files were haunted by the random number generator asset bundle ghosts

#

perfect!

delicate glade
#

damn wtf

#

so i added 1 more model (1mb uncompressed) and it added 13 mb to the mod size??? πŸ’€

#

im very confused

#

DAMNNN okay note to self dont import the mmd instead because that 6mb model will add 26mb to the mod size

elder hill
#

blendshapes can be expensiveo

#

check that

delicate glade
#

just checked, thats 1mb of it

#

FOUND IT

#

it was the normals

#

i set normals to calculate instead of import

#

11mb gone

elder hill
#

oh interesting

delicate glade
#

i would rather not have the normals of 1 model be larger filesize than the entirety of my 30 model replacement suit mod

#

thanks tho! was literally checking that as you sent

#

couldve 100% never gotten that

obtuse nebula
# elder hill blendshapes can be expensiveo

So true, my mayu model was like... 60+mb or something like that because of all the blendshapes it has for VRChat lol stripped them all off and removed 80% of the file size

median rain
delicate glade
#

😭

grim scarab
#

does this mod work in v73

solar bramble
#

Mine havent had any issues tbh

#

and I migrated over to v73

grim scarab
#

Good to hear

long briar
#

mrapi the immortal mod that never breaks and works flawless RWStrongCat

median rain
#

I think I've broken it more times than game version updates, to be honest.

cosmic narwhal
#

Hello. My sincerest apologies for requiring asistance with this mod. I followed the entire guide in the mod api and some video tutorials and overall everything went smoothly. However, when I load up the game, my character model is invisible. The annoying part is that there's no error message in any of the steps I have followed. Is there another requirement I'm missing out regarding the models or the materials/textures? Or has this happened to someone else before?

upper dagger
#

hdrp/lit or liltoon

#

And there should be no missing materials on the mesh.

#

In some cases, the skinned mesh renderer under the skeleton can also cause the model to fail to load.

#

Also the bounds of the skinned mesh renderer

cosmic narwhal
# upper dagger hdrp/lit or liltoon

Yep. The skinned mesh renderer didn't work but it was the shader indeed. For some reason hdrp/lit was not working. However, I downloaded the liltoon shader and it's finally showing in-game.

#

Thank you so much!!

spiral cargo
vapid glen
#

Hiya, I need your help fellas, I followed the video tutorial naqibam made, but when I loaded mod first it was just looking like default suit reskin and now the game refuses to start with this error. Could you help me?

long briar
#

The size of the DLL looks too small, maybe it didn't build the asset bundle properly?

distant spindle
#

Is it possible to replace the texture on a model without making a new unityasset? Say if I give a path in my mod for people to add their textures to, like MoreSuits does, but label them with their steamid or username and swap them out, sort of like how LethalVRM does.

` public new void SetAvatarRenderers(bool enabled)
{
base.SetAvatarRenderers(enabled);

        if (((BodyReplacementBase)this).controller.playerSteamId == 76561198012800532)
        {
            // Replace the texture on this avatar's material for personalization.
            Material mat = replacementModel.GetComponent<Material>();
            // Load the image from plugins\moresuits\advanced\VoidCat_Body_BaseColor.png
            Texture2D tex = new Texture2D(1024, 1024);
            byte[] fileData = System.IO.File.ReadAllBytes(System.IO.Path.Combine(Paths.PluginPath, "PoikSpirit-VoidCatCompany", "moresuits", "advanced", "VoidCat_Body_BaseColor.png"));
            tex.LoadImage(fileData);
            // And its emissive map from plugins\moresuits\advanced\VoidCat_Body_Emissive.png
            Texture2D emissiveTex = new Texture2D(1024, 1024);
            byte[] emissiveFileData = System.IO.File.ReadAllBytes(System.IO.Path.Combine(Paths.PluginPath, "PoikSpirit-VoidCatCompany", "moresuits", "advanced", "VoidCat_Body_Emissive.png"));
            emissiveTex.LoadImage(emissiveFileData);
            // Then assign them to the material
            mat.mainTexture = tex;
            mat.SetTexture("_EmissiveMap", emissiveTex);
            Debug.Log("renderer.GetMaterialCount(): " + replacementModel.GetComponentInParent<Renderer>().GetMaterialCount());
            Debug.Log("Customized VoidCat texture applied.");
            ((BodyReplacementBase)this).controller.gameObject.TryGetComponent<BodyReplacementBase>(out var bodyReplacement);
            bodyReplacement.replacementModel.GetComponent<Renderer>().material = mat;
            bodyReplacement.replacementViewModel.GetComponent<Renderer>().material = mat;
            bodyReplacement.replacementModel.GetComponentInChildren<Renderer>().material = mat;
            bodyReplacement.replacementViewModel.GetComponentInChildren<Renderer>().material = mat;
            bodyReplacement.replacementModel.GetComponentInParent<Renderer>().material = mat;
            bodyReplacement.replacementViewModel.GetComponentInParent<Renderer>().material = mat;
        }
    }
}`

Is clearly not the way to do it. The code runs, but the default texture is still there. I dunno if it's getting overwritten by a later call, I'm grabbing the wrong renderer (nuclear option level of grabbing everything didn't work), or it's even the right way to swap the texture image to begin with.

My UnityProject for this one is gone (by accident), and I don't want to start over.

eager mural
safe sage
#

Hello, would it be possible for someone to show me how to make a simple model replacement mod for the game?

distant spindle
#

Here's the newest one.

long hinge
#

damn no need to ping me lmaoπŸ˜…

distant spindle
#

I think at least.

distant spindle
#

Thank you for the tutorials, by the way!

safe sage
livid tide
safe sage
#

how do I get the .fbx models from the workshop uploads?

distant spindle
eager mural
#

it uses steam sockets to sync between people who have it so host doesnt have to have the mod to sync and stuff

distant spindle
#

Ah. Just on default meshes? That's not a terrible idea for adding client side additional functionality to MoreSuits.

I really just need to know which model/renderer is the one that is actively shown for MRAPI, as the one (actually three) I swapped the texture on does not cause the shown model in game to change. I'll do a little more digging later.

vivid shale
#

is there a list of known incompatibilities? for some reason some models i have installed make me bug out and slide to the left whenever im crouching or using an emote from toomanyemotes

long briar
#

no, this tends to be a model issue tho

weary shard
#

Why do some mods that use ModelReplacementAPI not work

#

It doesn't show the models as models, it shows them as suits when equipping

weary shard
#

Ok, I tested on a different profile and it works just fine, that means there seems to be an incompatibility in the old modpack and I have to find which mod does it ( I am so tired of these mods not working 😞 )

versed berry
eager mural
#

indeed v80 probs will break alot of mods

long briar
#

Is there anything known about v80?

cinder oriole
#

not until either right before it drops or right asit drops

#

Zeekerss doesnt like giving warnings

pseudo furnace
#

Salutations! I was wondering if it's possible to have a custom model use a cutout shader? The model in question doesn't look quite right unless I change from opaque to cutout and adjust the alpha cutoff, but when I test it in game it seems to revert to opaque. Is there a way to fix this? I'm attaching a reference screenshot. Thanks in advance! <3

spiral cargo
#

In the image texture itself I have to make sure I have alpha is set to transparency

#

On top of setting the material from opaque to cutout

#

Should be a checkbox when you select the texture itself!

pseudo furnace
#

Got it! Not sure what the issue was the first time, but after a couple of attempts it looks perfect. Thanks for the help! <3

real thistle
#

Anyone know how to get modelreplacementsdk into unity? I have tried using git, and manual, but it wont import correctaly, I have unity failed to find entry points and error code 4 : Build asset version error: packages/com.bunya.modelreplacementsdk/bunya.modelreplacementsdk.asmdef in SourceAssetDB has modification time of '2026-03-25T00:09:12.0758226Z' while content on disk has modification time of '0001-01-01T00:00:00Z'

#

I already have reinstalled unity, restarted my computer, deleted library

#

I fixed it i think! right clicking on assests and reimporting seems to have fixedf it somehow

grim scarab
#

@median rain i dont know if anyone told you but this mod will probably need an update for v80

distant spindle
#

The new hand slot causes log spam with Model Replacement API. Seems to work otherwise (with my model at least). I haven't done more testing than that yet.

#

Lemme pull the logs and see what the spam was.

#
[Error  : Unity Log] IndexOutOfRangeException: Index was outside the bounds of the array.
Stack trace:
ModelReplacement.Patches.LocateHeldObjectsOnModelReplacementPatch.LateUpdatePatch (GrabbableObject& __instance) (at <b2c3a9c897704bec936a49e15eb643f1>:0)
(wrapper dynamic-method) GrabbableObject.DMD<GrabbableObject::LateUpdate>(GrabbableObject)
lyric marsh
livid tide
#

Only changes I can see on there that are different are things relating to the utility slot at least there won't be anything malicious

toxic gulch
#

hello hi, im trying to get a premade 3d model modded into the game following a tutorial for modelreplacementsdk and running into a problem with both the lighting and the pose. I got him in the game but any shadows make him unnaturally dark and the right arm is bent weird. this also happens in unity when i try to run it for both arms. any suggestions appreciated!

#

normal tpose when its not running

shadow path
#

Oh boy

#

Did this break with v80

solar bramble
#

Mine still look okay from what i can see, but i also haven't played it fully tbh

toxic gulch
#

I've made model mods in the past that have the lighting issues, but not the arm breaking. Those mods are still working on the latest version. Unfortunately I lost the source project files for those so I can't double check if there are any differences

#

The fact that the arms are also bent in Unity when I click the run button makes me think it's either something with the model or my settings that I'm not sure how to adjust

real thistle
#

no idea if the property is called shinyness or something else

harsh cosmos
#

does anybody know why, when building from unity, it just makes the cs and csproj files super fast without compiling the models to a file

harsh cosmos
#

ive tried with many models and on CachyOS and Bazzite so it might be a linux issue?

toxic gulch
toxic gulch
harsh cosmos
toxic gulch
#

You have generate new project on build checked on?

harsh cosmos
#

ill try making a dummy character from scratch in a completely new project and see if it works

toxic gulch
#

so for me I have LC path just set to somewhere in my documents, im pretty sure thats where it tries to save the project files. if you leave it blank it should open the explorer and let you select where to save it from there

#

otherwise it looks like you did everything else right

harsh cosmos
#

youre telling me i shouldnt have the lc path be the path to lc?

toxic gulch
#

i dont have it set to my path to lc πŸ€·β€β™‚οΈ

#

i think the idea is its supposed to save directly to your mods folder?

harsh cosmos
#

oh yea

#

changing that didnt work either

toxic gulch
#

damn yeah i got nothing then sorry :( i havent tried this on linux before

harsh cosmos
#

god damn it i dont want to buy another hard drive to reinstall windows

toxic gulch
#

remaking my model seemed to get the arm working but he still looks weirdly dark when not in direct light, any way to fix that?

harsh cosmos
#

ok i killed bazzite and installed windows 11 in the fertile soil of its corpse and the build thing is working now

toxic gulch
#

That really sucks it doesn't work on bazzite

grim scarab
#

like cachyos

#

it'll probably work better

obtuse nebula
#

Why angry studio

eager mural
#

Lethal updated some time ago to 2022.3.62

#

so its probs confussed about the dlls having diffirent signiture

#

from what the game dlls are compiled against

obtuse nebula
#

I have near zero coding knowledge, but I did eventually figure out how to re-reference what it was crying about. idk if I did it right though lol the assembly sharp is still mad though, don't know what to do about that

eager mural
#

so its a warning to ignore

#

but ye the issue was in packages well still is where it refrencing the old version of Unity

#

so you can either update it though the nuget manager to version 2022.3.62 or in that text file you sent earlier where they all are listed you can change the numbers from 2022.3.9 to 2022.3.62

#

but ye what you did works too

harsh cosmos
#

but in case you use cachy and building the project works for you, it gives me sanity that the workflow is possible on linux

grim scarab
#

It was more of a general suggestion tbh

#

Assuming the arch-likes would be a little easier to make it work than the fedora-based bazzite

#

Since the former is on the bleeding edge

#

So they would be getting their advancements first over the fedora-based and debian-based machines

harsh cosmos
#

@median rain are you aware of anybody successfully exporting from unity, running on linux?

solar bramble
#

having a minor issue where mesh is not moving correctly (socks not moving with the rest of the model) anyone know of a fix? Ive tried weight painting in blender, and merging verticies to see if its just face on face and still having issue

delicate glade
#

is there any way to add a config that disables the model AND suit from being registered? as far as i can tell theres a way to exclude the model and just have the suit as a config but not both

#

i know more suits has a disabled suit list, maybe its possible to add/remove the listed suit there..? unsure if thats possible though

paper sun
# lyric marsh https://thunderstore.io/c/lethal-company/p/qwcan/ModelReplacementAPI_v80/ should...

This got made to fix ModelReplacement-API for v80+ BUT - this v80 version doesn't show the players model with TooManyEmotes in third person. Always shows hands of models that require ModelReplacement API IF the config to generate a view model is enabled and sometimes the whole model is invisible or always if one uses a non-ModelReplacementAPI suit.
This stuff only applies to the v80 fix version.

Meanwhile, for the curious ones as to why v80 fix exists - the old ModelReplacement API breaks utility slot quite a lot:

  • spams errors if an item inside the utility slot is being held lowering the frame rate
  • causes items like the spray can, weed killer, probably the inhaler as well, to not work at all - they make visual effect, yes - but they don't use up their capacity nor affect the game, spray doesn't leave spray marks, weed killer doesn't do anything - so on, could apply to more modded items as well
  • many oh many items become blurry when held by a player (like what, the game can't decide where to put the item in the hand?, 3rd image)
    ^^^ these three ONLY apply to the current, old ModelReplacementAPI

ahh, i love writing reports.... anyway, is @median rain actually working on this or?... should I ping the one who made the v80 fix?

grim scarab
#

bunyas not working on it rn

#

they just dont really have time to spend on it iirc

#

it is MIT licensed though so it can be forked (like the v80 fix) and hopefully it lands somewhere with active devs

paper sun
twin sentinel
#

Hi there! Hopefully not breaking any rules asking this. First time using ModelReplacementAPI (and LC modding in general). I've successfully gotten a character in and switching blendshapes when using emotes. Does anyone know if it's possible to make the character blink when alive? I've tried searching but all I can find are gifs of blinking cats πŸ˜…

delicate glade
#

yeah just add an animator somewhere on the model and make an animation for blinking

#

what you can do to make it stop blinking on death is add some code per suit that finds where the animator is and forces it to play a different animation (closed eyes for example)

twin sentinel
#

Right. I've not made an animator before, but I'll give it a go. Thanks!

delicate glade
#

heres an example

#

basically i define the animator, then have an OnDeath() override where i find the animator on the replacementDeadBody

#

i have a trigger called OnDeath that transitions from the idle state off of it

#

personally i use it for tail and ear animations but you can do this same concept for anything

#

transform.Find looks through your model downwards like a file directory so just input what it would be for your model

drifting flax
solar bramble
#

do u need the fork tho? I find that the OG works okay. Unless theres something I am missing w my models

drifting flax
#

The OG isn't updated for v80, so it breaks when you use the new utility slot

solar bramble
#

AH

#

That's what I haven't done yet.

#

I have yet to actually play w the new utility slot sldfhlkjsdfhkl

drifting flax
#

I put the bare minimum effort into my v80 fork so use with caution

solar bramble
#

bare minimum still means a lot of time lets be real

drifting flax
#

It was like 15 minutes of work lol

twin sentinel
solar bramble
drifting flax
#

I made a PR for my changes but idk if the OG mod is even still being maintained

delicate glade
drifting flax
solar bramble
#

literally i barely can code and rely on tutorials so step above me

#

i know bare minimum of c#

#

but maybe oneday ill punch out shakespere nevertheless...

twin sentinel
delicate glade
#

it would just be put in with the assetbundle as normal

twin sentinel
#

These files I mean. They've exported properly now but he still doesn't seem to be blinking for some reason... I'll keep trying

delicate glade
twin sentinel
#

It plays properly in Play mode

delicate glade
#

If it's still not working honestly I don't know because that's all I did

twin sentinel
#

This is what I get in play mode.

delicate glade
#

Yeah should be identical ingame

#

As it would get bundled with the model when you build

twin sentinel
#

Hmm, well I'm out of time tonight. Thanks for the help anyhow. I'll try again tomorrow. Take care!

delicate glade
twin sentinel
# delicate glade <:TS_kotoneHeart:1219492862803312672>

Hello! I'm still having issues getting the blinking animator to work unfortunately. I can't seem to use your Logger code to verify it's there either. Could I possibly screen share with you here to see if I'm missing a step somewhere please?

delicate glade
twin sentinel
#

Okay. I appreciate any help you can offer.
It's complaining about being unable to access the Logger. I don't have an OnDeath state yet so I'm using the OnEmoteStart function to test it.

#

I'm not too familiar with Unity, but I think I've spotted a possible cause for the animator not working.
If I select "Body" in the scene itself, I can see the Animator component I've added.

#

But if I select the Body from the Asset Drawer (after clicking the arrow), there's no Animator.

#

It doesn't seem possible to add an animator on the Asset drawer reference, only on the instance in the scene.

#

The tutorial on github shows the Model Replacement Project with a "Scene Prefabs" option.

#

Whereas my one says "Asset Prefabs". Maybe when I build my project, it's pulling from the asset directly rather than the one I've placed in the scene?

delicate glade
delicate glade
#

thats just the mesh within the project files

delicate glade
#

theyre likely using an older version of the api that had it named differently

delicate glade
delicate glade
#

OnDeath is basically a function within BodyReplacementBase, which we are overriding

#

make sure to have base.OnDeath(); at the start so it runs the code from the original script as well

twin sentinel
#

Oh I see that's in the other .cs file. I'm very new to this, apologies.
Visual Studio doesn't complain about the logger anymore. The animator still doesn't seem to be working in-game with the "Avatar" removed, nor did the Logger print to the console.

#

I'm wondering if this has something to do with it

eager mural
#

like a null ref exception is harder to figure out

#

easiest way is using breakpoints via debugger

twin sentinel
#

I've fixed the null ref exception. It wasn't the animator.

#

Actually no. I removed the Logger stuff and the exception went away. I put it back and the error re-appeared

#

This is my OnDeath function. The blendshapes all work correctly on death, but I'm guessing I've messed up with the logger test trying to find the animator.

eager mural
#

so the null ref is the logger as its null

twin sentinel
#

Okay I've fixed the null ref logger, thanks. Unfortunately I've run out of time again this evening. Take care.

hushed saffron
#

most, if not all custom model mods are broken in vr when using LCVR 1.5.0

#

would the shader fix described in this document by the dev have to be fixed for each mod individually?

#

or could an update to the api fix it?

grim scarab
#

You might be able to ask qwcan to try fixing this in the v80 fork but idk

solar bramble
#

Anyone know about adding toon shaders to models?

delicate glade
#

no particularly special setup

solar bramble
#

okie

delicate glade
#

depending on the shader it might look different but yea

#

this is what i used

#

if you go to unity registry in package manager you should be able to find it iirc

#

both seemed to work

solar bramble
#

i love u

delicate glade
#

out of pure curiosity i wanted to try doing CTRL+A in my biggest model project

#

😭

#

the results were not disappointing

twin sentinel
#

πŸ’₯

twin sentinel
#

I'm still having problems with getting animations to work. I took a break from the blink and tried to make a tail animation, but that's not working either.

#

There must be something I'm doing wrong in Unity

twin sentinel
delicate glade
twin sentinel
#

Thank you! I'll hop in one of the chatting channels

obtuse nebula
#

Trying to figure out why my stupid model isn't working

[Error  : Unity Log] NullReferenceException: Object reference not set to an instance of an object
Stack trace:
ModelReplacement.BodyReplacementBase.LoadModelReplacement () (at <b2c3a9c897704bec936a49e15eb643f1>:IL_002C)
ModelReplacement.BodyReplacementBase.Awake () (at <b2c3a9c897704bec936a49e15eb643f1>:IL_0057)
UnityEngine.GameObject:AddComponent(Type)
ModelReplacement.ModelReplacementAPI:SetPlayerModelReplacement(PlayerControllerB, Type)
ModelReplacement.PlayerControllerBPatch:ManageBodyReplacements(PlayerControllerB)
ModelReplacement.PlayerControllerBPatch:ManageRegistryBodyReplacements(PlayerControllerB&)
GameNetcodeStuff.PlayerControllerB:DMD<GameNetcodeStuff.PlayerControllerB::Update>(PlayerControllerB)```
I setup my model, I click build project. I open the Mayu.csproj and click rebuild, I then select everything here and zip it, load it into Gale as a local mod.
obtuse nebula
#

If there's any ModelReplacement pros out there ❀️ i'd super appreciate the help

solar bramble
#

im not a pro but id check to see if asset name is correct in the code

solar bramble
#

o shit u might be right

eager mural
#

but also it is a null ref error so not sure if it would be because of your suit missing depends on the code that assigns it i guess

obtuse nebula
eager mural
#

well ye you have a null ref error

#

did you forget to tell unity to include the model in the bundle?

#

as null ref can be as little as a missing required value

#

but in your case it seems to say something about invalid assetbundle

obtuse nebula
#

This is the project settings

eager mural
#

so stuff must be missing in it

obtuse nebula
#

The prefab is referenced and everything's there

eager mural
#

ye that dont tell me anything xD

obtuse nebula
#

So unless it's outdated, things are broken or I did something wrong, i'd have no idea

eager mural
#

yes last edited 2 years ago

#

there been quiet a few game updates

obtuse nebula
eager mural
#

what i say lets add AssetBundles Browser to check if everything is getting added first

#

its made by Unity themself

#

you can install it using the git url via the package manager in Unity if you used that before

obtuse nebula
#

doing that right meow

#

I clicked Build again, and opened the browser and this is what it shows

solar bramble
#

meanwhile im having an odd error myself tbh

#

lmfao

#

bc it keeps erroring when I try to add a second suit

eager mural
#

when you run rebuild project does it actually replace the bundle in the project path?

#

well build project

obtuse nebula
#

I get this in the output

eager mural
#

ye that was successful

#

and that dll gives you that same error yes?

obtuse nebula
#
[Info   :MirrorDecor] Plugin MirrorDecor is loaded!
[Info   :   BepInEx] Loading [ModelReplacementAPI 2.4.19]
[Info   :meow.ModelReplacementAPI] Plugin meow.ModelReplacementAPI is loaded!
[Info   :   BepInEx] Loading [MayuModel 0.1.3]
[Info   :   Console] Mayu.MayuBundle
[Error  : Unity Log] ArgumentNullException: stream
Parameter name: ManagedStream object must be non-null
Stack trace:
UnityEngine.AssetBundle.ValidateLoadFromStream (System.IO.Stream stream) (at <60c13874e0e045b59e9d86f24a2d5c95>:IL_0009)
UnityEngine.AssetBundle.LoadFromStream (System.IO.Stream stream) (at <60c13874e0e045b59e9d86f24a2d5c95>:IL_0001)
ModelReplacement.Assets.PopulateAssets () (at <99508100641b41a2ab02c93a652654d3>:IL_004B)
ModelReplacement.Plugin.Awake () (at <99508100641b41a2ab02c93a652654d3>:IL_0012)
UnityEngine.GameObject:AddComponent(Type)
BepInEx.Bootstrap.Chainloader:Start()
UnityEngine.XR.Management.XRGeneralSettings:Awake()

[Info   :   BepInEx] Loading [More Suits 1.5.0]
[Info   :More Suits] Plugin More Suits is loaded!
eager mural
#

ye its failing when it gets to the loading part

#

to load the assetbundle

#

in the code for actually loading it is the names correct?

obtuse nebula
#

Could it be Assembly-CSharp looking angry? Or would that be unrelated.

eager mural
#

nah thats fine its the publicizer making it look mad

eager mural
#

might be easier like that

obtuse nebula
#

It's looking for this, and putting it in the DLL, right? is it case sensitive?

#

Because the DLL is the same size as that asset bundle so... i'd assume it is being properly put in the mod

solar bramble
#

i dont understand how yall can get toon shaders to look good. i legit cannot tell

long briar
#

@median rain i dont see anything breaking realy but these are being spammed every time i hold a utility item (flashlight weed killer etc)

left oxide
#

Will this get compatibility with cadaver blooms?

long briar
#

probably not

#

i think even the sapsucker still just spawns the default body when someone gets killed by it

twin sentinel
# eager mural https://github.com/Unity-Technologies/AssetBundles-Browser

If anyone was following my woes with getting animators to work - this was the fix. Installing the asset bundle browser revealed that my animations weren't being auto-packaged into the asset bundle. I was able to select the animations and manually add them to the asset bundle (in the bottom right corner of the screen).

#

Thank you for that πŸ’š

hallow cloak
long briar
drifting flax
#

Replacement

#

I submitted the changes as a PR to the original, but who knows if they'll be accepted ever

long briar
#

i pinged bunya so it should sooner or later

drifting flax
#

I wouldn't be so sure, last message was 6 months ago

solar bramble
#

rip

grim scarab
solar bramble
#

jdhlkasjf

grim scarab
#

Have fun fixing the issues with this api

drifting flax
#

It doesn't fix any other problems with the move to v80, just the errors when using the tool slot. There are still issues with other things, for example TooManyEmotes

solar bramble
#

o7

solar bramble
#

possible dum error on my end but I keep getting this message for one of my suits. Everything looks ok in code (no errors) and the asset bundle built correctly. It went from working to not working

eager mural
#

so a paramter isnt set

#

paraneter*

#

which one is it. it dont say

solar bramble
#

dies

#

i'll review everything again

eager mural
# solar bramble *dies*

also when coding your own stuff for the game when you build it you should also get a .pdb file if you throw it along side your dll into the mods folder and it errors out because of your code it will tell you which line πŸ˜„

solar bramble
#

i love u

eager mural
#

some people have it set to embedded so its just included by default inside of the dll btw

#

but it wont give you the answer every time xD

solar bramble
#

no error w that so its gotta be something in unity that im missing

#

IT WAS IN UNITY

#

nvm i did forget something in unity but its still throwing same error.... i spoke 2 soon....

eager mural
#

i have a suspicion to what it is but ye

#

without seeing the project its hard to tell

solar bramble
#

i just deleted the model entirely and remade it and that fixed it lmfao

#

probably something to do w the jiggle physics that I added but idfk it works now

long briar
#

do you have to use the old unity version from the tutorial or the newer one? i was thinking about making something again but its been a few months

solar bramble
#

I'd use the newer one. It seems to work just fine imo

#

old unity version had some security issues

long briar
#

what version was that again?

solar bramble
#

I believe its 2022.3.62f2?

#

as the most recent that is

long briar
#

looks correct?

#

i was so close to making a newer tutorial just for the sake of it

#

its so hard to understand this guy

#

can it be any 2022 version?

#

in the video it is 2022.3.9f1, you mentioned 2022.3.62f2, i got f3 and the latest 2022 version is 2022.3.75f1

#

well i guess ill just fuck around and find it

eager mural
#

f3 should work for you only difference between f2 and f3 is a UI fix if i remember from the changelog

#

which is editor only

#

ye doult either of those should cause you issuses

#

those 2 things are only differences between f2 and f3

long briar
#

models are invisible when emoting

#

models are visible with the original mrapi

drifting flax
#

Β―_(ツ)_/Β―

twin sentinel
#

I've been doing some experimenting today (fighting tooth-and-nail with Unity) to make my character's eyes not static

solar bramble
#

Damn howd you do it??? That looks awesome

twin sentinel
#

I needed to convert the character to a prefab first, which allowed me to add an empty object to the bone hierarchy. I called "LookAt" and parented it to the neck bone. On both eyes I added an "Aim Constraint" component and hooked them up to aim at the LookAt object. I moved the LookAt object to eye level and forwards a fair bit. This gives the eyes some movement during animations, because they're looking ahead at an object which moves similarly but not exactly the same as the head bone.

#

I just got voice working on a blendshape too! The shape affects the mouth and the cheek tufts for some extra movement

solar bramble
#

I gotta try that sometime. For real its so cool!!!

solar bramble
#

Ough my model's jaw will not move and everything looks correct, but I am also getting an error [Error :meow.ModelReplacementAPI] Could not set all model scripts. Error: Object reference not set to an instance of an object

#

so I wonder what I am missing. Path looks correct in unity too

#

maybe i mispelled something?

#

looks like 1 word was misspelled lmfao

#

too bad the model looks like this tho, with zero movement

#

gonna try playing with weight painting and see what happens

solar bramble
#

I also wanna try adding blinking tbh bc the concept sounds so cool

solar bramble
#

Still twisted.... Anyone have an idea why?

#

It 'opens' correctly, just not closing right

#

....setting start to 0f fixes it, but then it doesn't open.... i forsee a lot of toggling...

long briar
#

Every time I see models do this kind of stuff with blinking eyes and moving mouth it's like an additional -20fps wich is why I never realy looked into this (idk how this can even destroy performance this much but it's what I observed)

grim scarab
#

i did it with coroutines and using the blendshapes instead of rotation/position

#

granted idk if that helped at all

#

but its pretty hard to measure these

#

cus unless you package the exact same model and just have one of them not do the blinking code theres too many factors to take into account

#

biggest one being a variance in tris/poly count

#

also if a model has physics objects

#

those slow the game down a ton

long briar
#

I usually compare my fps to the default suit, - 20fps compared to the vanilla suit is average, suits with just 1 addition tend to have - 40 fps, I've had very rare occasions where I even saw - 50ish fps

#

Wich is fine solo but in a group of 5 ppl is kinda unbearable even tho the performance hit doesn't stack up like that

hallow cloak
#

Do not put on HSR sparkle model at 3am (-120 fps)

long briar
#

I remember alot of the genshin models doing - 40 fps simply for changing the camera height for smaller characters

#

I was looking into adding sounds to being damaged to my models in the past together with a friend who knows coding and a some help from here but I never actualy bothered trying it after seeing how poor models run that have any kinds of additions

#

I prefer the better performance while also doing less

hallow cloak
#

I had ran some tests by patching out some of the expensive stuff in this api mod, some had gains but i didnt feel they warrant the visual trade off/unmotivated as well at the time, I ended up removing them without diving deeper

long briar
#

Also now you can't even disable the shader for each model anymore since zeekers fixed the shader

#

Now all my models look dirty

#

Ugh

hallow cloak
#

nnmm im pretty sure theres a way

long briar
#

There's always a way

#

But who knows the way?

#

I dont

hallow cloak
#

I also dont, but the lethal star rail creator has found a way if the configs to be believed (I havent tested or played). They dont seem to be in the server, or if they are, theres like 15 people with the same name

long briar
#

I bet this just toggles the option we have in unity wich stopped working

#

When was this added?

hallow cloak
#

when it got updated to v81

long briar
hallow cloak
#

I think. I never paid attention, i had only downloaded this mod for testing purposes with unity camera layer hellzone

long briar
#

Ah

#

What mod is it?

hallow cloak
long briar
#

Ah this one

#

I can check later when I'm home

#

In like 2h KanamiCry

hallow cloak
#

Best of luck, im caught up with other stuff right now but ill keep an eye out for your resukts

delicate glade
#

Though I'm a bit concerned if that fps is true lol though I can't see how that could be the case

long briar
#

I can check when I'm home

delicate glade
#

Much appreciated!

hallow cloak
delicate glade
#

If it's possible id like to make it a config disabled by default

hallow cloak
#

that would be ideal, the quirks im thinking of are erm, unable to climb ladders due to being too small, not sure how this happened but it fixed itself after reloading the lobby, second one, small visual bug with items that have canvases on them

delicate glade
#

Interesting

#

Like the bag holder thingy?

#

Item uh bag

#

Belt

hallow cloak
#

World space ones

#

I got a screenshot somewhere, a sec

delicate glade
#

Also for ladders do you mean if the ladder is suspended above the player? I assume with this method the grab position comes from around the camera

#

Otherwise I can't see not being able to reach the ladder at all but maybe I'm missing something

hallow cloak
# hallow cloak I got a screenshot somewhere, a sec

not really something 99% of items have to worry about to be honest, they look normal on the floor/with normal sized player model. ive tried fixing this with a few methods i came up with, but i dont really know what to do about it

hallow cloak
#

but no, it was every single ladder, even the one on titan but did work when i swapped to someone... larger

#

BUT only happened twice in all my... short time using it so im not sure if its too valid of a worry

#

but the interaction being disproportionate to where youre actually looking is a real thing

delicate glade
#

Interesting okay I'll mess around, thanks for the insight!

#

Personally I'm fine with the debuffs as long as it's clear what's happening

#

It's only if something isn't working that feels like it should that's an issue

hallow cloak
#

I see that, i agree with you with you under the context of this mod anyway. the only true issue is the hit to performance, it is tolerable but it can be real brutal

delicate glade
#

Yeah that I'm most worried about

#

Especially since I've already gotten performance reports without that feature despite my mod being very light

grim scarab
#

ill pull up the code

#

oh boy lets see if i remember how these work

#

CameraVisuals.cs

using BepInEx;
using BepInEx.Logging;
using GameNetcodeStuff;
using HarmonyLib;
using ModelReplacement;
using UnityEngine;

namespace CamVisuals
{
    [BepInPlugin("MRCameraVisuals(name)", "(name)", "1.0.0")]
    public class CameraVisuals : BaseUnityPlugin
    {
        private readonly Harmony harmony = new Harmony("CameraVisuals(name)");

        private static GameObject gameObject;

        private static CameraVisuals Instance;

        public static Vector3 baseSize;

        public static ManualLogSource mls;

        private static bool usingCameraVisuals;

        private static bool terminalDisable = false;

        private void Awake()
        {
            if (Instance == null)
            {
                Instance = this;
            }
            mls = base.Logger;
            harmony.PatchAll(typeof(CameraVisuals));
            mls.LogInfo("CAMERA HEIGHTS LOADED");
        }

        public static void DetectCamera(PlayerControllerB player)
        {
            gameObject = player.gameObject;
            Transform childTransform = gameObject.transform.Find("ScavengerModel").Find("metarig").Find("CameraContainer");
            if (childTransform != null)
            {
                GameObject childObject = childTransform.gameObject;
                if (gameObject.GetComponent<MR(name)>() && !usingCameraVisuals)
                {
                    gameObject.transform.Find("ScavengerModel").Find("metarig").Find("CameraContainer")
                        .Find("MainCamera").Find("HUDHelmetPosition").localPosition += new Vector3(0f, 0.005f, 0f);
                    gameObject.transform.localScale = new Vector3(1f, 1.185f, 1f);
                    usingCameraVisuals = true;
                }
            }
            else
            {
                CameraVisuals.mls.LogInfo("Child GameObject not found.");
            }
        }

        public static void StopUsingModel()
        {
            usingCameraVisuals = false;
        }

        [HarmonyPatch(typeof(Terminal), "BeginUsingTerminal")]
        [HarmonyPostfix]
        public static void DetectCamera2()
        {
            PlayerControllerB local = GameNetworkManager.Instance.localPlayerController;
            baseSize = local.gameObject.transform.localScale;
            if (!terminalDisable && usingCameraVisuals)
            {
                gameObject.gameObject.transform.Find("ScavengerModel").Find("metarig").Find("CameraContainer")
                        .Find("MainCamera").localPosition += new Vector3(0f, -0.31f, -0.018f);
                terminalDisable = true;
            }
        }

        [HarmonyPatch(typeof(Terminal), "QuitTerminal")]
        [HarmonyPostfix]
        public static void ResetCamera()
        {
            PlayerControllerB local = GameNetworkManager.Instance.localPlayerController;
            if (terminalDisable && usingCameraVisuals)
            {
                gameObject.gameObject.transform.Find("ScavengerModel").Find("metarig").Find("CameraContainer")
                        .Find("MainCamera").localPosition -= new Vector3(0f, -0.31f, -0.018f);
                terminalDisable = false;
            }
        }
    }
}```
then add this to Start() in BodyReplacements.cs
```cs
if (childTransform != null)
{
    GameObject childObject = childTransform.gameObject;
    if (!usingCameraVisuals)
    {
        usingCameraVisuals = true;
        Task.Delay(50).ContinueWith(t => CameraVisuals.DetectCamera(player));
    }
}
else
{
    CameraVisuals.mls.LogInfo("Child GameObject not found.");
}```
where usingCameraVisuals is a public bool taken from Plugin.cs
#

this should be right

#

iirc this code got a performance improvement passed in CruiserImproved because it was setting camera position every frame even when not in the cruiser

delicate glade
#

Okay yeah something like that I would expect to impact performance I just didn't think it'd actually be coded like that

grim scarab
#

this code itself shouldnt be that bad on performance since it runs in Awake and postfixes terminal stuff

delicate glade
#

Sweet

grim scarab
#

i guess the others run in update or something

#

who knows tbh, the star rail models probably have shitloads of polys because mihoyo

#

and id think with so many of them in a pack theyre probably not decimated

delicate glade
#

The blendshapes too can get steep quick

#

My Uma model extractions take over 100mb each with them on

#

But disabled is under 1mb

#

Not sure why exactly

grim scarab
#

yea i guess because it has to include every variation possible by the blendshapes?

#

beats me

#

the models i worked with had the cam code, blendshapes, high poly model, physics objects, and voicelines

#

idr how bad perf was but this was in liek v69 and i tested in a profile with no performance mods and imperium enabled

delicate glade
#

TS_phoenixThink ic

#

I'll mess around when I get home from work, thank you as always!

grim scarab
#

yup

twin sentinel
#

I didn't notice a performance hit with my model. I ran with a crew of 6 yesterday and we all tried it at once. Seemed fine.

#

The only thing that didn't work was setting blendshapes for emoting. Works fine locally but over a network game my friends didn't see it

long briar
#

^genshin models guy also figured out a way to make the models clean again

#

performance hit is also not as big as it used to be but its still there

#

i tested this one just now

#

can use any model mod from him tho

#

he also fixed some other issues that used to exist back then

#

like the camera not resetting when changing to a model from a different mod that doesnt have a custom height

#

it resets now wich wasnt the case in the past

#

i do wanna know how he got the models clean again

grim scarab
long briar
#

ye the HSR mod reduces my fps by 50

#

from 200 to 150 in orbit

#

not even comparing to vanilla suit and rather to another modded suit from myself

#

but the hsr models are also clean

brisk wagon
long briar
#

can you write it down in more detail at some point throughout the week? atleast the render queue stuff

brisk wagon
# long briar can you write it down in more detail at some point throughout the week? atleast ...

Uhh, I've been switching my models over to use the Unity Toon Shader from my previous setup, which just has an option to set it at a value. Transparency starts to kick in at 3000, so I've been setting all my materials to that, or 3100 if they still need some additional transparency.

If your shader setup has an option for z-write I'd try enabling that as well so that the models are transparent by technicality but you can't actually see through them

delicate glade
elder hill
delicate glade
#

not really sure what getting "childObject" does here

#

i guess just making absolutely sure it doenst run multiple times..? though its a start function so idk how it would

#

also rewriting how i do BodeReplacmeents.cs since having 79 suits is getting tiresome

#

idk why i didnt do something like this sooner

#

well ig that assumes this works

#

instead of having massive blocks of code for every suit just call one other class that handles everything and give it the necessary info per suit

#

is this configured for like a suit by suit basis?

delicate glade
#

theres really not much im seeing that can return null

#

and the fact every suit works perfectly until you try on a different one is interesting

#

actually where is usingCameraVisuals even set back to false

#

actually why does that bool even exist

#

and why does every .Find have many nested .Finds instead of just one path

elder hill
delicate glade
#

my only guess is maybe it was designed as an update function or smth kinda thrown together

#

but when ported to a single call all the code was kept

#

actually

#

maybe this camvisuals thing is persistent so when i grab a new suit that bool stays the same

#

so id need to call this function to reset the bool

#

is my assumption? TS_phoenixThink

#

but even then idk why it would return null somewhere

#

hm im not sure what i really did but i cleaned up the code a bit and now its not erroring so uhh

#

ill try adjusting some heights and see if it seems to work

#

okay interesting

#

i have learned that the position actually does absolutely nothing

#

its the scale that controls everything i think?

#

confirming rn

#

oh wait

#

OHHHHHH

#

ITS FOR THE HUD

#

DUH

#

gonna try this code

#

basically each suit i have a float representing the models approximate height, relative to the base player model which i am assuming is 173cm because i said so

#

based off that we do some automatic calculations to infer the models scale relative to the defualt suit

#

luckily i already set up a measuring tape in my project for exactly purposes like this lmao

#

i scaled it so it aligns with the default player model on 173cm, so that i can scale every other model accordingly

#

in theory this means i can automate all of the height based code with just a float that represents the models height

solar bramble
#

game changing for some of my models tbh

#

i rely on a camera adjuster mod to manually do it

delicate glade
#

ngl didnt know there was a mod out there for it

#

πŸ’€

#

im still trying to get this to work though im adjusting values for the hud

solar bramble
#

tbh tho its a lot easier if its just built into the models cause u have to manually toggle the camera until it fits ur model size

#

so imo still gamechanging stuff

delicate glade
#

OH OKAY i figured out the math

#

so the Y position is default set to -0.05f, the scale needs to lower that value the higher it is

#

so i need to do some funny math fuckery

#

basically we can do this by dividing 1 by the model scale BEFORE mutliplying the -0.05

#

to inverse the direction the scaling goes

#

the only problem using this method for anyone else curious is you need to know how large your model is proportionately to the player models height that i made up

#

fuck nvm thats not right LMAO

#

i somehow made the most accurate helmet vision mod ever

#

by accident

solar bramble
#

Help lmfao

#

someone would be into that i promise lol

delicate glade
#

oh 100%

#

oh ffs okay i think i got it

#

i forgot a negative sign again

solar bramble
#

wondering if adding blinking means I can't have mouth movement anymore tbh

delicate glade
#

you can have both

solar bramble
#

goddd why wont it worrrk then

#

maybe im forgetting a bracket

#

somewhere

#

or it could be the fact that i need to revise cause there are multiple models

#

tutorial didn't specify adding more than one lmfao

delicate glade
#

i couldnt get the harmony patch part to work for whatever reason so i just rewrote it like how i usually do patches

#

i think ive got it all in a good state now for the most part, the hud looks ever so sliiightly off when using a model at a very different height but thats not that big of a deal imo

#

and i can always fix it later if i figure it out

#

the magic of making functions like this is if i ever want to adjust something i only need to adjust it once in that little function, rather than in like 80 spots for each individual suit

solar bramble
#

cannot get these damn mouths to move

#

oh my fucking god my mic has been off this whole time

#

somehow its inverted toooo wadda hell im cryinhg

elder hill
#

I mean Please

delicate glade
#

uhhhhhhhhhhhhhhh

#

heres the stock image i stole off google

#

and heres the material settings i set to crop it because i couldnt be assed to edit the image in photoshop

#

scuffed position/rotation/scale to get it roughly aligned in an empty scene for player model testing

elder hill
#

Lol, thanks

delicate glade
#

and then another one i rotated a bit to see on another angle

#

np ig kyoukoxd

solar bramble
#

saving lives

#

i have to see about copying ur POV code and getting my signalis models to be biblically correct.

delicate glade
#
public class ModelReplacementManager : MonoBehaviour
{
    internal static void OverrideStart(Vector3 cameraLocalPosition, float modelHeight)
    {
        if (Plugin.cameraAdjustEnabled.Value) //only make camera adjustments if the player has the config enabled.
{
    CameraVisuals.DetectCamera(GameNetworkManager.Instance.localPlayerController, cameraLocalPosition, modelHeight);
}
    }
    internal static void OverrideOnDeath(Transform replacementBodyTransform, string headAnimatorPath, string tailAnimatorPath)
    {
        if (replacementBodyTransform.Find(headAnimatorPath).gameObject.TryGetComponent<Animator>(out Animator headAnimator2))
        {
            headAnimator2.SetTrigger("OnDeath");
        }
        else Plugin.Logger.LogError("Head animator not found! Please report this and provide the log, thank you! <3");
        if (replacementBodyTransform.Find(tailAnimatorPath).gameObject.TryGetComponent<Animator>(out Animator tailAnimator2))
        {
            tailAnimator2.SetTrigger("OnDeath");
        }
        else Plugin.Logger.LogError("Tail animator not found! Please report this and provide the log, thank you! <3");
    }
}```
#

i have this in my BodyReplacements.cs

#
using BepInEx;
using BepInEx.Logging;
using GameNetcodeStuff;
using HarmonyLib;
using ModelReplacement;
using UnityEngine;

namespace CamVisuals
{
    [BepInPlugin("MRCameraVisuals(name)", "(name)", "1.0.0")]
    public class CameraVisuals : BaseUnityPlugin
    {
        private readonly Harmony harmony = new Harmony("CameraVisuals(name)");

        private static GameObject gameObject;

        private static CameraVisuals Instance;

        private static float currCameraLocalScale;

        private static bool terminalDisable = false;

        private void Awake()
        {
            if (Instance == null)
            {
                Instance = this;
            }
            harmony.PatchAll(typeof(CameraVisuals));
        }

        public static void DetectCamera(PlayerControllerB player, Vector3 cameraLocalPosition, float modelHeight)
        {
            float modelScale = modelHeight / 173f; //basically we input the characters height, then divide it by the default LC height (173cm because i said so) to get the characters height relative to normal.

            gameObject = player.gameObject;
            Transform childTransform = gameObject.transform.Find("ScavengerModel/metarig/CameraContainer");
            if (childTransform != null)
            {
                Plugin.Logger.LogInfo(gameObject.transform.Find("ScavengerModel/metarig/CameraContainer/MainCamera/HUDHelmetPosition").localPosition);
                Vector3 newLocalPosition = new Vector3(0.01f, -0.05f * (1 / modelScale), -0.05f); //we grab the default local position and multiply it by our scale, moving it automatically based on how tall we can gather our model is.
                Vector3 newLocalScale = new Vector3(modelScale, modelScale, modelScale);
                currCameraLocalScale= modelScale;
                gameObject.transform.Find("ScavengerModel/metarig/CameraContainer/MainCamera/HUDHelmetPosition").localPosition = newLocalPosition;
                gameObject.transform.localScale = newLocalScale;
            }
            else
            {
                Plugin.Logger.LogInfo("Camera Container not found!");
            }
        }
        [HarmonyPatch(typeof(Terminal))]
        internal class DetectCameraTerminalPatch : MonoBehaviour
        {
            [HarmonyPatch(typeof (Terminal), nameof(Terminal.BeginUsingTerminal))]
            [HarmonyPostfix]
            public static void DetectCamera()
            {
                PlayerControllerB localPlayerController = GameNetworkManager.Instance.localPlayerController;
                if (!terminalDisable)
                {
                    ((Component)localPlayerController).gameObject.transform.Find("ScavengerModel/metarig/CameraContainer/MainCamera").localPosition = new Vector3(0f, (-3*currCameraLocalScale)+2.95f, -0.05f);
                    terminalDisable = true;
                }
            }

            [HarmonyPatch(typeof(Terminal), nameof(Terminal.QuitTerminal))]
            [HarmonyPostfix]
            public static void ResetCamera()
            {
                PlayerControllerB localPlayerController = GameNetworkManager.Instance.localPlayerController;
                if (terminalDisable)
                {
                    ((Component)localPlayerController).gameObject.transform.Find("ScavengerModel/metarig/CameraContainer/MainCamera").localPosition = new Vector3(0f, 0f, 0f);
                    terminalDisable = false;
                }
            }
        }
    }
}```
#

and this is the new script CameraVisuals

#
public class SILENCESUZUKA : BodyReplacementBase
{
    protected override GameObject LoadAssetsAndReturnModel()
    {
        string model_name = "SilenceSuzuka";
        return Assets.MainAssetBundle.LoadAsset<GameObject>(model_name);
    }
    protected override void Start()
    {
        base.Start();
        ModelReplacementManager.OverrideStart(new Vector3(0f, 0f, 0f), 160);
    }
    protected override void OnDeath()
    {
        base.OnDeath();
        ModelReplacementManager.OverrideOnDeath(base.replacementDeadBody.transform, "pfb_bdy1002_00/Position/Hip/UpBody_Ctrl/Waist/Spine/Chest/Neck/Head", "pfb_bdy1002_00/Position/Hip");
    }
}```
heres an example body replacement in BodyReplacements.cs
grim scarab
#

Did u actually get this working

grim scarab
delicate glade
#

the camera gets a little funky when entering the terminal (i havent perfected the formula yet), and when you swap to a suit that doesnt have this camera functionality it doesnt revert to normal

grim scarab
#

Hm

delicate glade
#

both these problems make sense i just havent found solutions for em yet

grim scarab
#

Have you tried just undoing the scale and position edits in the suit destroy func

delicate glade
#

i indeed havent that makes a lot of sense

#

i will try that

grim scarab
#

When I think abt it, it would probably be worth to store the values somewhere else and then call them as vars when u do the changes

#

To make the code more copyable

delicate glade
#

yeah

grim scarab
#

/easier to experiment

delicate glade
#

can store in plugin

#

actually

#

if its just restoring to default i dont need to

#

because default isnt gonna change

#

unless you mean having the default be a variable somewhere else and call that

#

which makes sense thats what im gonna do

grim scarab
#

No I mean

#

Just reverse the change u do on awake

delicate glade
#

that wont work if you go from one modded to suit then another then to a default suit

#

as itll just use the previous modded suit no?

grim scarab
#

Na

delicate glade
#

or do you mean very very beginning awake

grim scarab
#

The awake where it applies the height change

#

Take those values and do the negative kf them in destroy

#

Maybe prefix instead of postfix to make sure it works before doing the new suit

delicate glade
#

that wont work like i said though if you go from a custom height suit, to another custom height, to a non custom one tho

#

as itll restore back to the first custom suit

grim scarab
#

Hum

#

I wonder why

#

Ohhh wait

#

I do remember just making an actual reset

#

That was dependent on switching to suit id 0

#

Forces vanilla values

#

I guess you could force default in the destroy func and see how that goes

delicate glade
#

are we thinking of diff problems cuz im thinking when you swap to any suit that isnt one set up with my specific functionality

grim scarab
#

Yeah

#

I think i did per-suit reversing on my attempt and it wasn't working

#

So i made the orange suit reset to defaults

#

Maybe it would just be better to make each suit reset to default before putting the new one on

delicate glade
#

definitely

#

most players wouldnt know to swap to orange suit first, and some have it disabled entirely (like me)

#

somehow i broke the entire mod again and nothings working

#

hmmmmm

#

OH WAIT

#

IK WHATS GOING ON

#

the config i declared i didnt bind

#

completely forgot you have to do that

grim scarab
#

Btw if u get this working consistently do you think you'd upload it separately like a library so other mods can use it

delicate glade
#

im ngl i have no idea how to do that

#

ive never considered something like that

#

πŸ’€

#

generally im the one just yoinking other things

long briar
#

sounds like i have to learn stuff about shaders to clean my models again OriHeheCry

#

ive never used the toon shader to begin with

delicate glade
#

okay done this seems to work

#

now regardless of what suit is put on next, the camera position and model scale is reset to default (in the case it is a custom model that has those properties, they will be overriden right away)

solar bramble
long briar
#

i dont even like the shader tbh

#

but if it makes my models clean i guess ill look into it

#

idk how i look into it but ill figure

delicate glade
#

honestly for most of my models i like the default shaders as it makes them blend with the game better

long briar
#

exactly

#

i do like glossy looks

#

and the games i take models from also run a more realistic shader compared to other anime like games

delicate glade
grim scarab
#

this is better than what i managed lol

#

on mine there was always 1 frame of default heigh before switching to the new one

delicate glade
#

thats because of the delay that was set

#

so it was swapping to default then after a delay swapping to the new height

#

i removed the delay because the ondestroy is being called first anyways

grim scarab
#

ah

#

i think i set that because the heights were just stacking instead of setting correctly

#

doesnt matter if you just do set instead of additive

brisk wagon
long briar
#

well i generally dont know anything about shaders so that sounds like an adventure

solar bramble
#

having an issue with mouth movement on the model, for some reason it is crooked? fixing the initial and max opening does not seem to fix

#

its almost like i need to correct more than that. in blender though it works just fine as intended...

#

Girl looks like shes chewing gum T0T

solar bramble
# delicate glade

btw did you make this an actual add on, or should i just yoink what you posted above?

delicate glade
#

its just in my project, it isnt really finalized

#

i havent tested much and i know using the terminal is jank with tall models

#

iirc it also breaks the camera completely on any model that isnt mine havent fixed that yet

eager mural
#

as some shader features might be outright disabled for the game you trying to use it in

#

so then it requires using a different techinique or adding custom stuff to re-enable said feature but i dont think Lethal stripped out much

#

but ye make sure its a HDRP compatiable shader πŸ˜„

#

this is for lethal case atleast

solar bramble
#

anyone know how to get toon shading so clean in lethal?

obtuse nebula
#

@eager mural I decided to give it another shot, gave up and was like.. frick this and deleted the whole visual studio side of my project, before building the project again, made sure every thing that had my model name, was the same, even capitalizations lmao -- I built it, re-referenced the bepin and unity crap, built it... and it loaded in LC with no problems πŸ˜„ πŸ˜„ πŸ˜„

obtuse nebula
#

Run into a new issue, when updating another one of my mods, I get this when having both mods

[Error  :meow.ModelReplacementAPI] Cannot register body replacement type ModelReplacement.MRMAYU, suit name to replace default is already registered.
[Error  :meow.ModelReplacementAPI] Cannot register body replacement type ModelReplacement.MRMAYU, suit name to replace orangesuit is already registered.
[Info   : mayumodel] Plugin com.wolfgang.mayumodel is loaded!```
#

Switching to Mayu just makes my playermodel default but with the mayu suit texture, same as my new one, but with their suit texture ConfusedDog

obtuse nebula
#

Okay, I figured it out. For some ungodly reason, all new suits you make with the latest thing that generates these configs, tries to patch Default,Orange Suit. If you have more than 1 of these mods, they conflict and break. So you need to make it point to itself.. why it doesn't do that by default is beyond me lol

eager mural
#

but i think the reason is because you can have multiple suits in one mod

#

but ye i didnt really look at what it generates nor how

#

but i did patch mrapi for one of my mods but ye

obtuse nebula
#

Until I learn how, I just ship my suits with a notice in the readme to change the config to what it should be ;3;

long briar
#

i managed to poke bunya yesterday and hes atleast aware now that mrapi needs a small update

#

but also he sounded very busy and not very available

#

replying to me alone took him like 3 days AnimatedPlink

eager mural
#

and it will just use that instead of generating one

obtuse nebula
#

Anyone know what could be causing this? It's been plaguing me with the last 2 models i've tried building. I tried deleting the Library folder and let unity re-import it, which fixed the first model doing this annoying error, but that didn't work with this one.

eager mural
obtuse nebula
#

Can you show me an example?

eager mural
#

this stuff

obtuse nebula
#

Oh! I'll have a look when I'm on my computer

eager mural
#

I recommend adding AssetBundle Browser to your Unity if you dont have it makes a bit more user friendly imo

#

it gives you this panel which you can just right click delete the unwanted ones while the default thing in Unity is.. clear all refs manually to the bundle and hit Remove Unused Names..

obtuse nebula
#

lmao if I click build on the Asset Bundle Browser with the director set to where I want my asset to be built, it works just fine. Using the SDK build button doesn't work xD

obtuse nebula
#

So, in the Asset Browser, I had to rename it there, and build for it to build lmao -- then I rename it to the proper name before turning it into a DLL

tidal dew
#

Did anyone figure out what causes the belt bags to bug with this mod?

#

This is like the error it spams when I'm holding the belt bag but I've no idea what it means

#

The bug seemingly happens when you pick something up with an "open" belt bag. It causes the bag to break and you can no longer open it

tidal dew
#

My friend said it's the new utility slot that bugs the bag. If it's in one of your normal 4 slots it works fine

tidal dew
#

Nvm some goat made a hotfix ❀️ #thunderstore-releases message

obtuse nebula
#

How do people include 2 different model replacements in 1 mod? I wanna setup a cat and bunny version of basically the same model but as 2 seperate suit choices

grim scarab
#

it should be a drop down in the bottom right

obtuse nebula
grim scarab
#

ye

obtuse nebula
#

You mean like, have both the models in the same scene?

grim scarab
#

no

#

theres a drop down called assetbundle

#

put both of your models on one bundle

obtuse nebula
#

This look right?

#

Alright, so I built it. Have 2 seperate suits on the rack with the respective names. But they both just turn me into the bunny model

#

Sniffing in the built assetbundle, it has both prefabs in it with all of the assets

upper dagger
#

You can choose not to use Config

#

If you don't use other functions, you can do it like this:

#

@obtuse nebula

obtuse nebula
#

Sorry, just woke up about an hour ago and had to do some stuffs

obtuse nebula
obtuse nebula
#

I have a super smart coder friend who was able to fix all that up!

obtuse nebula
#

Why can I not get emission to work on the HDRP/Lit material? It's showing on the material, not on the model
So, the emissions don't appear in-editor but they appear in-game. however, they don't actually glow in the darkness

obtuse nebula
eager mural
# obtuse nebula

if you have UnityExplorer installed you can mess with the material at runtime like turning up its Intensity to see if that helps

#

as i suspect maybe your Emission Intensity is too low

#

try values between like 50-500 for it lmao

obtuse nebula
obtuse nebula
obtuse nebula
#

I'll give it a shot

hallow cloak
#

set the nits to like 10 and then test

obtuse nebula
#

So, I mimicked your settings, still nothing 😒

obtuse nebula
eager mural
obtuse nebula
eager mural
#

well its a camera that renders its view onto a texture

#

it just has some camera setting disabled that stops the emission glow from rendering

#

probs for performance reasons maybe

#

or a oversight

#

some mods add combatiablity to mirror mods by tweaking its camera settings to enable the stuff they need πŸ˜„

#

but that is via code

hallow cloak
#

That mirror is a nightmare and has a stupidly long range with no framerate cap that renders even when youre not on the ship

obtuse nebula
#

When's someone going to fork that mod and unfrick it

hallow cloak
obtuse nebula
#

Yoooo ModelReplacement got an update!

tidal dew
tidal dew
oblique sapphire
#

It won't let me compile, do you know what the problem might be?

upper dagger
#

I created a template.

obtuse nebula
#

Something else is stopping you from building the DLL.

eager mural
oblique sapphire
#

thank you

oblique sapphire
eager mural
#

aka no permission in that folder to do stuff

#

and should have asked in #dev-general would have gotten an answer faster

delicate glade
#

for anyone else with model replacement mods that exceed the moresuits limit, do you just add some info on your mod page that suggests to increase the limit? or have you found a way to make your mod increase the limit automatically?

grim scarab
#

the only other mod i can think of that has that many model replacements is the star rail mod lol

#

i think they just tell u to increase the max suits idk

#

you could include a moresuits config with a higher max suits but thats a bad idea

livid tide
#

There's a mod that adds pages that I find works well though haven't been on in a bit

#

Because otherwise moresuits just crams them all on there until they overflow the rack and start floating

delicate glade
#

when it overflows the 100 the rest are ignored, but you can adjust the cap in moresuits config

livid tide
#

Ah, admittedly haven't reached that point in the number of suits myself lmao

delicate glade
#

yeah i didnt even know there was a cap myself until i hit it

#

it looks really funny all together in the editor

#

😭

hallow cloak
solar bramble
#

Lord

eager mural
solar bramble
#

throwing this here but i was making a suit for higgs from DS2 and wondered if anyone else wanted chars from the game included

solar bramble
#

Also for some reason in lethal the hair mesh is stretched but in unity and blender he is normal when I pose/move the mesh

solar bramble
#

found out the parenting was wild on the armature

fast zodiac
#

hello! i've been told to ask here, i don't know if someone has already talked about this before because i couldn't find anything but is there a way for the model on the right to look like the one on the left?
these are screenshots from february vs today, and the shadows affect the models too much to my liking but removing/keeping post processing does not change anything

delicate glade
#

whenever a player changes suits it adjusts the height for everyone in the lobby

#

even though i already check to make sure that player is local, and even tried adding a check in the override itself where when the suit is equipped the code ONLY runs if the one who called it is the same player as the one having their height adjusted

#

somehow it feels like when someone interacts with a suit, every player in the lobby is running that code themself

#

honestly at this point i have no idea what to do

#

oh i see the genshin model mod code checks with GetComponent<modelreplacementname>

#

well shit

delicate glade
#

I just need to somehow get the player that equipped the suit but as far as I'm testing that's impossible for some bizarre reason

delicate glade
#

wait really??

eager mural
# delicate glade wait really??

yes i written a full API to modify stuff based on suits with support for MRAPI 2 years ago which i never published πŸ˜„

#

so i know its possible

delicate glade
eager mural
#

okay so what you gotta do is Check the player current suit ye

#

then in MRAPI there is a Dictionary that holds all Suits that has a registered model

#

if you got a match for the x suit you know they wearing a model suit

#

and if you want to be more specific you can check the name of the model suit

delicate glade
eager mural
delicate glade
#

this..?

eager mural
#

yes

#

and what each ID means is stored inside of StartOfRound

delicate glade
eager mural
#

yep

delicate glade
#

hmm ill try it but i think itll be the same result

#

cuz i think if im understanding right it just passes through whatever is local from everyone when a suit is equipped

eager mural
#

MRAPI dont do any networking to sync it btw

#

it just uses the stuff base game uses