derail-valley-modding / skin-manager Goto Github PK
View Code? Open in Web Editor NEWA Derail Valley mod that allows rolling stocks skins to be changed.
Home Page: https://www.nexusmods.com/derailvalley/mods/34
License: MIT License
A Derail Valley mod that allows rolling stocks skins to be changed.
Home Page: https://www.nexusmods.com/derailvalley/mods/34
License: MIT License
I'm working on a mod that adds lights to the locomotives, and I'm working to add a reversing light to the steam loco as part of this. I'd like the reversing light to inherit the skin from the locomotive (the model is literally copied from the SH282, so it's perfect for this), but I've discovered that the name
field is not set on the skin textures.
This is where the texture is created afaik:
https://github.com/SvetlozarValchev/dv-skin-manager-mod/blob/master/SkinManagerMod/Main.cs#L324
I think it would be sufficient to add texture.name = diffuse.name;
there (etc for the other texture types)
There may be more related info here: https://discordapp.com/channels/332511223536943105/560262776673796157/756439002336329779
Not sure how feasible this is, but when doing rapid-fire skin editing (i'm incompetent at blender etc, so i edit textures in gimp and then reload to see if it looks okay) it can get tedious to do the whole "ctrl-f10 -> reload all textures -> wait -> reapply skin with radio" shtick.
it'd be neat if there was a comms radio mode (maybe enabled in settings or something?) that when used on a car, reloads the texture for the currently applied skin and then re-applies it.
The Install Unzipped
button clears the selected folder before installing the skins, but does not check if the selected folder is reasonable, if the files to be deleted are reasonable, or warn the user that files will be deleted, and no guidance/documentation is provided as to what folder should be selected.
Fortunately I only wiped my UMM Mods
folder so no data was lost, but another user may not be so lucky.
ensure unix compatibility for packager zips
For example, same skin for both S282 and tender try to package in same folder with zip archive
https://github.com/derail-valley-modding/skin-manager/blob/2ca7a1b3ce149b27137886525a7dea94215af132/SkinManagerMod/TextureLoader.cs#L65C96-L65C96
SkinManagerMod is still expecting a "Skins" directory, but now we're using lowercase.
This mod doesn't seem to reskin any hidden axles and wheels. Normally this isn't an issue, but the Rearranged S282 mod creates hidden axles that should still be reskinned.
For example, if you're using a 2-8-2 wheel arrangement on the S282, the fifth drive wheels are hidden and won't be reskinned. If you then reskin the locomotive, then switch to a 2-10-2 wheel arrangement, the fifth drive wheels might show up with the previous skin.
Naturally, this bug occurs with the leading and trailing axles too.
I could fix this in Rearranged S282 with some kind of harmony patch, but it seems easiest if it's patched in Skin Manager.
It seems like all that needs to change is this line:
foreach (var renderer in objectRoot.GetComponentsInChildren<MeshRenderer>())
into this:
foreach (var renderer in objectRoot.GetComponentsInChildren<MeshRenderer>(true))
This bug happens because Component.GetComponentsInChildren()
does not search inactive GameObjects unless you set the includeInactive
parameter to true
.
Would this be a reasonable change?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.