Giter Site home page Giter Site logo

Comments (15)

HolographicWings avatar HolographicWings commented on August 17, 2024

It seems that regular scripts aren't allowed to be included in the AssetBundle. I thought having the scripts in a dll would resolve it but while loading in the game tells me: Warning: Unity Log] The referenced script (mydllfile.myscript) on this Behaviour is missing! Even though the gameobjects definitely has the correct script attached. Not sure if this is my fault but I'm a bit confused now.

this is not allowed, a bundle can't be scanned with any antivirus so it's easy to put malwares in them
theres a whitelist of allowed components

from lethalsdk-unity-project.

Wesley-wasnietavailabledusdanmaarzo avatar Wesley-wasnietavailabledusdanmaarzo commented on August 17, 2024

That makes sense.
So I'm guessing there is no way to have custom stuff happen like.. a box trigger enabling some particles or having a sound play every so many seconds for instance.

from lethalsdk-unity-project.

HolographicWings avatar HolographicWings commented on August 17, 2024

That makes sense. So I'm guessing there is no way to have custom stuff happen like.. a box trigger enabling some particles or having a sound play every so many seconds for instance.

i planned to add some scripts to do that, but i never did it, and the mod is in end of support so.. :/

from lethalsdk-unity-project.

ThisMight avatar ThisMight commented on August 17, 2024

Wouldn't it be possible to include these scripts in a separate DLL and run them from there?

from lethalsdk-unity-project.

HolographicWings avatar HolographicWings commented on August 17, 2024

Wouldn't it be possible to include these scripts in a separate DLL and run them from there?

Yes, you need to make a DLL, bundles can't store scripts
Load this DLL in unity by placing it in a plugins folder

from lethalsdk-unity-project.

Wesley-wasnietavailabledusdanmaarzo avatar Wesley-wasnietavailabledusdanmaarzo commented on August 17, 2024

I did try this but whenever I referenced a script from my dll on objects in the prefab, when loaded, the game couldn't find them.

from lethalsdk-unity-project.

ThisMight avatar ThisMight commented on August 17, 2024

I did try this but whenever I referenced a script from my dll on objects in the prefab, when loaded, the game couldn't find them.

Same on that, Little success. I have tried using a bepinex plugin to add the dll via bepinex, but it still couldn't find the reference. won't stop me from trying to figure it out lol.

My theory would be having it added as a component using an auxilary help plugin is one of the ways to do it, but depending on what you're trying to acomplish, this method might either be unmanagable or just unperformant.

from lethalsdk-unity-project.

HolographicWings avatar HolographicWings commented on August 17, 2024

Does your bepinex plugins was loading before lethal Expansion?

from lethalsdk-unity-project.

ThisMight avatar ThisMight commented on August 17, 2024

Does your bepinex plugins was loading before lethal Expansion?

Nope, it seems lethalSDK has priority over the plugin, and I lack the knowledge on how to increase priority.

from lethalsdk-unity-project.

HolographicWings avatar HolographicWings commented on August 17, 2024

Does your bepinex plugins was loading before lethal Expansion?

Nope, it seems lethalSDK has priority over the plugin, and I lack the knowledge on how to increase priority.

Add a dependency for Lethal Expansion in your plugin
Look for Bepinex dependency flag

from lethalsdk-unity-project.

ThisMight avatar ThisMight commented on August 17, 2024

Does your bepinex plugins was loading before lethal Expansion?

Nope, it seems lethalSDK has priority over the plugin, and I lack the knowledge on how to increase priority.

Add a dependency for Lethal Expansion in your plugin Look for Bepinex dependency flag

What I'm guessing is doing something along the lines of

 [BepInPlugin(GUID, Name, Version)]
 [BepInDependency("HolographicWings-LethalExpansion-1.3.30", BepInDependency.DependencyFlags.HardDependency)]

On top of the class inheriting BaseUnityPlugin?

from lethalsdk-unity-project.

HolographicWings avatar HolographicWings commented on August 17, 2024

Yes but the id of the mod is just LethalExpansion
A tip is to check the name of the config file

from lethalsdk-unity-project.

ThisMight avatar ThisMight commented on August 17, 2024

I've tested that, yet still comes out as not being found on the object inside the map,

Using a simple class "ExistanceNotifier"

public class ExistanceNotifier : MonoBehaviour
    {

        [SerializeField] private string message;

        public void Awake()
        {
            Debug.Log(message);
        }
    }

Using the reference

[BepInPlugin(GUID, Name, Version)]
[BepInDependency("LethalExpansion", BepInDependency.DependencyFlags.HardDependency)]

Inside the editor of the moon itself, simple awake checker
image

Yet, in the command line, twice:
Once, before the game has started and everything is being initialized
image
And once the moon has loaded.
image

So, I'm not sure exactly what the root cause of the missing dependencies could be at this point.

from lethalsdk-unity-project.

HolographicWings avatar HolographicWings commented on August 17, 2024

I tried on my side too
LethalExpansion need your DLL as dependance, so it will need every DLL of every peoples who make custom script as dependance
I will look for an alternative, like Lua scripting

from lethalsdk-unity-project.

HolographicWings avatar HolographicWings commented on August 17, 2024

Lua is not made for Unity, it works but i will have to write every unity function which will take me months..

from lethalsdk-unity-project.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.