summaryrefslogtreecommitdiffstats
path: root/libunity.py
diff options
context:
space:
mode:
authoryum <yum.food.vr@gmail.com>2022-10-24 22:08:06 -0700
committeryum <yum.food.vr@gmail.com>2022-10-24 22:08:06 -0700
commit08655f96dc798e3e129058a5e97c5aa7ff96e798 (patch)
treeb2543852ec52fec22319f562a737e48e95681b37 /libunity.py
parent4b0d262f4630538cc04f6e8bda407fe3f3ba213b (diff)
STT now beeps when it shows text, and can be locked to world
Empty cells are excluded from the beeping behavior. Note: I have not checked in the prefab with the audio source yet. * libtastt gen_fx now adds 3 toggles to FX layer: toggle board, toggle world lock, toggle beep sound * libunity guid_map can now append instead of replacing * TaSTT_Toggle_{On,Off}.anim now use the prefab path, as do generated animations
Diffstat (limited to 'libunity.py')
-rw-r--r--libunity.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/libunity.py b/libunity.py
index 486df9f..dcf3b69 100644
--- a/libunity.py
+++ b/libunity.py
@@ -1120,6 +1120,8 @@ if __name__ == "__main__":
"result of the computation")
parser.add_argument("--guid_map", type=str, help="Path to guid.map, " +
"generated by a previous call to `guid_map`")
+ parser.add_argument("--guid_map_append", type=bool, help="If set, " +
+ "append to GUID map instead of overwriting.")
args = parser.parse_args()
if args.cmd == "merge":
@@ -1152,6 +1154,12 @@ if __name__ == "__main__":
print("Looking up GUIDs under {}".format(args.project_root),
file=sys.stderr)
guid_map = getGuidMap(args.project_root)
+ if args.guid_map_append:
+ tmp_map = {}
+ with open(args.save_to, "rb") as f:
+ tmp_map = pickle.load(f)
+ # combine guid_map and tmp_map
+ guid_map = {**guid_map, **tmp_map}
print("Saving to {}".format(args.save_to), file=sys.stderr)
with open(args.save_to, 'wb') as f:
pickle.dump(guid_map, f)