From 0b5695acc19a3f7c5c7a874e869a96855f9cf95b Mon Sep 17 00:00:00 2001 From: Chr1Z93 Date: Tue, 25 Jun 2024 12:59:08 +0200 Subject: [PATCH] updated download button creation --- objects/AdditionalPlayerCards.2cba6b.json | 2 +- .../TheMeddlingofMeowlathotep.d02940.json | 20 ------- .../AllorNothing.72ab92.json | 20 ------- .../BadBlood.451eaa.json | 20 ------- .../BytheBook.cc7eb3.json | 20 ------- .../LaidtoRest.e2dd57.json | 20 ------- .../ReadorDie.9e73fa.json | 20 ------- .../RedTideRising.5302f2.json | 20 ------- .../RelicsofthePast.0d6da1.json | 20 ------- objects/EdgeoftheEarth.895eaa.json | 2 +- objects/EncounterSets.304ffc.json | 8 +-- objects/ReturntoTheCircleUndone.757324.json | 4 +- objects/ReturntoTheDunwichLegacy.ce9130.json | 4 +- objects/ReturntoTheForgottenAge.479ff3.json | 4 +- objects/ReturntoThePathtoCarcosa.e9889a.json | 4 +- .../ReturntotheNightoftheZealot.56270d.json | 4 +- .../CarnevaleofHorrors.23dd51.json | 20 ------- .../CurseoftheRougarou.db7039.json | 20 ------- .../FortuneandFolly.0dce91.json | 20 ------- .../GuardiansoftheAbyss.ee987d.json | 20 ------- .../MachinationsThroughTime.3c4f3c.json | 20 ------- .../MurderattheExcelsiorHotel.01d780.json | 20 ------- .../TheBlobthatAteEverything.4dee5a.json | 20 ------- .../TheLabyrinthsofLunacy.4c173f.json | 20 ------- .../TheMeddlingofMeowlathotep.d02940.json | 20 ------- .../WaroftheOuterGods.fc7674.json | 20 ------- objects/TheCircleUndone.63e097.json | 2 +- objects/TheDream-Eaters.a16a1a.json | 2 +- objects/TheFeastofHemlockVale.c740af.json | 2 +- objects/TheForgottenAge.0bcf19.json | 2 +- objects/TheInnsmouthConspiracy.465aab.json | 2 +- objects/TheScarletKeys.300fcc.json | 2 +- src/core/DownloadBox.ttslua | 56 +++++++++---------- 33 files changed, 47 insertions(+), 413 deletions(-) diff --git a/objects/AdditionalPlayerCards.2cba6b.json b/objects/AdditionalPlayerCards.2cba6b.json index d9ed5092..c193fe1d 100644 --- a/objects/AdditionalPlayerCards.2cba6b.json +++ b/objects/AdditionalPlayerCards.2cba6b.json @@ -15,7 +15,7 @@ }, "CustomMesh": { "CastShadows": true, - "ColliderURL": "https://raw.githubusercontent.com/RobMayer/TTSLibrary/master/advboxes/core_h_COL.obj", + "ColliderURL": "", "Convex": true, "CustomShader": { "FresnelStrength": 0, diff --git a/objects/BarkhamHorror.308439/TheMeddlingofMeowlathotep.d02940.json b/objects/BarkhamHorror.308439/TheMeddlingofMeowlathotep.d02940.json index e45d04c2..fc05fe53 100644 --- a/objects/BarkhamHorror.308439/TheMeddlingofMeowlathotep.d02940.json +++ b/objects/BarkhamHorror.308439/TheMeddlingofMeowlathotep.d02940.json @@ -4,26 +4,6 @@ "y": 0, "z": 0 }, - "AttachedDecals": [ - { - "CustomDecal": { - "ImageURL": "http://cloud-3.steamusercontent.com/ugc/959719855119695911/931B9829687A20F4DEADB36DA57B7E6D76792231/", - "Name": "dunwich_back", - "Size": 7.4 - }, - "Transform": { - "posX": 0, - "posY": 0, - "posZ": 0, - "rotX": 270, - "rotY": 0, - "rotZ": 0, - "scaleX": 2, - "scaleY": 2, - "scaleZ": 2 - } - } - ], "Autoraise": true, "ColorDiffuse": { "a": 0.27451, diff --git a/objects/ChallengeScenarios.9f6801/AllorNothing.72ab92.json b/objects/ChallengeScenarios.9f6801/AllorNothing.72ab92.json index b150356e..85a9793d 100644 --- a/objects/ChallengeScenarios.9f6801/AllorNothing.72ab92.json +++ b/objects/ChallengeScenarios.9f6801/AllorNothing.72ab92.json @@ -4,26 +4,6 @@ "y": 0, "z": 0 }, - "AttachedDecals": [ - { - "CustomDecal": { - "ImageURL": "http://cloud-3.steamusercontent.com/ugc/959719855119695911/931B9829687A20F4DEADB36DA57B7E6D76792231/", - "Name": "dunwich_back", - "Size": 7.4 - }, - "Transform": { - "posX": -0.0021877822, - "posY": -0.08963572, - "posZ": -0.00288731651, - "rotX": 270, - "rotY": 359.869568, - "rotZ": 0, - "scaleX": 2.00000215, - "scaleY": 2.00000238, - "scaleZ": 2.00000262 - } - } - ], "Autoraise": true, "ColorDiffuse": { "a": 0.27451, diff --git a/objects/ChallengeScenarios.9f6801/BadBlood.451eaa.json b/objects/ChallengeScenarios.9f6801/BadBlood.451eaa.json index a8fe9cf7..64678d62 100644 --- a/objects/ChallengeScenarios.9f6801/BadBlood.451eaa.json +++ b/objects/ChallengeScenarios.9f6801/BadBlood.451eaa.json @@ -4,26 +4,6 @@ "y": 0, "z": 0 }, - "AttachedDecals": [ - { - "CustomDecal": { - "ImageURL": "http://cloud-3.steamusercontent.com/ugc/959719855119695911/931B9829687A20F4DEADB36DA57B7E6D76792231/", - "Name": "dunwich_back", - "Size": 7.4 - }, - "Transform": { - "posX": -0.0021877822, - "posY": -0.08963572, - "posZ": -0.00288731651, - "rotX": 270, - "rotY": 359.869568, - "rotZ": 0, - "scaleX": 2.00000215, - "scaleY": 2.00000238, - "scaleZ": 2.00000262 - } - } - ], "Autoraise": true, "ColorDiffuse": { "a": 0.27451, diff --git a/objects/ChallengeScenarios.9f6801/BytheBook.cc7eb3.json b/objects/ChallengeScenarios.9f6801/BytheBook.cc7eb3.json index ba1c69ad..49aff845 100644 --- a/objects/ChallengeScenarios.9f6801/BytheBook.cc7eb3.json +++ b/objects/ChallengeScenarios.9f6801/BytheBook.cc7eb3.json @@ -4,26 +4,6 @@ "y": 0, "z": 0 }, - "AttachedDecals": [ - { - "CustomDecal": { - "ImageURL": "http://cloud-3.steamusercontent.com/ugc/959719855119695911/931B9829687A20F4DEADB36DA57B7E6D76792231/", - "Name": "dunwich_back", - "Size": 7.4 - }, - "Transform": { - "posX": -0.0021877822, - "posY": -0.08963572, - "posZ": -0.00288731651, - "rotX": 270, - "rotY": 359.869568, - "rotZ": 0, - "scaleX": 2.00000215, - "scaleY": 2.00000238, - "scaleZ": 2.00000262 - } - } - ], "Autoraise": true, "ColorDiffuse": { "a": 0.27451, diff --git a/objects/ChallengeScenarios.9f6801/LaidtoRest.e2dd57.json b/objects/ChallengeScenarios.9f6801/LaidtoRest.e2dd57.json index 6750e563..11c81061 100644 --- a/objects/ChallengeScenarios.9f6801/LaidtoRest.e2dd57.json +++ b/objects/ChallengeScenarios.9f6801/LaidtoRest.e2dd57.json @@ -4,26 +4,6 @@ "y": 0, "z": 0 }, - "AttachedDecals": [ - { - "CustomDecal": { - "ImageURL": "http://cloud-3.steamusercontent.com/ugc/959719855119695911/931B9829687A20F4DEADB36DA57B7E6D76792231/", - "Name": "dunwich_back", - "Size": 7.4 - }, - "Transform": { - "posX": 0, - "posY": 0, - "posZ": 0, - "rotX": 270, - "rotY": 0, - "rotZ": 0, - "scaleX": 2, - "scaleY": 2, - "scaleZ": 2 - } - } - ], "Autoraise": true, "ColorDiffuse": { "a": 0.27451, diff --git a/objects/ChallengeScenarios.9f6801/ReadorDie.9e73fa.json b/objects/ChallengeScenarios.9f6801/ReadorDie.9e73fa.json index 2acce7c1..cf505bd6 100644 --- a/objects/ChallengeScenarios.9f6801/ReadorDie.9e73fa.json +++ b/objects/ChallengeScenarios.9f6801/ReadorDie.9e73fa.json @@ -4,26 +4,6 @@ "y": 0, "z": 0 }, - "AttachedDecals": [ - { - "CustomDecal": { - "ImageURL": "http://cloud-3.steamusercontent.com/ugc/959719855119695911/931B9829687A20F4DEADB36DA57B7E6D76792231/", - "Name": "dunwich_back", - "Size": 7.4 - }, - "Transform": { - "posX": -0.0021877822, - "posY": -0.08963572, - "posZ": -0.00288731651, - "rotX": 270, - "rotY": 359.869568, - "rotZ": 0, - "scaleX": 2.00000215, - "scaleY": 2.00000238, - "scaleZ": 2.00000262 - } - } - ], "Autoraise": true, "ColorDiffuse": { "a": 0.27451, diff --git a/objects/ChallengeScenarios.9f6801/RedTideRising.5302f2.json b/objects/ChallengeScenarios.9f6801/RedTideRising.5302f2.json index 85fdb993..8f61343e 100644 --- a/objects/ChallengeScenarios.9f6801/RedTideRising.5302f2.json +++ b/objects/ChallengeScenarios.9f6801/RedTideRising.5302f2.json @@ -4,26 +4,6 @@ "y": 0, "z": 0 }, - "AttachedDecals": [ - { - "CustomDecal": { - "ImageURL": "http://cloud-3.steamusercontent.com/ugc/959719855119695911/931B9829687A20F4DEADB36DA57B7E6D76792231/", - "Name": "dunwich_back", - "Size": 7.4 - }, - "Transform": { - "posX": -0.0021877822, - "posY": -0.08963572, - "posZ": -0.00288731651, - "rotX": 270, - "rotY": 359.869568, - "rotZ": 0, - "scaleX": 2.00000215, - "scaleY": 2.00000238, - "scaleZ": 2.00000262 - } - } - ], "Autoraise": true, "ColorDiffuse": { "a": 0.27451, diff --git a/objects/ChallengeScenarios.9f6801/RelicsofthePast.0d6da1.json b/objects/ChallengeScenarios.9f6801/RelicsofthePast.0d6da1.json index 91794ecb..74405cdf 100644 --- a/objects/ChallengeScenarios.9f6801/RelicsofthePast.0d6da1.json +++ b/objects/ChallengeScenarios.9f6801/RelicsofthePast.0d6da1.json @@ -4,26 +4,6 @@ "y": 0, "z": 0 }, - "AttachedDecals": [ - { - "CustomDecal": { - "ImageURL": "http://cloud-3.steamusercontent.com/ugc/959719855119695911/931B9829687A20F4DEADB36DA57B7E6D76792231/", - "Name": "dunwich_back", - "Size": 7.4 - }, - "Transform": { - "posX": -0.0021877822, - "posY": -0.08963572, - "posZ": -0.00288731651, - "rotX": 270, - "rotY": 359.869568, - "rotZ": 0, - "scaleX": 2.00000215, - "scaleY": 2.00000238, - "scaleZ": 2.00000262 - } - } - ], "Autoraise": true, "ColorDiffuse": { "a": 0.27451, diff --git a/objects/EdgeoftheEarth.895eaa.json b/objects/EdgeoftheEarth.895eaa.json index 70cb19c7..d3c661e0 100644 --- a/objects/EdgeoftheEarth.895eaa.json +++ b/objects/EdgeoftheEarth.895eaa.json @@ -13,7 +13,7 @@ }, "CustomMesh": { "CastShadows": true, - "ColliderURL": "https://raw.githubusercontent.com/RobMayer/TTSLibrary/master/advboxes/core_h_COL.obj", + "ColliderURL": "", "Convex": true, "CustomShader": { "FresnelStrength": 0, diff --git a/objects/EncounterSets.304ffc.json b/objects/EncounterSets.304ffc.json index 9e9b8af4..e8f10fb6 100644 --- a/objects/EncounterSets.304ffc.json +++ b/objects/EncounterSets.304ffc.json @@ -17,12 +17,12 @@ "CustomShader": { "FresnelStrength": 0.1, "SpecularColor": { - "b": 0.745098054, + "b": 0.7450981, "g": 0.8117647, "r": 0.8745098 }, "SpecularIntensity": 0.05, - "SpecularSharpness": 3.60000014 + "SpecularSharpness": 3.6 }, "DiffuseURL": "http://cloud-3.steamusercontent.com/ugc/863978359495062918/777CFB72754EC943DF113C1EC1CA495B07FCB6C1/", "MaterialIndex": 1, @@ -50,9 +50,9 @@ "Sticky": false, "Tooltip": true, "Transform": { - "posX": -66.409, + "posX": -66.41, "posY": 1.863, - "posZ": -84.545, + "posZ": -84.55, "rotX": 90, "rotY": 151, "rotZ": 0, diff --git a/objects/ReturntoTheCircleUndone.757324.json b/objects/ReturntoTheCircleUndone.757324.json index 92a42b46..d4b66b07 100644 --- a/objects/ReturntoTheCircleUndone.757324.json +++ b/objects/ReturntoTheCircleUndone.757324.json @@ -6,9 +6,9 @@ }, "Autoraise": true, "ColorDiffuse": { - "a": 0.27451, + "a": 0.27, "b": 1, - "g": 0.99608, + "g": 1, "r": 1 }, "CustomMesh": { diff --git a/objects/ReturntoTheDunwichLegacy.ce9130.json b/objects/ReturntoTheDunwichLegacy.ce9130.json index 9cc75276..a0d4d5f9 100644 --- a/objects/ReturntoTheDunwichLegacy.ce9130.json +++ b/objects/ReturntoTheDunwichLegacy.ce9130.json @@ -6,9 +6,9 @@ }, "Autoraise": true, "ColorDiffuse": { - "a": 0.27451, + "a": 0.27, "b": 1, - "g": 0.99608, + "g": 1, "r": 1 }, "CustomMesh": { diff --git a/objects/ReturntoTheForgottenAge.479ff3.json b/objects/ReturntoTheForgottenAge.479ff3.json index 51d766e2..2f010020 100644 --- a/objects/ReturntoTheForgottenAge.479ff3.json +++ b/objects/ReturntoTheForgottenAge.479ff3.json @@ -6,9 +6,9 @@ }, "Autoraise": true, "ColorDiffuse": { - "a": 0.27451, + "a": 0.27, "b": 1, - "g": 0.99608, + "g": 1, "r": 1 }, "CustomMesh": { diff --git a/objects/ReturntoThePathtoCarcosa.e9889a.json b/objects/ReturntoThePathtoCarcosa.e9889a.json index a8f770d8..e7ccf238 100644 --- a/objects/ReturntoThePathtoCarcosa.e9889a.json +++ b/objects/ReturntoThePathtoCarcosa.e9889a.json @@ -6,9 +6,9 @@ }, "Autoraise": true, "ColorDiffuse": { - "a": 0.27059, + "a": 0.27, "b": 1, - "g": 0.99608, + "g": 1, "r": 1 }, "CustomMesh": { diff --git a/objects/ReturntotheNightoftheZealot.56270d.json b/objects/ReturntotheNightoftheZealot.56270d.json index 145e7fa7..0825d2d0 100644 --- a/objects/ReturntotheNightoftheZealot.56270d.json +++ b/objects/ReturntotheNightoftheZealot.56270d.json @@ -6,9 +6,9 @@ }, "Autoraise": true, "ColorDiffuse": { - "a": 0.27451, + "a": 0.27, "b": 1, - "g": 0.99608, + "g": 1, "r": 1 }, "CustomMesh": { diff --git a/objects/StandaloneScenarios.77a5f9/CarnevaleofHorrors.23dd51.json b/objects/StandaloneScenarios.77a5f9/CarnevaleofHorrors.23dd51.json index 90d95a57..ff0162f3 100644 --- a/objects/StandaloneScenarios.77a5f9/CarnevaleofHorrors.23dd51.json +++ b/objects/StandaloneScenarios.77a5f9/CarnevaleofHorrors.23dd51.json @@ -4,26 +4,6 @@ "y": 0, "z": 0 }, - "AttachedDecals": [ - { - "CustomDecal": { - "ImageURL": "http://cloud-3.steamusercontent.com/ugc/959719855119695911/931B9829687A20F4DEADB36DA57B7E6D76792231/", - "Name": "dunwich_back", - "Size": 7.4 - }, - "Transform": { - "posX": -0.0021877822, - "posY": -0.08963572, - "posZ": -0.00288731651, - "rotX": 270, - "rotY": 359.869568, - "rotZ": 0, - "scaleX": 2.00000215, - "scaleY": 2.00000238, - "scaleZ": 2.00000262 - } - } - ], "Autoraise": true, "ColorDiffuse": { "a": 0.27451, diff --git a/objects/StandaloneScenarios.77a5f9/CurseoftheRougarou.db7039.json b/objects/StandaloneScenarios.77a5f9/CurseoftheRougarou.db7039.json index 7d5aba40..3216fd5b 100644 --- a/objects/StandaloneScenarios.77a5f9/CurseoftheRougarou.db7039.json +++ b/objects/StandaloneScenarios.77a5f9/CurseoftheRougarou.db7039.json @@ -4,26 +4,6 @@ "y": 0, "z": 0 }, - "AttachedDecals": [ - { - "CustomDecal": { - "ImageURL": "http://cloud-3.steamusercontent.com/ugc/959719855119695911/931B9829687A20F4DEADB36DA57B7E6D76792231/", - "Name": "dunwich_back", - "Size": 7.4 - }, - "Transform": { - "posX": -0.0021877822, - "posY": -0.08963572, - "posZ": -0.00288731651, - "rotX": 270, - "rotY": 359.869568, - "rotZ": 0, - "scaleX": 2.00000215, - "scaleY": 2.00000238, - "scaleZ": 2.00000262 - } - } - ], "Autoraise": true, "ColorDiffuse": { "a": 0.27451, diff --git a/objects/StandaloneScenarios.77a5f9/FortuneandFolly.0dce91.json b/objects/StandaloneScenarios.77a5f9/FortuneandFolly.0dce91.json index 632be886..69f01f68 100644 --- a/objects/StandaloneScenarios.77a5f9/FortuneandFolly.0dce91.json +++ b/objects/StandaloneScenarios.77a5f9/FortuneandFolly.0dce91.json @@ -4,26 +4,6 @@ "y": 0, "z": 0 }, - "AttachedDecals": [ - { - "CustomDecal": { - "ImageURL": "http://cloud-3.steamusercontent.com/ugc/959719855119695911/931B9829687A20F4DEADB36DA57B7E6D76792231/", - "Name": "dunwich_back", - "Size": 7.4 - }, - "Transform": { - "posX": -0.0021877822, - "posY": -0.08963572, - "posZ": -0.00288731651, - "rotX": 270, - "rotY": 359.869568, - "rotZ": 0, - "scaleX": 2.00000215, - "scaleY": 2.00000238, - "scaleZ": 2.00000262 - } - } - ], "Autoraise": true, "ColorDiffuse": { "a": 0.27451, diff --git a/objects/StandaloneScenarios.77a5f9/GuardiansoftheAbyss.ee987d.json b/objects/StandaloneScenarios.77a5f9/GuardiansoftheAbyss.ee987d.json index 3a47cf32..2c177fe5 100644 --- a/objects/StandaloneScenarios.77a5f9/GuardiansoftheAbyss.ee987d.json +++ b/objects/StandaloneScenarios.77a5f9/GuardiansoftheAbyss.ee987d.json @@ -4,26 +4,6 @@ "y": 0, "z": 0 }, - "AttachedDecals": [ - { - "CustomDecal": { - "ImageURL": "http://cloud-3.steamusercontent.com/ugc/959719855119695911/931B9829687A20F4DEADB36DA57B7E6D76792231/", - "Name": "dunwich_back", - "Size": 7.4 - }, - "Transform": { - "posX": -0.0021877822, - "posY": -0.08963572, - "posZ": -0.00288731651, - "rotX": 270, - "rotY": 359.869568, - "rotZ": 0, - "scaleX": 2.00000215, - "scaleY": 2.00000238, - "scaleZ": 2.00000262 - } - } - ], "Autoraise": true, "ColorDiffuse": { "a": 0.27451, diff --git a/objects/StandaloneScenarios.77a5f9/MachinationsThroughTime.3c4f3c.json b/objects/StandaloneScenarios.77a5f9/MachinationsThroughTime.3c4f3c.json index 7f46a8da..6fca73d8 100644 --- a/objects/StandaloneScenarios.77a5f9/MachinationsThroughTime.3c4f3c.json +++ b/objects/StandaloneScenarios.77a5f9/MachinationsThroughTime.3c4f3c.json @@ -4,26 +4,6 @@ "y": 0, "z": 0 }, - "AttachedDecals": [ - { - "CustomDecal": { - "ImageURL": "http://cloud-3.steamusercontent.com/ugc/959719855119695911/931B9829687A20F4DEADB36DA57B7E6D76792231/", - "Name": "dunwich_back", - "Size": 7.4 - }, - "Transform": { - "posX": -0.0021877822, - "posY": -0.08963572, - "posZ": -0.00288731651, - "rotX": 270, - "rotY": 359.869568, - "rotZ": 0, - "scaleX": 2.00000215, - "scaleY": 2.00000238, - "scaleZ": 2.00000262 - } - } - ], "Autoraise": true, "ColorDiffuse": { "a": 0.27451, diff --git a/objects/StandaloneScenarios.77a5f9/MurderattheExcelsiorHotel.01d780.json b/objects/StandaloneScenarios.77a5f9/MurderattheExcelsiorHotel.01d780.json index 902a8f9a..a8331c71 100644 --- a/objects/StandaloneScenarios.77a5f9/MurderattheExcelsiorHotel.01d780.json +++ b/objects/StandaloneScenarios.77a5f9/MurderattheExcelsiorHotel.01d780.json @@ -4,26 +4,6 @@ "y": 0, "z": 0 }, - "AttachedDecals": [ - { - "CustomDecal": { - "ImageURL": "http://cloud-3.steamusercontent.com/ugc/959719855119695911/931B9829687A20F4DEADB36DA57B7E6D76792231/", - "Name": "dunwich_back", - "Size": 7.4 - }, - "Transform": { - "posX": -0.0021877822, - "posY": -0.08963572, - "posZ": -0.00288731651, - "rotX": 270, - "rotY": 359.869568, - "rotZ": 0, - "scaleX": 2.00000215, - "scaleY": 2.00000238, - "scaleZ": 2.00000262 - } - } - ], "Autoraise": true, "ColorDiffuse": { "a": 0.27451, diff --git a/objects/StandaloneScenarios.77a5f9/TheBlobthatAteEverything.4dee5a.json b/objects/StandaloneScenarios.77a5f9/TheBlobthatAteEverything.4dee5a.json index 1f2c15df..776dc213 100644 --- a/objects/StandaloneScenarios.77a5f9/TheBlobthatAteEverything.4dee5a.json +++ b/objects/StandaloneScenarios.77a5f9/TheBlobthatAteEverything.4dee5a.json @@ -4,26 +4,6 @@ "y": 0, "z": 0 }, - "AttachedDecals": [ - { - "CustomDecal": { - "ImageURL": "http://cloud-3.steamusercontent.com/ugc/959719855119695911/931B9829687A20F4DEADB36DA57B7E6D76792231/", - "Name": "dunwich_back", - "Size": 7.4 - }, - "Transform": { - "posX": -0.0021877822, - "posY": -0.08963572, - "posZ": -0.00288731651, - "rotX": 270, - "rotY": 359.869568, - "rotZ": 0, - "scaleX": 2.00000215, - "scaleY": 2.00000238, - "scaleZ": 2.00000262 - } - } - ], "Autoraise": true, "ColorDiffuse": { "a": 0.27451, diff --git a/objects/StandaloneScenarios.77a5f9/TheLabyrinthsofLunacy.4c173f.json b/objects/StandaloneScenarios.77a5f9/TheLabyrinthsofLunacy.4c173f.json index e2c2a511..f7058a5d 100644 --- a/objects/StandaloneScenarios.77a5f9/TheLabyrinthsofLunacy.4c173f.json +++ b/objects/StandaloneScenarios.77a5f9/TheLabyrinthsofLunacy.4c173f.json @@ -4,26 +4,6 @@ "y": 0, "z": 0 }, - "AttachedDecals": [ - { - "CustomDecal": { - "ImageURL": "http://cloud-3.steamusercontent.com/ugc/959719855119695911/931B9829687A20F4DEADB36DA57B7E6D76792231/", - "Name": "dunwich_back", - "Size": 7.4 - }, - "Transform": { - "posX": -0.0021877822, - "posY": -0.08963572, - "posZ": -0.00288731651, - "rotX": 270, - "rotY": 359.869568, - "rotZ": 0, - "scaleX": 2.00000215, - "scaleY": 2.00000238, - "scaleZ": 2.00000262 - } - } - ], "Autoraise": true, "ColorDiffuse": { "a": 0.27451, diff --git a/objects/StandaloneScenarios.77a5f9/TheMeddlingofMeowlathotep.d02940.json b/objects/StandaloneScenarios.77a5f9/TheMeddlingofMeowlathotep.d02940.json index 722aa4c7..25edc9cb 100644 --- a/objects/StandaloneScenarios.77a5f9/TheMeddlingofMeowlathotep.d02940.json +++ b/objects/StandaloneScenarios.77a5f9/TheMeddlingofMeowlathotep.d02940.json @@ -4,26 +4,6 @@ "y": 0, "z": 0 }, - "AttachedDecals": [ - { - "CustomDecal": { - "ImageURL": "http://cloud-3.steamusercontent.com/ugc/959719855119695911/931B9829687A20F4DEADB36DA57B7E6D76792231/", - "Name": "dunwich_back", - "Size": 7.4 - }, - "Transform": { - "posX": 0, - "posY": 0, - "posZ": 0, - "rotX": 270, - "rotY": 0, - "rotZ": 0, - "scaleX": 2, - "scaleY": 2, - "scaleZ": 2 - } - } - ], "Autoraise": true, "ColorDiffuse": { "a": 0.27451, diff --git a/objects/StandaloneScenarios.77a5f9/WaroftheOuterGods.fc7674.json b/objects/StandaloneScenarios.77a5f9/WaroftheOuterGods.fc7674.json index dbdc2852..4066bbcc 100644 --- a/objects/StandaloneScenarios.77a5f9/WaroftheOuterGods.fc7674.json +++ b/objects/StandaloneScenarios.77a5f9/WaroftheOuterGods.fc7674.json @@ -4,26 +4,6 @@ "y": 0, "z": 0 }, - "AttachedDecals": [ - { - "CustomDecal": { - "ImageURL": "http://cloud-3.steamusercontent.com/ugc/959719855119695911/931B9829687A20F4DEADB36DA57B7E6D76792231/", - "Name": "dunwich_back", - "Size": 7.4 - }, - "Transform": { - "posX": -0.0021877822, - "posY": -0.08963572, - "posZ": -0.00288731651, - "rotX": 270, - "rotY": 359.869568, - "rotZ": 0, - "scaleX": 2.00000215, - "scaleY": 2.00000238, - "scaleZ": 2.00000262 - } - } - ], "Autoraise": true, "ColorDiffuse": { "a": 0.27451, diff --git a/objects/TheCircleUndone.63e097.json b/objects/TheCircleUndone.63e097.json index 1790a231..44268cc8 100644 --- a/objects/TheCircleUndone.63e097.json +++ b/objects/TheCircleUndone.63e097.json @@ -13,7 +13,7 @@ }, "CustomMesh": { "CastShadows": true, - "ColliderURL": "https://raw.githubusercontent.com/RobMayer/TTSLibrary/master/advboxes/core_h_COL.obj", + "ColliderURL": "", "Convex": true, "CustomShader": { "FresnelStrength": 0, diff --git a/objects/TheDream-Eaters.a16a1a.json b/objects/TheDream-Eaters.a16a1a.json index acacfa28..39a36f26 100644 --- a/objects/TheDream-Eaters.a16a1a.json +++ b/objects/TheDream-Eaters.a16a1a.json @@ -13,7 +13,7 @@ }, "CustomMesh": { "CastShadows": true, - "ColliderURL": "https://raw.githubusercontent.com/RobMayer/TTSLibrary/master/advboxes/core_h_COL.obj", + "ColliderURL": "", "Convex": true, "CustomShader": { "FresnelStrength": 0, diff --git a/objects/TheFeastofHemlockVale.c740af.json b/objects/TheFeastofHemlockVale.c740af.json index 4783385c..9e271dbd 100644 --- a/objects/TheFeastofHemlockVale.c740af.json +++ b/objects/TheFeastofHemlockVale.c740af.json @@ -13,7 +13,7 @@ }, "CustomMesh": { "CastShadows": true, - "ColliderURL": "https://raw.githubusercontent.com/RobMayer/TTSLibrary/master/advboxes/core_h_COL.obj", + "ColliderURL": "", "Convex": true, "CustomShader": { "FresnelStrength": 0, diff --git a/objects/TheForgottenAge.0bcf19.json b/objects/TheForgottenAge.0bcf19.json index 4258bd4e..29985c6a 100644 --- a/objects/TheForgottenAge.0bcf19.json +++ b/objects/TheForgottenAge.0bcf19.json @@ -13,7 +13,7 @@ }, "CustomMesh": { "CastShadows": true, - "ColliderURL": "https://raw.githubusercontent.com/RobMayer/TTSLibrary/master/advboxes/core_h_COL.obj", + "ColliderURL": "", "Convex": true, "CustomShader": { "FresnelStrength": 0, diff --git a/objects/TheInnsmouthConspiracy.465aab.json b/objects/TheInnsmouthConspiracy.465aab.json index 0f34218f..6b3dda2f 100644 --- a/objects/TheInnsmouthConspiracy.465aab.json +++ b/objects/TheInnsmouthConspiracy.465aab.json @@ -13,7 +13,7 @@ }, "CustomMesh": { "CastShadows": true, - "ColliderURL": "https://raw.githubusercontent.com/RobMayer/TTSLibrary/master/advboxes/core_h_COL.obj", + "ColliderURL": "", "Convex": true, "CustomShader": { "FresnelStrength": 0, diff --git a/objects/TheScarletKeys.300fcc.json b/objects/TheScarletKeys.300fcc.json index c2ffe6f5..53c6d4c8 100644 --- a/objects/TheScarletKeys.300fcc.json +++ b/objects/TheScarletKeys.300fcc.json @@ -13,7 +13,7 @@ }, "CustomMesh": { "CastShadows": true, - "ColliderURL": "https://raw.githubusercontent.com/RobMayer/TTSLibrary/master/advboxes/core_h_COL.obj", + "ColliderURL": "", "Convex": true, "CustomShader": { "FresnelStrength": 0, diff --git a/src/core/DownloadBox.ttslua b/src/core/DownloadBox.ttslua index 21957367..a0c3c742 100644 --- a/src/core/DownloadBox.ttslua +++ b/src/core/DownloadBox.ttslua @@ -1,41 +1,35 @@ function onLoad() - local notes = self.getGMNotes() + -- make sure the model is loaded so that we can use the bounds + Wait.condition(buttonCreation, function() return not self.loading_custom end) +end - -- default parameters (e.g. scenarios) - local buttonParameters = { +-- dynamic download button position based on model +function buttonCreation() + local scale = self.getScale() + local bounds = self.getBoundsNormalized() + + self.createButton({ label = "Download", click_function = "buttonClick_download", function_owner = self, - position = { x = 0, y = 0.1, z = 2.1 }, - height = 250, - width = 800, - font_size = 150, + position = { + x = 0, + y = -(bounds.size.y / 2 + bounds.offset.y) / scale.y + 0.5, + z = (bounds.size.z / 2 + 1.2) / scale.z + }, + height = 700, + width = 2300, + font_size = 430, color = { 0, 0, 0 }, - font_color = { 1, 1, 1 } - } - - -- return to boxes - if string.match(notes, "................") == "campaigns/return" then - buttonParameters.position.z = 2 - - -- official campaign boxes - elseif string.match(notes, ".........") == "campaigns" or self.hasTag("LargeBox") then - buttonParameters.position.z = 6 - buttonParameters.height = 500 - buttonParameters.width = 1700 - buttonParameters.font_size = 350 - - -- investigator boxes - elseif string.match(notes, ".............") == "investigators" then - buttonParameters.position.z = 7 - buttonParameters.height = 850 - buttonParameters.width = 3400 - buttonParameters.font_size = 700 - end - - self.createButton(buttonParameters) + font_color = { 1, 1, 1 }, + scale = { 1 / scale.x, 1, 1 / scale.z } + }) end function buttonClick_download(_, playerColor) - Global.call('placeholder_download', { url = self.getGMNotes(), player = playerColor and Player[playerColor] or nil, replace = self.guid }) + Global.call('placeholder_download', { + url = self.getGMNotes(), + player = playerColor and Player[playerColor] or nil, + replace = self.guid + }) end