Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/cicd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ on:

jobs:
build-game:
runs-on: ubuntu-latest
runs-on: ubuntu-22.04
steps:
- name: checkout
uses: actions/checkout@v4
Expand Down Expand Up @@ -115,7 +115,7 @@ jobs:

test-linux-build:
needs: build-game
runs-on: ubuntu-latest
runs-on: ubuntu-22.04
if: ${{ !startsWith(github.ref, 'refs/tags/') }}
steps:
- name: Download Linux artifact
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/discord.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on:

jobs:
notify-reviewers:
runs-on: ubuntu-latest
runs-on: ubuntu-22.04
steps:
- name: Send Discord notification
env:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pr_comment_artifact.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ on:
jobs:
comment-on-pr:
if: github.event.workflow_run.conclusion == 'success'
runs-on: ubuntu-latest
runs-on: ubuntu-22.04
steps:

- name: Get Artifact URL & PR Info
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ on:

jobs:
pre-commit:
runs-on: ubuntu-latest
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v3
Expand All @@ -19,7 +19,7 @@ jobs:

# This could be a pre-commit hook but it's quite expensive, so we only run it on CI
godot-validator:
runs-on: ubuntu-latest
runs-on: ubuntu-22.04
steps:
- name: checkout
uses: actions/checkout@v4
Expand All @@ -34,7 +34,7 @@ jobs:

tests:
# The type of runner that the job will run on
runs-on: ubuntu-latest
runs-on: ubuntu-22.04

# Steps represent a sequence of tasks that will be executed as part of the job
steps:
Expand Down
19 changes: 19 additions & 0 deletions src/addons/fmod/FmodManager.gd
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
@tool
extends Node

var performance_display: PerformancesDisplay

func _ready():
process_mode = PROCESS_MODE_ALWAYS
performance_display = PerformancesDisplay.new()
add_child(performance_display)

func _exit_tree() -> void:
remove_child(performance_display)
performance_display.free()

func _process(delta):
FmodServer.update()

func _notification(what):
FmodServer.notification(what)
1 change: 1 addition & 0 deletions src/addons/fmod/FmodManager.gd.uid
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
uid://cds10pm7hwn3p
78 changes: 78 additions & 0 deletions src/addons/fmod/FmodPlugin.gd
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
@tool
class_name FmodPlugin extends EditorPlugin


const ADDON_PATH = "res://addons/fmod"


@onready var theme = get_editor_interface().get_base_control().get_theme()


var fmod_bank_explorer_window: PackedScene = load("res://addons/fmod/tool/ui/FmodBankExplorer.tscn")
var bank_explorer: FmodBankExplorer
var fmod_button: Button
var export_plugin = FmodEditorExportPlugin.new()
var emitter_inspector_plugin = FmodEmitterPropertyInspectorPlugin.new(self)
var bank_loader_inspector_plugin = FmodBankLoaderPropertyInspectorPlugin.new(self)


func _init():
FmodBankDatabase.reload_all_banks()

add_autoload_singleton("FmodManager", "res://addons/fmod/FmodManager.gd")
fmod_button = Button.new()
fmod_button.icon = load("res://addons/fmod/icons/fmod_icon.svg")
fmod_button.text = "Fmod Explorer"

fmod_button.pressed.connect(_on_project_explorer_button_clicked)

add_control_to_container(EditorPlugin.CONTAINER_TOOLBAR, fmod_button)

bank_explorer = fmod_bank_explorer_window.instantiate()
bank_explorer.theme = get_editor_interface().get_base_control().get_theme()
bank_explorer.visible = false
add_child(bank_explorer)

add_inspector_plugin(bank_loader_inspector_plugin)
add_inspector_plugin(emitter_inspector_plugin)


func _on_project_explorer_button_clicked():
bank_explorer.should_display_copy_buttons = true
bank_explorer.should_display_select_button = false
_popup_project_explorer(FmodBankExplorer.ToDisplayFlags.BANKS | FmodBankExplorer.ToDisplayFlags.BUSES | FmodBankExplorer.ToDisplayFlags.VCA | FmodBankExplorer.ToDisplayFlags.EVENTS)


func open_project_explorer_events(on_select_callable: Callable):
_open_project_explorer(FmodBankExplorer.ToDisplayFlags.BANKS | FmodBankExplorer.ToDisplayFlags.EVENTS, on_select_callable)


func open_project_explorer_bank(on_select_callable: Callable):
_open_project_explorer(FmodBankExplorer.ToDisplayFlags.BANKS, on_select_callable)


func _open_project_explorer(display_flag: int, on_select_callable: Callable):
bank_explorer.should_display_copy_buttons = false
bank_explorer.should_display_select_button = true
_popup_project_explorer(display_flag, on_select_callable)


