Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ssw.bat
- ---------
- @echo off
- :: V 2.1 patch
- :: fixed stonecutter recipes (count required)
- :: fixed furnance recipes (misuse of tag, where item should be)
- :: Version 2
- :: can handle spaces in folder/path names [for temp folder holding the output files only. folder structure with spaces is not supported by minecraft datapacks/mods]
- :: All variables are stored in the ssw.bat file -No Quotes / spaces supported in file/block name
- :: slabs / stairs / walls Reciepe creator (stone cutter & table crafting)
- :: Sand blocks & Sandstone blocks get extra done
- :: Sand & sandstone entered with name without the suffix (grey_cracked_sand_stone would be grey_cracked sandstone // purple_sand would be entered as purple sand)
- :: creates crafting for each of the sandstones for the others in the stone cutter
- :: assumes each block given will have walls/slabs/stairs of it
- :: separate batch files for compatibility & cross usage in a folder that is in the environmental path variables.
- :: -- Call can link to a full path where files kept w/ environmental path variable use
- :: ---
- :: updates
- :: added support for folders with spaces (note, folder structure with spaces is not supported by minecraft datapacks/mods)
- :: mcaid(furn/cfire/stoncut/table) -- support for path spaces pass through (note, folder structure with spaces is not supported by minecraft datapacks/mods)
- :: mcaid(furn/cfire/stoncut/table) -- tweaked to signal start of file (to overwrite old files of the same name & prevent corrupted files)
- :: mcaid(furn/cfire/stoncut/table)/filwrite -- introduced exit /b to close the files if the first argument is missing. (attempting to prevent accidental execution & errors)
- :: filwrite -- organized & fat cutout (28 to 9 lines w/ exit condition, & new switch)
- :: filwrite -- new switch to indicate to overwrite file of the same name or append to it.
- :: ssw -- formatting & notes used to keep human readable & allow Understanding of what is being used where
- goto Start
- :primevar
- :: do not use Quote marks in mod or paths
- set MOD=vanilla_reclaim
- set BASEFOLDER=F:\Minecraft-aidfiles\
- set STONEC=%BASEFOLDER%stone-cutter\
- set TABLEC=%BASEFOLDER%table\
- set CAMPC=%BASEFOLDER%campfire\
- set FURNC=%BASEFOLDER%furnance\
- set CCSSTONE=%CAMPC%sandstone\
- set FCGLASS=%FURNC%glass\
- set SCSTAIR=%STONEC%stair\
- set SCWALL=%STONEC%wall\
- set SCSLAB=%STONEC%slab\
- set TCSTAIR=%TABLEC%stair\
- set TCWALL=%TABLEC%wall\
- set TCSLAB=%TABLEC%slab\
- :: sandstone/sand value setting, do not touch
- set SANDSTONE=no
- set SAND=no
- exit /b
- :Start
- call :primevar
- if ["%1"]==[""] goto End
- set NAMES=%~1
- if ["%2"]==["sandstone"] set SANDSTONE=yes
- if ["%2"]==["sand"] set SAND=yes
- goto Reciepe
- :Reciepe
- if %SAND%==yes (
- call :reciepewrite heavy_%NAMES%_sand off off
- call :reciepewrite loose_%NAMES%_sand off off
- call :reciepewrite %NAMES%_sand sandy %NAMES%
- goto End
- )
- if %SANDSTONE%==yes (
- call :reciepewrite %NAMES%_sand_stone sandstone %NAMES%
- call :reciepewrite %NAMES%_cut_sand_stone off off
- call :reciepewrite %NAMES%_chiseled_sand_stone off off
- call :reciepewrite %NAMES%_smooth_sand_stone off off
- goto End
- )
- call :reciepewrite %NAMES% off off
- :End
- exit /b
- :reciepewrite
- set twmess=%1
- set temptwmess=%3
- set alt=%2
- if ["%alt%"]==["sandstone"] (
- :: stonecutter swapping for sandstones
- call :stonecut "%STONEC%" %temptwmess%_cut_sand_stone twist %temptwmess%_sand_stone
- call :stonecut "%STONEC%" %temptwmess%_chiseled_sand_stone twist %temptwmess%_sand_stone
- call :stonecut "%STONEC%" %temptwmess%_smooth_sand_stone twist %temptwmess%_sand_stone
- call :stonecut "%STONEC%" %temptwmess%_sand_stone twist %temptwmess%_cut_sand_stone
- call :stonecut "%STONEC%" %temptwmess%_chiseled_sand_stone twist %temptwmess%_cut_sand_stone
- call :stonecut "%STONEC%" %temptwmess%_smooth_sand_stone twist %temptwmess%_cut_sand_stone
- call :stonecut "%STONEC%" %temptwmess%_sand_stone twist %temptwmess%_chiseled_sand_stone
- call :stonecut "%STONEC%" %temptwmess%_cut_sand_stone twist %temptwmess%_chiseled_sand_stone
- call :stonecut "%STONEC%" %temptwmess%_smooth_sand_stone twist %temptwmess%_chiseled_sand_stone
- call :stonecut "%STONEC%" %temptwmess%_sand_stone twist %temptwmess%_smooth_sand_stone
- call :stonecut "%STONEC%" %temptwmess%_cut_sand_stone twist %temptwmess%_smooth_sand_stone
- call :stonecut "%STONEC%" %temptwmess%_chiseled_sand_stone twist %temptwmess%_smooth_sand_stone
- :: Table Crafting for the sandstones
- call :table "%TABLEC%" %temptwmess%_sand square %temptwmess%_sand_stone 4
- call :table "%TABLEC%" %temptwmess%_sand_stone square %temptwmess%_cut_sand_stone 4
- call :table "%TABLEC%" %temptwmess%_cut_sand_stone square %temptwmess%_chiseled_sand_stone 4
- :: Campe fire crafting for sand version to smoothstone
- call :campfire "%CCSSTONE%" %temptwmess%_sand 300 0.35 %temptwmess%_smooth_sand_stone
- )
- if ["%alt%"]==["sandy"] call :furn %FCGLASS% %temptwmess%_sand 200 0.1 %temptwmess%_glass
- call :stonecut "%SCSTAIR%" %twmess% stair %twmess%_stair
- call :stonecut "%SCWALL%" %twmess% wall %twmess%_wall
- call :stonecut "%SCSLAB%" %twmess% slab %twmess%_slab
- call :table "%TCSTAIR%" %twmess% stair %twmess%_stair 4
- call :table "%TCWALL%" %twmess% wall %twmess%_wall 6
- call :table "%TCSLAB%" %twmess% wall %twmess%_slab 6
- exit /b
- :stonecut
- :: arguments(in number order) - Path / Name1 / Name2 / Type
- call mcaidstoncut %1 %2 %4 %3 %MOD%
- exit /b
- :table
- :: arguments(in number order) - Path / Name1 / Type / Name2 / Craft_Number
- call mcaidtable %3 %5 %2 %4 %1 %MOD%
- exit /b
- :campfire
- :: arguments(in number order) - Path / Name1 / Cook_time / Exp / Name2
- call mcaidcfire %1 %3 %4 %2 %5 %MOD%
- exit /b
- :furn
- :: arguments(in number order) - Path / Name1 / Cook_time / EXP / Name 2
- call mcaidfurn %1 %3 %4 %2 %5 %MOD%
- exit /b
- --------------------------------------------------------------------------------------------------------------------------------------
- mcaidtable.bat
- ------
- @echo off
- if ["%1"]==[""] goto End
- set oext=json
- set patnum=%~1
- set cntnum=%2
- set tempora=%3
- set temporatwo=%4
- set tempath=%~5
- set tmod=%6
- call filwrite "%tempath%" { %temporatwo% %oext% new
- call filwrite "%tempath%" " "type": "minecraft:crafting_shaped"," %temporatwo% %oext%
- :: echo used over call for patterns Consistency of use (double spaces in paterns broke arguments)
- if ["%patnum%"]==["square"] echo "pattern": [ "yy","yy" ], >> %tpath%%temporatwo%.%oext%
- if ["%patnum%"]==["stair"] echo "pattern": [ "y ","yy ","yyy" ], >> %tpath%%temporatwo%.%oext%
- if ["%patnum%"]==["wall"] echo "pattern": [ "yyy","yyy" ], >> %tpath%%temporatwo%.%oext%
- if ["%patnum%"]==["slab"] echo "pattern": [ "yyy" ], >> %tpath%%temporatwo%.%oext%
- call filwrite "%tempath%" " "key": {" %temporatwo% %oext%
- call filwrite "%tempath%" " "y": {" %temporatwo% %oext%
- call filwrite "%tempath%" " "item": "%tmod%:%tempora%"" %temporatwo% %oext%
- call filwrite "%tempath%" " }" %temporatwo% %oext%
- call filwrite "%tempath%" " }," %temporatwo% %oext%
- call filwrite "%tempath%" " "result":{" %temporatwo% %oext%
- call filwrite "%tempath%" " "item": "%tmod%:%temporatwo%"," %temporatwo% %oext%
- call filwrite "%tempath%" " "count": %cntnum%" %temporatwo% %oext%
- call filwrite "%tempath%" " }" %temporatwo% %oext%
- call filwrite "%tempath%" } %temporatwo% %oext%
- echo file %tpath%%temporatwo%.%oext%
- :End
- exit /b
- --------------------------------------------------------------------------------------------------------------------------------------
- mcaidstoncut.bat
- ------------------
- @echo off
- if ["%1"]==[""] goto End
- set oext=json
- set tpath=%~1
- set tempora=%2
- set temporatwo=%3
- set temalt=%4
- set tmod=%5
- set fout=%temporatwo%_from_%tempora%
- call filwrite "%tpath%" { %fout% %oext% new
- call filwrite "%tpath%" " "type": "minecraft:stonecutting"," %fout% %oext%
- call filwrite "%tpath%" " "ingredient": {" %fout% %oext%
- call filwrite "%tpath%" " "item": "%tmod%:%tempora%"" %fout% %oext%
- call filwrite "%tpath%" " }," %fout% %oext%
- call filwrite "%tpath%" " "result": "%tmod%:%temporatwo%"," %fout% %oext%
- if %temalt%==slab ( call filwrite "%tpath%" " "count": 2" %fout% %oext%) else call filwrite "%tpath%" " "count": 1" %fout% %oext%
- call filwrite "%tpath%" } %fout% %oext%
- echo file %tpath%%fout%.%oext%
- :End
- exit /b
- --------------------------------------------------------------------------------------------------------------------------------------
- mcaidfurn.bat
- ---------------
- @echo off
- if ["%1"]==[""] goto End
- set oext=json
- set tpath=%~1
- set ctime=%2
- set exp=%3
- set temnam=%4
- set outnam=%5
- set tmod=%6
- call filwrite "%tpath%" { %outnam% %oext% new
- call filwrite "%tpath%" " "type": "minecraft:smelting"," %outnam% %oext%
- call filwrite "%tpath%" " "ingredient": {" %outnam% %oext%
- call filwrite "%tpath%" " "item": "%tmod%:%temnam%"" %outnam% %oext%
- call filwrite "%tpath%" " }," %outnam% %oext%
- call filwrite "%tpath%" " "result": "%tmod%:%outnam%"," %outnam% %oext%
- call filwrite "%tpath%" " "experience": %exp%," %outnam% %oext%
- call filwrite "%tpath%" " "cookingtime": %ctime%" %outnam% %oext%
- call filwrite "%tpath%" } %outnam% %oext%
- echo file %tpath%%outnam%.%oext%
- :End
- exit /b
- --------------------------------------------------------------------------------------------------------------------------------------
- mcaidcfire.bat
- ----------------
- @echo off
- if ["%1"]==[""] goto End
- set oext=json
- set temname=%4
- set temnametwo=%5
- set tpath=%~1
- set ctime=%2
- set exp=%3
- set tmod=%6
- call filwrite "%tpath%" { %temnametwo% %oext% new
- call filwrite "%tpath%" " "type": "minecraft:campfire_cooking"," %temnametwo% %oext%
- call filwrite "%tpath%" " "ingredient": {" %temnametwo% %oext%
- call filwrite "%tpath%" " "item": "%tmod%:%temname%"" %temnametwo% %oext%
- call filwrite "%tpath%" " }," %temnametwo% %oext%
- call filwrite "%tpath%" " "result": "%tmod%:%temnametwo%"," %temnametwo% %oext%
- call filwrite "%tpath%" " "experience": %exp%," %temnametwo% %oext%
- call filwrite "%tpath%" " "cookingtime": %ctime%" %temnametwo% %oext%
- call filwrite "%tpath%" } %temnametwo% %oext%
- echo file %tpath%%temnametwo%.%oext%
- :End
- exit /b
- --------------------------------------------------------------------------------------------------------------------------------------
- filwrite.bat
- --------------
- @echo off
- if ["%1"]==[""] goto End
- set tpath=%~1
- if NOT EXIST %tpath% mkdir %tpath%
- set tout=%tpath%%~3.%~4
- if ["%~5"]==["new"] ( set toper=^>) else set toper=^>^>
- echo %~2 %toper% %tout%
- :End
- exit /b
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement