• Hi Guest!

    We are extremely excited to announce the release of our first Beta for VaM2, the next generation of Virt-A-Mate which is currently in development.
    To participate in the Beta, a subscription to the Entertainer or Creator Tier is required. Once subscribed, download instructions can be found here.

    Click here for information and guides regarding the VaM2 beta. Join our Discord server for more announcements and community discussion about VaM2.

Question How to know VAM custom classes properties and methods for scripting?

Datel

Member
Joined
Jul 23, 2024
Messages
39
Reactions
35
Does VAM has wiki or documentation with custom classes, methods and properties?

For example, I dont know about Supercontroller and it's properties and methods to use it.
I would like to fix mouse selection of controllers, but i dont know hover controller property, how select controllers, how it works and where is mouse events processing.

Tried to get type info, but "Exception: System.Security.SecurityException: Security Check Failed (NamespaceRestriction)". I dont really know how to work with class without it's method names
 
Solution
The only thing I know of is the template under VaM's "Custom/Scripts/MeshedVR" folder. You can open the PluginBuilder cs project in Visual Studio and for things like the SuperController it will show you all the properties/methods via auto-completion or "go to definition". Other than that I've had to look at other people's plugins for reference.
The only thing I know of is the template under VaM's "Custom/Scripts/MeshedVR" folder. You can open the PluginBuilder cs project in Visual Studio and for things like the SuperController it will show you all the properties/methods via auto-completion or "go to definition". Other than that I've had to look at other people's plugins for reference.
 
Upvote 0
Solution
The only thing I know of is the template under VaM's "Custom/Scripts/MeshedVR" folder. You can open the PluginBuilder cs project in Visual Studio and for things like the SuperController it will show you all the properties/methods via auto-completion or "go to definition". Other than that I've had to look at other people's plugins for reference.
Did not know about that, thanks. I'll try to check, maybe i could find enough to make things what i want :unsure:
 
Upvote 0
The only thing I know of is the template under VaM's "Custom/Scripts/MeshedVR" folder. You can open the PluginBuilder cs project in Visual Studio and for things like the SuperController it will show you all the properties/methods via auto-completion or "go to definition". Other than that I've had to look at other people's plugins for reference.
Thank you again, i got more what i wanted, will look deeper.
Also, this one guide for VisualStudioCode is helpful too https://hub.virtamate.com/resources/how-to-setup-visual-studio-code-without-visual-studio.48263/
 
Upvote 0
Its probably best to start by looking at plugins from others. Start with something simple and work your way up.

There is no VaM documentation, but you can use ILSpy to look at VaM_Data\Managed\Assembly-CSharp.dll. It allows you to look at VaM's codebase. Technically its decompiling the DLL, hence code comments are lost and local variable names are replaced with generic ones. Benefit of access to the code like this is that code doesn't lie ;)

Also of course Unity, the engine used by VaM, is documented and there are lots of tutorials for it. However, note that VaM 1.xx is using a fairly old Unity version: 2018.1.9
 
Upvote 0
I would like to fix mouse selection of controllers, but i dont know hover controller property, how select controllers, how it works and where is mouse events processing.
For that specifically a look at my PowerHandles plugin (part of Essentials) may or may not help.
 
Upvote 0
For that specifically a look at my PowerHandles plugin (part of Essentials) may or may not help.
Thank you. I am using PowerHandles, it is very useful. Also I found that Supercontroller and Handlers have many private properties and methods, so seems it is impossible to replace one function or rewrite small part of code.
For example list of highlighted controllers is private and no methods to set it. Also methods for choosing controller by mouse doint many strange raycast things in private methods and I cannot turn it off to replace with my implementation 😢
 
Upvote 0
Back
Top Bottom