func _popup_project_explorer(to_display: int, callable: Callable = Callable()):
if bank_explorer.visible == true:
bank_explorer.close_window()
return
bank_explorer.regenerate_tree(to_display, callable)
bank_explorer.popup_centered()


func _enter_tree():
add_export_plugin(export_plugin)


func _exit_tree():
remove_inspector_plugin(emitter_inspector_plugin)
remove_inspector_plugin(bank_loader_inspector_plugin)

remove_control_from_container(EditorPlugin.CONTAINER_TOOLBAR, fmod_button)
fmod_button.queue_free()
remove_export_plugin(export_plugin)
1 change: 1 addition & 0 deletions src/addons/fmod/FmodPlugin.gd.uid
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
uid://cwsif6rhp50p5
101 changes: 101 additions & 0 deletions src/addons/fmod/fmod.gdextension
Original file line number Diff line number Diff line change
@@ -0,0 +1,101 @@
[configuration]
entry_symbol = "fmod_library_init"
compatibility_minimum = 4.2

[libraries]
windows.editor.x86_64 = "res://addons/fmod/libs/windows/libGodotFmod.windows.editor.x86_64.dll"
windows.debug.x86_64 = "res://addons/fmod/libs/windows/libGodotFmod.windows.template_debug.x86_64.dll"
windows.release.x86_64 = "res://addons/fmod/libs/windows/libGodotFmod.windows.template_release.x86_64.dll"
macos.editor = "res://addons/fmod/libs/macos/libGodotFmod.macos.editor.framework"
macos.debug = "res://addons/fmod/libs/macos/libGodotFmod.macos.template_debug.framework"
macos.release = "res://addons/fmod/libs/macos/libGodotFmod.macos.template_release.framework"
linux.editor.x86_64 = "res://addons/fmod/libs/linux/libGodotFmod.linux.editor.x86_64.so"
linux.debug.x86_64 = "res://addons/fmod/libs/linux/libGodotFmod.linux.template_debug.x86_64.so"
linux.release.x86_64 = "res://addons/fmod/libs/linux/libGodotFmod.linux.template_release.x86_64.so"
android.debug.x86_64 = "res://addons/fmod/libs/android/x86_64/libGodotFmod.android.template_debug.x86_64.so"
android.release.x86_64 = "res://addons/fmod/libs/android/x86_64/libGodotFmod.android.template_release.x86_64.so"
android.debug.arm64 = "res://addons/fmod/libs/android/arm64/libGodotFmod.android.template_debug.arm64.so"
android.release.arm64 = "res://addons/fmod/libs/android/arm64/libGodotFmod.android.template_release.arm64.so"
ios.debug = "res://addons/fmod/libs/ios/libGodotFmod.ios.template_debug.xcframework"
ios.release = "res://addons/fmod/libs/ios/libGodotFmod.ios.template_release.xcframework"

[icons]
FmodEventEmitter2D = "res://addons/fmod/icons/fmod_icon.svg"
FmodEventEmitter3D = "res://addons/fmod/icons/fmod_icon.svg"
FmodListener2D = "res://addons/fmod/icons/fmod_icon.svg"
FmodListener3D = "res://addons/fmod/icons/fmod_icon.svg"
FmodBankLoader = "res://addons/fmod/icons/fmod_icon.svg"

