Tabletop Simulator

Tabletop Simulator

Not enough ratings
Disinfector Table
   
Award
Favorite
Favorited
Unfavorite
File Size
Posted
Updated
8.234 KB
20 Apr, 2023 @ 12:33pm
20 Apr, 2023 @ 12:40pm
2 Change Notes ( view )

Subscribe to download
Disinfector Table

Description
You're probably here because you tried loading in your cards/decks onto Pie's MTG tables, and the table yelled at you that your stuff is infected and did not let you spawn anything. This table attempts to disinfect those objects. Instructions are on the bottom right of the screen when you load the table.

  • I highly recommend that you just reimport your decks - you could load in the Deck Lister (from my mtg tables) onto an empty table if you need help getting your card lists

  • If, for whatever reason, you don't want to do that - then I highly recommend you try and fix your files using the manual text-editor fix ( described below ↓ )

  • Seriously, the fix at this table is clunky - the virus tends to overwhelm the disinfecting script... but you can certainly try it at your own discretion




Why is this happening?
Someone made a malicious script attached to an object that, when loaded into TTS, imprints itself on ALL other objects at a table. Those objects end up carrying and spreading the malicious script. Unknowingly, folks end up saving infected cards/decks and then spawning them in other games with other people - spreading the virus further.

I'll repeat, if a *single* infected object is present at a table - *everything* gets infected:
  • You spawned *all* your decks on a test table in single player, moved around some cards, and then saved them? If a single deck or card was infected - they're all infected now.
  • You spread out your deck into individual cards and then put it back together and saved that? Now the deck object itself is infected, but ALSO each individual card within it is infected as well. It's infection-inception.

Anyhow - the thing sucks. I cannot allow this virus to run rampant at my tables and I put in special measures to prevent that.



Manual, text-editor fix, outside of TTS

You'll need to use Notepad++ or a similar text editor.

  1. go to an empty TTS table (not the MTG table, just the empty default TTS table) and load in all the items you wish to disinfect
  2. select ALL of them and save them as one object (or you can toss them into some container and save the container)
  3. go to the folder on your PC where TTS stores its saved objects (/Documents/My Games/Tabletop Simulator/Saves/Saved Objects/ on Windows 10 by default)
  4. locate the .json file of the saved object that contains all the infected objects, right click and open it with a text editor
  5. press ctrl+F (or whatever shortcut to search the file) and search for "LuaScript":
  6. you're looking for a line that looks like THIS
  7. select the entire malicious script inside the quotes (including all the spaces at the beginning) and delete it
  8. Make surer you're left with:
    "LuaScript": "",
    if the structure of the line is messed up (need the quotes, need the comma) - the file wont work when loading back into TTS.
  9. Repeat steps 5-8 for all the "LuaScript" lines - OR - at least in Notepad++ you can put in the malicious code as the line to search for, and do a Replace All to get rid of all of them simultaneously
  10. Save the text file - go back to TTS and load your bundle of objects back in. These are clean now.





Someone else made a portable version to fight the same virus: Cleaner Block by Rheza.
It won't work at my MTG tables though (I blocked the ability of any script to modify other items). You're welcome to load it onto an empty table and see if it works better than what I tried to do here.
8 Comments
Oops I Baked a Pie  [author] 30 Apr, 2023 @ 2:08pm 
That could overwhelm the disinfector. If too many items are spawned at the same time - the cleaner script might not run fast enough to prevent the malicious script from running. Honestly, the manual "edit the json" instructions are the safest way to go.
Hungry Woof 30 Apr, 2023 @ 2:01pm 
Thanks. Table works good. I recomend use "Spred" function if you cleaning your deck, otherwise cards from pile will be deleted on the main mtg table after seccessfull loading a pile itself
Adil3tr 26 Apr, 2023 @ 5:56pm 
Okay cool, I think I'm clean? I checked a hundred of the objects within the mod json and they seem to be clean.
Oops I Baked a Pie  [author] 26 Apr, 2023 @ 9:17am 
if ANY item in that room is infected - then ALL items are infected - that's how the virus works and why I had to prevent it from spawning at all on my main tables - its script auto-appends itself to all other objects (which then also auto-append the virus script to any new objects)

I recommend getting notepad++ and opening the .json save file of the room with all the items in it and editing the LuaScript lines using Replace All
Adil3tr 26 Apr, 2023 @ 5:44am 
I mean I have a room of hundreds of objects, is the only way to check them to copy them all and try and spawn them in the MTG room? Do you have a link to that room that deletes bad objects?
Oops I Baked a Pie  [author] 25 Apr, 2023 @ 9:11pm 
If you see a "cleaning..." message - that means your object was infected
Adil3tr 25 Apr, 2023 @ 5:23pm 
Is there an object I can spawn in a room and see what objects it deletes?
Rachel Wulf 21 Apr, 2023 @ 10:51am 
just a note, you didn't delete the default hand zones, and i've noticed I'm a little bit more likely to get 'The infection got out' when i don't delete the hand zones before i start cleaning stuff.

either way though, thank you for your efforts.