-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
OFF+ & Additional Equipment patch: Release v1.0 - Give OFF+ starting Assassin bro Reinforced Padded Armor Expanded Markets & Additional Equipment patch: Release v1.0 - Add Masked Nomad Light Helmet to Nomad gear list
- Loading branch information
0 parents
commit d7e4702
Showing
7 changed files
with
210 additions
and
0 deletions.
There are no files selected for viewing
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,3 @@ | ||
dist/ | ||
old_versions/ | ||
testing/ |
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,59 @@ | ||
@echo off | ||
|
||
set modname=off_plus_additional_equipment_patch | ||
set modkitdir=YOUR_MODKIT_BIN_PATH | ||
set version=1.0 | ||
|
||
echo. | ||
echo Creating temporary directory... | ||
echo. | ||
|
||
@REM /i means create tmp\scripts if it's not there, /e means copy subdirectories even if empty, /f outputs full src/dst paths (if you want), /y means overwrite, /c ignores errors | ||
mkdir "%~dp0\tmp_scripts" | ||
xcopy "%~dp0\scripts\!mods_preload\mod_p_offp_sae*" "%~dp0\tmp_scripts\" /i /e /y | ||
|
||
cd "%modkitdir%" | ||
CALL "%modkitdir%\masscompile.bat" "%~dp0\tmp_scripts" | ||
|
||
REM %~dp0 refers to the drive letter + path of where THIS batch file lives | ||
|
||
echo. | ||
echo Copying files to dist\scripts | ||
echo. | ||
|
||
REM after build, copy scripts folder to dist\scripts folder. /i means create dist\scripts if it's not there, /e means copy subdirectories even if empty, /f outputs full src/dst paths (if you want), /y means overwrite, /c ignores errors | ||
xcopy "%~dp0\tmp_scripts" "%~dp0\dist\scripts" /i /e /y /c | ||
|
||
echo %~dp0 | ||
|
||
echo. | ||
echo Removing temporary directory... | ||
echo. | ||
|
||
REM Remove tmp_scripts directory | ||
rmdir "%~dp0\tmp_scripts" /s /q | ||
|
||
echo. | ||
echo Removing uncompiled source from dist... | ||
echo. | ||
|
||
REM Remove uncompiled source from dist\scripts directory | ||
for /r "%~dp0\dist\scripts" %%f in (*.nut) do del /f /q "%%f" | ||
|
||
echo. | ||
echo Packaging mod into .zip... | ||
echo. | ||
|
||
REM Requires Powershell 5.0 / .NET Framework 4.x (some claim 4, some claim 4.5, some claim 4.8) | ||
powershell.exe -nologo -noprofile -command "& { Compress-Archive -Force -Path '%~dp0\dist\scripts' -DestinationPath '%~dp0\dist\%modname%_%version%.zip' }" | ||
|
||
echo. | ||
echo Cleaning up dist\scripts | ||
echo. | ||
|
||
REM Remove dist\scripts directory | ||
rmdir "%~dp0\dist\scripts" /s /q | ||
|
||
echo Done. | ||
|
||
pause |
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,59 @@ | ||
@echo off | ||
|
||
set modname=expanded_markets_additional_equipment_patch | ||
set modkitdir=YOUR_MODKIT_BIN_PATH | ||
set version=1.0 | ||
|
||
echo. | ||
echo Creating temporary directory... | ||
echo. | ||
|
||
@REM /i means create tmp\scripts if it's not there, /e means copy subdirectories even if empty, /f outputs full src/dst paths (if you want), /y means overwrite, /c ignores errors | ||
mkdir "%~dp0\tmp_scripts" | ||
xcopy "%~dp0\scripts\!mods_preload\mod_p_sem_sae*" "%~dp0\tmp_scripts\" /i /e /y | ||
|
||
cd "%modkitdir%" | ||
CALL "%modkitdir%\masscompile.bat" "%~dp0\tmp_scripts" | ||
|
||
REM %~dp0 refers to the drive letter + path of where THIS batch file lives | ||
|
||
echo. | ||
echo Copying files to dist\scripts | ||
echo. | ||
|
||
REM after build, copy scripts folder to dist\scripts folder. /i means create dist\scripts if it's not there, /e means copy subdirectories even if empty, /f outputs full src/dst paths (if you want), /y means overwrite, /c ignores errors | ||
xcopy "%~dp0\tmp_scripts" "%~dp0\dist\scripts" /i /e /y /c | ||
|
||
echo %~dp0 | ||
|
||
echo. | ||
echo Removing temporary directory... | ||
echo. | ||
|
||
REM Remove tmp_scripts directory | ||
rmdir "%~dp0\tmp_scripts" /s /q | ||
|
||
echo. | ||
echo Removing uncompiled source from dist... | ||
echo. | ||
|
||
REM Remove uncompiled source from dist\scripts directory | ||
for /r "%~dp0\dist\scripts" %%f in (*.nut) do del /f /q "%%f" | ||
|
||
echo. | ||
echo Packaging mod into .zip... | ||
echo. | ||
|
||
REM Requires Powershell 5.0 / .NET Framework 4.x (some claim 4, some claim 4.5, some claim 4.8) | ||
powershell.exe -nologo -noprofile -command "& { Compress-Archive -Force -Path '%~dp0\dist\scripts' -DestinationPath '%~dp0\dist\%modname%_%version%.zip' }" | ||
|
||
echo. | ||
echo Cleaning up dist\scripts | ||
echo. | ||
|
||
REM Remove dist\scripts directory | ||
rmdir "%~dp0\dist\scripts" /s /q | ||
|
||
echo Done. | ||
|
||
pause |
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,32 @@ | ||
@echo off | ||
set modname=off_plus_additional_equipment_patch | ||
set year=%DATE:~10,4% | ||
set month=%DATE:~4,2% | ||
set day=%DATE:~7,2% | ||
set ymddate=%year%-%month%-%day% | ||
|
||
set paddedtime=%TIME: =0% | ||
set hour=%paddedtime:~0,2% | ||
set min=%paddedtime:~3,2% | ||
set sec=%paddedtime:~6,2% | ||
set hmstime=%hour%%min%%sec% | ||
|
||
set datadir=YOUR_DATA_DIR | ||
|
||
echo. | ||
echo Preserving old version, if any, in data directory... | ||
echo. | ||
|
||
REM Make a directory for old versions, if necessary, silencing error output | ||
mkdir "%~dp0\old_versions" > nul 2> nul | ||
move "%datadir%\%modname%*.zip" "%~dp0\old_versions\%modname%-%ymddate%-%hmstime%.zip" | ||
|
||
echo. | ||
echo Installing new version, if any, to data directory... | ||
echo. | ||
|
||
move "%~dp0\dist\%modname%*.zip" "%datadir%\" 2> nul | ||
|
||
echo Done. | ||
|
||
pause |
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,32 @@ | ||
@echo off | ||
set modname=expanded_markets_additional_equipment_patch | ||
set year=%DATE:~10,4% | ||
set month=%DATE:~4,2% | ||
set day=%DATE:~7,2% | ||
set ymddate=%year%-%month%-%day% | ||
|
||
set paddedtime=%TIME: =0% | ||
set hour=%paddedtime:~0,2% | ||
set min=%paddedtime:~3,2% | ||
set sec=%paddedtime:~6,2% | ||
set hmstime=%hour%%min%%sec% | ||
|
||
set datadir=YOUR_DATA_DIR | ||
|
||
echo. | ||
echo Preserving old version, if any, in data directory... | ||
echo. | ||
|
||
REM Make a directory for old versions, if necessary, silencing error output | ||
mkdir "%~dp0\old_versions" > nul 2> nul | ||
move "%datadir%\%modname%*.zip" "%~dp0\old_versions\%modname%-%ymddate%-%hmstime%.zip" | ||
|
||
echo. | ||
echo Installing new version, if any, to data directory... | ||
echo. | ||
|
||
move "%~dp0\dist\%modname%*.zip" "%datadir%\" 2> nul | ||
|
||
echo Done. | ||
|
||
pause |
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,17 @@ | ||
::mods_registerMod("off_plus_additional_equipment_patch", 1.0, "OFF+ & Additional Equipment Patch"); | ||
|
||
::mods_queue("off_plus_additional_equipment_patch", "of_flesh_and_faith_plus, sato_additional_equipment(>=3.2)", function() { | ||
::mods_hookExactClass("scenarios/world/southern_assassins_scenario", function(sas) { | ||
local onSpawnAssets = ::mods_getMember(sas, "onSpawnAssets"); | ||
|
||
::mods_override(sas, "onSpawnAssets", function() { | ||
onSpawnAssets(); | ||
|
||
local roster = World.getPlayerRoster(); | ||
local bros = roster.getAll(); | ||
local items = bros[1].getItems(); | ||
items.unequip(items.getItemAtSlot(Const.ItemSlot.Body)); | ||
items.equip(new("scripts/items/armor/oriental/reinforced_padded_armor")); | ||
}); | ||
}); | ||
}); |
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,8 @@ | ||
::mods_registerMod("expanded_markets_additional_equipment_patch", 1.0, "Expanded Markets & Additional Equipment Patch"); | ||
|
||
::mods_queue("expanded_markets_additional_equipment_patch", "sato_expanded_markets(>=1.2), sato_additional_equipment(>=3.2)", function() { | ||
::SEM_SOUTHERN_ARMOR.extend([ | ||
"helmets/oriental/masked_nomad_light_helmet", | ||
"helmets/oriental/masked_nomad_light_helmet" | ||
]) | ||
}); |