Skip to content

Commit

Permalink
don't serialize id of audio resource if no audio defined in Component
Browse files Browse the repository at this point in the history
  • Loading branch information
JirkaDellOro committed Apr 22, 2024
1 parent b9ab6db commit 66b55b4
Show file tree
Hide file tree
Showing 2 changed files with 45 additions and 45 deletions.
88 changes: 44 additions & 44 deletions Core/Build/FudgeCore.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion Core/Source/Component/ComponentAudio.ts
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@ namespace FudgeCore {
//#region Transfer
public serialize(): Serialization {
let serialization: Serialization = super.serialize();
serialization.idResource = this.audio.idResource;
serialization.idResource = this.audio?.idResource;
serialization.playing = this.playing;
serialization.loop = this.loop;
serialization.volume = this.volume;
Expand Down

0 comments on commit 66b55b4

Please sign in to comment.