-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
79 changed files
with
718 additions
and
444 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
44 changes: 44 additions & 0 deletions
44
api/src/main/java/io/pzstorm/storm/event/OnLoadSoundBankEvent.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
/* | ||
* Zomboid Storm - Java modding toolchain for Project Zomboid | ||
* Copyright (C) 2021 Matthew Cain | ||
* | ||
* This program is free software: you can redistribute it and/or modify | ||
* it under the terms of the GNU General Public License as published by | ||
* the Free Software Foundation, either version 3 of the License, or | ||
* (at your option) any later version. | ||
* | ||
* This program is distributed in the hope that it will be useful, | ||
* but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
* GNU General Public License for more details. | ||
* | ||
* You should have received a copy of the GNU General Public License | ||
* along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
*/ | ||
|
||
package io.pzstorm.storm.event; | ||
|
||
import io.pzstorm.storm.event.lua.LuaEvent; | ||
|
||
/** | ||
* This event triggers when a sound bank is being loaded. | ||
* Users can use this event to change the path of sound banks being loaded, | ||
* effectively replacing vanilla with their own custom sound banks. | ||
*/ | ||
@SuppressWarnings({ "WeakerAccess", "unused" }) | ||
public class OnLoadSoundBankEvent implements LuaEvent { | ||
|
||
/** | ||
* {@code StringBuffer} containing the string that denotes the path to the sound bank being loaded. | ||
* In order to replace the given path with a custom path you can do the following: | ||
* <pre> | ||
* String customPath = "path/to/custom/sound/bank"; | ||
* soundBankPath.delete(0, soundBankPath.length()).append(customPath); | ||
* </pre> | ||
*/ | ||
public final StringBuffer soundBankPath; | ||
|
||
public OnLoadSoundBankEvent(StringBuffer soundBankPath) { | ||
this.soundBankPath = soundBankPath; | ||
} | ||
} |
35 changes: 35 additions & 0 deletions
35
api/src/main/java/io/pzstorm/storm/event/OnLoadSoundBanksEvent.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
/* | ||
* Zomboid Storm - Java modding toolchain for Project Zomboid | ||
* Copyright (C) 2021 Matthew Cain | ||
* | ||
* This program is free software: you can redistribute it and/or modify | ||
* it under the terms of the GNU General Public License as published by | ||
* the Free Software Foundation, either version 3 of the License, or | ||
* (at your option) any later version. | ||
* | ||
* This program is distributed in the hope that it will be useful, | ||
* but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
* GNU General Public License for more details. | ||
* | ||
* You should have received a copy of the GNU General Public License | ||
* along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
*/ | ||
|
||
package io.pzstorm.storm.event; | ||
|
||
/** | ||
* <p>This event triggers after vanilla FMOD sound banks finish loading.</p> | ||
* You can use this event to load custom sound banks like this: | ||
* <pre> | ||
* String path = "path/to/sound/bank"; | ||
* javafmod.FMOD_Studio_System_LoadBankFile(path); | ||
* </pre> | ||
*/ | ||
public class OnLoadSoundBanksEvent implements ZomboidEvent { | ||
|
||
@Override | ||
public String getName() { | ||
return "OnLoadSoundBanks"; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.