Skip to main content

Mod Toolkit Overview

Build this project in a few clicks#

  1. Click BuildTools -> BuildAllBundles in the toolbar of Unity.
  2. When the mod has been built it can be found in the ModProj project location at ModProj/Assets/Mods
  3. Copy the mod files(mod files are located ) to the corresponding path:
    • To run on Windows(or click BuildTools -> InstallModOnWindows): C:\Users[username]\AppData\LocalLow\CyDream\BattleTalent\Mods
    • To run on Quest(or click BuildTools -> InstallModOnAndroid): /sdcard/Android/data/com.CyDream.BattleTalent/files/Mods/
  4. Done!

Open the sample scene#

Once you opened the toolkit with Unity and SampleScene(Assets/Scenes/SampleScene), you will see something like this:

image-20220713105752324

Project Folder Structure#

Let me explain the folder stucture:

IndexExplanation
1-AddressableAssetsDataThis is generated by unity, just leave them alone
2-BuildIt's the object you want to be associate with addressable path, so that you can load them via script or built-in system. such as weapon(prefab), effect, flyobject, audio, icon, config...etc. You should place them in the coorsponding predefined folder, so that we'll handle the addressable path for you automatically. We'll explain addressable path later.
3-ResourcesWe place the resources don't need addressable path here. such as fbx, texture, shader. Because they will be loaded within the prefab, so we don't need to define a addressable path for them. Unity's addressable system will handle this for us.
4-ToolkitIt's the toolbox provided by developer, we'll dive in this place later.
5-Inner folder of a mod source filesAs you can see, we place the object under the coorsponding predefined folder. So that they will be associate with the coorsponding addressable path. Then the script or built-in system can load them correctly.

Mod Importer#

Mod importer can load and save the mod files you placed in the PCVR mod folder(Tools/OpenPCModFolder). It lets you to visit the inside resources of a mod even you don't have the source file. It's a good way to learn how to mod.

To use this tool, is to run the SampleScene. Then you'll see the mods list from PCVR mod folder.

image-20220713200308459

PS: currently, Mod Importer can not save the mesh(fbx) from mod, because we can't not access the mesh from memory. If anyone knows how to make a mesh readable from addressable at runtime, please let me know.

PC VR Simulator Shortcut#

ShortcutFunction at Body ModeFunction at Hand Mode
WASDwalkwalk
Shiftrunhand rotation
Altswitch to Hand Modeswitch to Body Mode
Tabswitch between your hand
Mouse Movementbody rotationhand movement
Ctrlhand movement on Z axis
ShortcutFunction
F12open or close MainMenu
F11open or close CheatMenu
F10reload mods(not working for now)
F9remove mods(not working for now)
F8jump to test scene
F4hide mouse
PageDownselect next target
Ukill target
Ystun target
PadNumtarget attacks
Homeenable target's AI
Enddisable target's AI
Kkill all
Spacejump
Gjump(no cooldown)
Vdash(no cooldown)

Log Path#

LogLog Path
Windowshttps://docs.unity3d.com/Manual/LogFiles.html
Questadb command: .\adb.exe logcat -s Unity -d > .\quest_log.txt

you can also read it on in-game console or using adb log command or using sidequest's adb window