UnloadSample
function instead of calling the separate Stop
function which is not supposed to be used for samples which are not loaded. The UnloadSample
function also needs to handle samples which are not (fully) loaded to free the sample index when the sound failed to be loaded.
Regression from #9431.
====================[ Build | game-server | Debug ]=============================
D:\JetBrains\CLion\bin\cmake\win\x64\bin\cmake.exe --build D:\CLion\ddnet\cmake-build-debug --target game-server -j 10
[0/2] Generating debug/libddnet_engine_shared.a
Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.15s
[2/2] Linking CXX executable DDNet-Server.exe
FAILED: DDNet-Server.exe
C:\Windows\system32\cmd.exe /C "cd . && D:\JetBrains\CLion\bin\mingw\bin\g++.exe -g @CMakeFiles\game-server.rsp -o DDNet-Server.exe -Wl,--out-implib,libDDNet-Server.dll.a -Wl,--major-image-version,0,--minor-image-version,0 && cd ."
D:\JetBrains\CLion\bin\mingw\bin/ld.exe: cannot find debug/libddnet_engine_shared.a: No such file or directory
collect2.exe: error: ld returned 1 exit status
ninja: build stopped: subcommand failed.
I run rustup install stable-x86_64-pc-windows-msvc
after rustup default stable-x86_64-pc-windows-msvc
. Then I run the build but an error pops up. Can anyone help me? (edited)PS D:\CLion\ddnet> rustup default stable-x86_64-windows-gnu
error: toolchain 'stable-x86_64-windows-gnu' is not installed
PS D:\CLion\ddnet> rustup install stable-x86_64-windows-gnu
error: error: invalid value 'stable-x86_64-windows-gnu' for '<toolchain>...': invalid toolchain name: 'stable-x86_64-windows-gnu'