Skip to content

Simplify asset management#1487

Merged
iamteapot422 merged 55 commits intoRE-SS3D:developfrom
rohitkulkarni97:Issues/Simplify-the-asset-management-workflow-#1259
Feb 24, 2026
Merged

Simplify asset management#1487
iamteapot422 merged 55 commits intoRE-SS3D:developfrom
rohitkulkarni97:Issues/Simplify-the-asset-management-workflow-#1259

Conversation

@rohitkulkarni97
Copy link
Contributor

Summary

Simplifies asset management and makes it robust by using GUIDs instead of names for referencing. Step 1 to introduce the Addressables system.

PR checklist

  • The game builds properly without errors.
  • No unrelated changes are present.
  • No "trash" files are committed.
  • Relevant code is documented.
  • Update the related GitBook document, or create a new one if needed.

Pictures/Videos

Testing

Networking checklist

  • Works from host in host mode.
  • Works from server in server mode.
  • Works on server in client mode.
  • Works and is syncronized across different clients.
  • Is persistent.

Changes

  1. DatabaseAsset is removed instead, const strings are used in different asset database scripts, which now contain the GUID of the prefab instead of the name.
  2. WorldObjectAssetReference is now named as ObjectAssetReference, because it serves more than the one purpose it was designed for.
  3. RoleData and RoleLoadout use ObjectAssetReference instead of direct prefabs.
  4. ObjectAssetReference now stores the GUID of the preab and the GUID of the database instead of their names.
  5. GenericObjectSo uses ObjectAssetReference instead of prefabs directly.
  6. Scripts using a list of audio clips to play via the audio subsystem use ObjectAssetReference instead, as the audio subsystem loads the clip from Assets.Get() anyway.

Related issues/PRs

Closes #1259
Simplify the asset management workflow

…eters in asset creation methods, and removing DatabaseAsset.cs usage.
….Get method instead of DatabaseAsset's Prefab property, Create, Get<T>() & CreateAs<T>(...) functions, and different implicit operators.
…Creator and DatabaseScriptWriter for consistency in asset management workflow.
…, and Item to use Assets.Get method for improved consistency and clarity
…to use Assets.Get method for improved consistency
…and other places to streamline asset retrieval
…tepCraftable, and Item to simplify usage of Assets.Get method
…nce to streamline addressable asset handling and improve code clarity
…nstructionHologramManager to utilize WorldObjectAssetReference for improved asset retrieval
…bjectsSO prefabs to enhance asset management
…eferences throughout the codebase for consistency
…AssetReference, and implement IEqualityComparer for improved comparison
…lementation and simplifying equality and hash code methods
…eters in asset creation methods, and removing DatabaseAsset.cs usage.
….Get method instead of DatabaseAsset's Prefab property, Create, Get<T>() & CreateAs<T>(...) functions, and different implicit operators.
…Creator and DatabaseScriptWriter for consistency in asset management workflow.
…, and Item to use Assets.Get method for improved consistency and clarity
…to use Assets.Get method for improved consistency
…and other places to streamline asset retrieval
Copy link
Contributor

@iamteapot422 iamteapot422 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Multiple errors in editor

Image


string key = $"{WorldObjectAssetPath}{worldObjectAssetReference.Id}.asset";
string key = $"{ObjectAssetReference.ObjectAssetPath}{gameObject.name}.asset";
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"Cannot resolve symbol 'ObjectAssetPath'"

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't have that error at my end, maybe it might be due to the missing ; (again I'm extremely sorry, I'm stupid)

@iamteapot422
Copy link
Contributor

Why was ObjectAssetReference.Create() removed?

@rohitkulkarni97
Copy link
Contributor Author

Multiple errors in editor

Image

I'm sorry, my bad 🙏

@rohitkulkarni97
Copy link
Contributor Author

Why was ObjectAssetReference.Create() removed?

It was moved to ObjectAssetReference.Editor file as it is only valid in the editor. The Editor functions of the ObjectAssetReference class were moved from ObjectAssetReference.cs to ObjectAssetReference.Editor.cs.
image

iamteapot422

This comment was marked as resolved.

Copy link
Contributor

@iamteapot422 iamteapot422 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Error on building the project

Image

Everything else (haven't checked networking yet) seems fine

@rohitkulkarni97
Copy link
Contributor Author

Error on building the project

Image Everything else (haven't checked networking yet) seems fine

Fixed

@rohitkulkarni97
Copy link
Contributor Author

rohitkulkarni97 commented Feb 23, 2026

Still getting errors

Editor:

Image Game: Image

Doesn't seem to happen at my end. Also, the scripts don't seem familiar to me. I haven't made changes to these files.

@iamteapot422
Copy link
Contributor

Still getting errors
Editor:
Image
Game:
Image

Doesn't seem to happen at my end. Also, the scripts don't seem familiar to me. I haven't made changes to these files.

Yeah, ten seconds after posting the review i have discarded the seemingly inoccuous changes and it worked

Copy link
Contributor

@iamteapot422 iamteapot422 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good work

@iamteapot422 iamteapot422 merged commit 3f7cf28 into RE-SS3D:develop Feb 24, 2026
2 checks passed
@iamteapot422 iamteapot422 changed the title Simplify the asset management workflow #1259 Simplify the asset management Feb 24, 2026
@iamteapot422 iamteapot422 changed the title Simplify the asset management Simplify asset management Feb 24, 2026
@rohitkulkarni97 rohitkulkarni97 deleted the Issues/Simplify-the-asset-management-workflow-#1259 branch February 24, 2026 21:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Simplify asset management

2 participants