# Boe6's vehicles: Interaction collider .phys files

Add the `.phys` file to your project, rename, and move the file as appropriate. It is linked through the `.ent` file.\
Path:

* `.ent file > RDTDataViewModel > components > chassis > collisionResource`

Convert the `.phys` to a `JSON` file:

<figure><img src="https://1427525421-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F4gzcGtLrr90pVjAWVdTc%2Fuploads%2Fgit-blob-e56b262c51a2f87f50ae207ffdc87ee9a884e45f%2Fimage142.png?alt=media" alt=""><figcaption></figcaption></figure>

Now you’ll need 2 python scripts created by “*The Magnificent Doctor Presto!*”. They can be downloaded on github here:

<https://github.com/DoctorPresto/Cyberpunk-Helper-Scripts>

Download both **export\_phys.py** and **import\_.phys.py**

In **Blender**, open the “**Scripting**” workspace:\\

<figure><img src="https://1427525421-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F4gzcGtLrr90pVjAWVdTc%2Fuploads%2Fgit-blob-c2315f17d69256bc0aebb8aca92aca4df9d202e8%2Fimage143.png?alt=media" alt=""><figcaption></figcaption></figure>

At the top of the text editor that just openned, use the folder icon to find the importing `.py` file we just downloaded.

<figure><img src="https://1427525421-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F4gzcGtLrr90pVjAWVdTc%2Fuploads%2Fgit-blob-68ee11cf1ffdfb7ad9f862f4249442406b20eda5%2Fimage8.png?alt=media" alt=""><figcaption></figcaption></figure>

This should open the `.py` file into the text editor. It should look like this:

<figure><img src="https://1427525421-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F4gzcGtLrr90pVjAWVdTc%2Fuploads%2Fgit-blob-42c67965cdd7618e9aa9bb15abb423b164a4422c%2Fimage203.png?alt=media" alt=""><figcaption></figcaption></figure>

Edit the “`physJsonPath`” value to the converted `phys.json` file.\
Example:

<figure><img src="https://1427525421-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F4gzcGtLrr90pVjAWVdTc%2Fuploads%2Fgit-blob-960dccaeae1b50dcd7b9c87822365a5dcf94edc5%2Fimage206.png?alt=media" alt=""><figcaption></figcaption></figure>

Once you’ve run the script, you should have vertices that look close to the outline of the original car model. Notice the outline similar to the porsche:

<figure><img src="https://1427525421-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F4gzcGtLrr90pVjAWVdTc%2Fuploads%2Fgit-blob-44f66307e61fd300839f34e2de9eec2df5066a46%2Fimage192.png?alt=media" alt=""><figcaption><p>(left is the front of the car, right is the back with spoiler fin)</p></figcaption></figure>

`.phys` files don’t like complex meshes, so they use only vertices without faces or edges. Each “submesh” is a small object shape, with no [concave angles](https://www.google.com/search?q=concave+angle+in+polygon\&tbm=isch\&sclient=img). Each submesh is then joined to create the overall collision mesh.

Switch back to the Layout workspace.

The easiest way to edit these in blender is to enable your vehicle’s body mesh, is to switch to Wireframe shading, by holding Z, and moving your mouse to “Wireframe”.\
Example:

<figure><img src="https://1427525421-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F4gzcGtLrr90pVjAWVdTc%2Fuploads%2Fgit-blob-5ae5536c34ee0d8f603318f2d6250fddcf38b40f%2Fimage109.png?alt=media" alt=""><figcaption></figcaption></figure>

This will allow you to see your body mesh, but also see vertices behind and around it.\
Example:\\

<figure><img src="https://1427525421-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F4gzcGtLrr90pVjAWVdTc%2Fuploads%2Fgit-blob-6a7a06b28258a0a2bdbbf6c96001f9b113b052e2%2Fimage66.png?alt=media" alt=""><figcaption></figcaption></figure>

Once done editing, select all the vertices objects and run the **export\_phys.py**, similar to the import script.

The `.phys` file should now be finished. Import from `json`, update path references, and test in-game. Make sure to update the `physJsonPath` again, as this is the path it will save the new `.json` to.

<figure><img src="https://1427525421-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F4gzcGtLrr90pVjAWVdTc%2Fuploads%2Fgit-blob-11c6d28a32a087860bb72d892184945b33cf9e3d%2Fimage155.png?alt=media" alt=""><figcaption></figcaption></figure>

<figure><img src="https://1427525421-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F4gzcGtLrr90pVjAWVdTc%2Fuploads%2Fgit-blob-765d7b2ee90fe234841d635b0ead81b2f9cd19f6%2Fimage91.png?alt=media" alt=""><figcaption></figcaption></figure>

Once the script has been run, you should have a new file with the “`new_`” prefix added in the same folder as the `phys.json`.\
Example:

<figure><img src="https://1427525421-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F4gzcGtLrr90pVjAWVdTc%2Fuploads%2Fgit-blob-a4750758b81efa5b38288debbdbdb34c9940a106%2Fimage111.png?alt=media" alt=""><figcaption></figcaption></figure>

This file can now be converted back from json and used in game.\
Example:

<figure><img src="https://1427525421-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F4gzcGtLrr90pVjAWVdTc%2Fuploads%2Fgit-blob-89553724859685324eb0150df1ba16ad96cc589b%2Fimage177.png?alt=media" alt=""><figcaption></figcaption></figure>