[dependencies]
windows.editor.x86_64 = {
"libs/windows/fmodL.dll": "",
"libs/windows/fmodstudioL.dll": ""
}
windows.debug.x86_64 = {
"libs/windows/fmodL.dll": "",
"libs/windows/fmodstudioL.dll": ""
}
windows.release.x86_64 = {
"libs/windows/fmod.dll": "",
"libs/windows/fmodstudio.dll": ""
}
linux.editor.x86_64 = {
"libs/linux/libfmodL.so": "",
"libs/linux/libfmodL.so.14": "",
"libs/linux/libfmodL.so.14.6": "",
"libs/linux/libfmodstudioL.so": "",
"libs/linux/libfmodstudioL.so.14": "",
"libs/linux/libfmodstudioL.so.14.6": ""
}
linux.debug.x86_64 = {
"libs/linux/libfmodL.so": "",
"libs/linux/libfmodL.so.14": "",
"libs/linux/libfmodL.so.14.6": "",
"libs/linux/libfmodstudioL.so": "",
"libs/linux/libfmodstudioL.so.14": "",
"libs/linux/libfmodstudioL.so.14.6": ""
}
linux.release.x86_64 = {
"libs/linux/libfmod.so": "",
"libs/linux/libfmod.so.14": "",
"libs/linux/libfmod.so.14.6": "",
"libs/linux/libfmodstudio.so": "",
"libs/linux/libfmodstudio.so.14": "",
"libs/linux/libfmodstudio.so.14.6": ""
}
macos.editor = {
"libs/macos/libfmodL.dylib": "",
"libs/macos/libfmodstudioL.dylib": ""
}
macos.debug = {
"libs/macos/libfmodL.dylib": "",
"libs/macos/libfmodstudioL.dylib": ""
}
macos.release = {
"libs/macos/libfmod.dylib": "",
"libs/macos/libfmodstudio.dylib": ""
}
android.debug.x86_64 = {
"libs/android/x86_64/libfmodL.so": "",
"libs/android/x86_64/libfmodstudioL.so": "",
}
android.release.x86_64 = {
"libs/android/x86_64/libfmod.so": "",
"libs/android/x86_64/libfmodstudio.so": "",
}
android.debug.arm64 = {
"libs/android/arm64/libfmodL.so": "",
"libs/android/arm64/libfmodstudioL.so": "",
}
android.release.arm64 = {
"libs/android/arm64/libfmod.so": "",
"libs/android/arm64/libfmodstudio.so": "",
}
ios.debug = {
"libs/ios/libfmodL_iphoneos.a": "",
"libs/ios/libfmodstudioL_iphoneos.a": ""
}
ios.release = {
"libs/ios/libfmod_iphoneos.a": "",
"libs/ios/libfmodstudio_iphoneos.a": ""
}
1 change: 1 addition & 0 deletions src/addons/fmod/fmod.gdextension.uid
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
uid://dq17s7r52klxe
3 changes: 3 additions & 0 deletions src/addons/fmod/icons/bank_icon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
38 changes: 38 additions & 0 deletions src/addons/fmod/icons/bank_icon.svg.import
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
[remap]

importer="texture"
type="CompressedTexture2D"
uid="uid://o2chsr07oeqs"
path="res://.godot/imported/bank_icon.svg-8de6c7bff09a67352e162b3c61b601de.ctex"
metadata={
"has_editor_variant": true,
"vram_texture": false
}

[deps]

source_file="res://addons/fmod/icons/bank_icon.svg"
dest_files=["res://.godot/imported/bank_icon.svg-8de6c7bff09a67352e162b3c61b601de.ctex"]

[params]

compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/hdr_compression=1
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=false
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/fix_alpha_border=true
process/premult_alpha=false
process/normal_map_invert_y=false
process/hdr_as_srgb=false
process/hdr_clamp_exposure=false
process/size_limit=0
detect_3d/compress_to=1
svg/scale=1.0
editor/scale_with_editor_scale=true
editor/convert_colors_with_editor_theme=true
3 changes: 3 additions & 0 deletions src/addons/fmod/icons/bus_icon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
38 changes: 38 additions & 0 deletions src/addons/fmod/icons/bus_icon.svg.import
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
[remap]

importer="texture"
type="CompressedTexture2D"
uid="uid://dj1kag4aeg58t"
path="res://.godot/imported/bus_icon.svg-f536ffd3c4893e79a9d3cb9a1b4fb50c.ctex"
metadata={
"has_editor_variant": true,
"vram_texture": false
}

[deps]

source_file="res://addons/fmod/icons/bus_icon.svg"
dest_files=["res://.godot/imported/bus_icon.svg-f536ffd3c4893e79a9d3cb9a1b4fb50c.ctex"]

[params]

compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/hdr_compression=1
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=false
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/fix_alpha_border=true
process/premult_alpha=false
process/normal_map_invert_y=false
process/hdr_as_srgb=false
process/hdr_clamp_exposure=false
process/size_limit=0
detect_3d/compress_to=1
svg/scale=1.0
editor/scale_with_editor_scale=true
editor/convert_colors_with_editor_theme=true
3 changes: 3 additions & 0 deletions src/addons/fmod/icons/c_parameter_icon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
38 changes: 38 additions & 0 deletions src/addons/fmod/icons/c_parameter_icon.svg.import
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
[remap]

importer="texture"
type="CompressedTexture2D"
uid="uid://cmvcqfsl167te"
path="res://.godot/imported/c_parameter_icon.svg-04115c2482c9a6874356ffdc09c41db0.ctex"
metadata={
"has_editor_variant": true,
"vram_texture": false
}

[deps]

source_file="res://addons/fmod/icons/c_parameter_icon.svg"
dest_files=["res://.godot/imported/c_parameter_icon.svg-04115c2482c9a6874356ffdc09c41db0.ctex"]

[params]

compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/hdr_compression=1
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=false
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/fix_alpha_border=true
process/premult_alpha=false
process/normal_map_invert_y=false
process/hdr_as_srgb=false
process/hdr_clamp_exposure=false
process/size_limit=0
detect_3d/compress_to=1
svg/scale=1.0
editor/scale_with_editor_scale=true
editor/convert_colors_with_editor_theme=true
Loading
Loading