/TwineHacker

Chrome\Firefox dev-tools extension: How To Debug(Or Cheat) Twine{SugarCube} Variables

Primary LanguageJavaScript

TwineHacker

To Debug(Or Cheat) Twine{SugarCube} Variables

based on extension from this f95 thread

(thanks to @spectr3.9911)

compatible with Chrome and Firefox

Installation instructions

  • Chrome: download repository and use Developer Mode then point directory
  • Firefox: use Firefox Developer Edition, upload as Temporary Extension and point TwineHacker.zip more later...

Rewrite

Extension is completely rewritten, these are changes:

  • F12 - Extension has its own dev tools panel
  • It's always open instead of being initially collapsed, so you might get scrolling (I hate this bug with not fully expandable panels and no possibility even to scroll)
  • No keys to activate. If TwH has detected the game, it will show panel, otherwise empty.
  • It's easy to add support to other engines (Wikifier etc)

TODO

  • support more games and game engines
    • (if i figure it out though)
  • improve speed and stability
    • find out cheap(!) new variables detection
    • fix extension death on a large amount of variables
  • variable freeze feature
    • (anyone does need it? those games are not action games)
  • section collapse improve
    • (yeah minimize scrolling would be great, just think where there controls could be place in just plain <table>)
    • we do have it now, great. or very bad.
  • support other browsers than Chrome and Firefox
    • (but aren't they all Chromium-based?)

Latest changes

  • 01.07.2021 14:00 - hanging issues fixed (less computations, less cycles)
  • 01.07.2021 23:00 - separate options page (in case if it still hangs) (so storage permissions are required)
  • 02.07.2021 18:00 - black style, detection message
  • 07.07.2021 00:00 - small fixes & changes, reorganized code
  • 08.07.2021 00:00 - bugfix: checkbox initially not checked
  • 09.07.2021 20:00 - bugfix: "changed" highlight fix
  • 12.07.2021 13:00 - bugfix: "changed" highlight fix regression
  • 18.07.2021 14:00 - alphabetical sorting
  • 18.07.2021 23:00 - filter feature
  • 04.08.2021 22:00 - filter highlighting feature
  • 04.08.2021 23:00 - separate field for highlighting feature
  • 04.08.2021 23:00 - highlighting also found values (still not ideal)
  • 08.08.2021 22:00 - minor fix title issue
  • 18.08.2021 21:00 - section collapsing by label click (still looks ugly)
  • 25.10.2021 16:00 - experimental value lock
  • 28.07.2022 17:00 - v3 manifest, error alert fix
  • 29.07.2022 20:00 - collapse all, expand all feature

List of tested games

  • Inheritance
  • Free Cities
  • An Unexpected New Life
  • The Ooze Wizard Apprentice
  • Event Girl
  • Favourite Teacher
  • Girl Crush
  • Paths
  • Repurposing Center
  • Degrees of Lewdity
  • The Company
  • Desideratum Blood Bonds
  • Female agent
  • College Daze
  • Degrees of Lewdity
    • (etc not mentioned here)
Spoiler Screenshots:
  1. download it here: https://github.com/lure0xaos/TwineHacker

    1.1. click "Code" button, then "Download ZIP", and unzip it Безымянный0

  2. How to install:

    2.1. Make sure "Developer mode" is on 2.2. Click "Load unpacked" and choose directory where you've downloaded it (where manifest.json is among other files) Безымянный png 2.3. So you should see it's loaded without errors: Безымянный2

  3. Open your game and press F12 to open Developer Tools sidebar, then switch to TwineHacker tab: Безымянный3

Now you can change any ingame value