MTS has all free content, all the time. Find out how YOU can help to keep it running. Tell me how...

[Script Mod] enable advanced debug/cheat interactions

by clown Posted 13th Sep 2014 at 8:19 PM - Updated 13th Sep 2014 at 11:53 PM by leefish
858 Comments / replies (Who?) - 11 Feedback Posts, 14 Thanks Posts
Picked Upload! This is a picked upload! It showcases some of the best talent and creativity available on MTS and in the community.
This mod is a small script that patches a function in the maxis game code to enable additional debug cheats. It also always enable cheats without needing to use the testingcheats command.
The python source is included as it provides an example of how to replace methods and functions in the maxis code.
I do not guarantee that the mod won't break with future updates of the game or that I'll be able to be arsed to fix it. But hey, you have the source :p

Unlike the original less than subtle method of modifying python33.dll to force the __debug__ variable to true, this one doesn't seem to be suffering from any game breaking side effect (at least it didn't during my extremely thorough 20 seconds test of getting a sim to fish and then successfully cancelling it).

Installation: put the zip file in your Mods directory. The zip also contains the .py source.
Make sure that script mods are enabled in game options.

Update: Now doesn't require to use the testingcheats console command.

Below is the original post describing the original less than satisfactory python dll editing method, in case someone is interested for some reason:



So I was looking into the decompiled python code and I noticed that a lot of interesting things are enabled when the global __debug__ variable is set to true.

It turns out that it is a builtin python variable normally set by python when run in non-optimized mode. Sims 4 helpfully ships python as a separate DLL from the main binary, so we can easily do some good ole hex editing of the code in that dll to force this variable to be set.

Steps:
1. Get HxD (http://mh-nexus.de/en/hxd/).
1. Locate your sims 4 directory, which should be something something Origin Games/The Sims 4
2. Go into the Game/Bin directory.
3. Make a backup copy of Python33.dll
4. Launch HxD
5. Drag and drop Python33.dll into HxD
6. Press ctrl+f to bring up the search dialog
7. In "datatypes", select "hex-values"
8. In "search for", enter "0f45fd57"
9. The four bytes "0F 45 FD 57" will be highlighted. Click on the "45".
10. type "44", so that those bytes now read "0F 44 FD 57"
11. Save

Restart the game.

In the game a bunch of new debug interactions should now be available by shift clicking on sims, objects or directly on the lot, allowing to manipulate traits, emotions, spawn sims, break things, start fires etc.
They are always available without having to enter testingcheats true in the console, until you restore the original Python33.dll file.

Doing this is also probably a useful step towards enabling the commands to reload scripts on the fly. There are lots of console commands that are flagged as debug only, but even after doing the above they don't seem to work. This will need more investigation.
Type: Other

You must have the expansion or stuff packs listed below installed to use this custom content. Please see the post text for any exceptions.

Sims 4
Key: - File was updated after upload was posted
Filename - Tip: You can click the magnifying glass to see the archive contents Size Downloads Date
EnableDebugCheats.zip

Size: 2.6 KB · Downloads: 204,960 · 13th Sep 2014
2.6 KB 204,960 13th Sep 2014
Don't forget to Thank the creator after downloading! Use the Thanks button located above the screenshots above.
Basic Download and Install Instructions:
1. Download: Click the File tab to see the download link. Click the link to save the .rar or .zip file(s) to your computer.
Read the upload description for installation instructions. If nothing else is specified, do the following:
2. Extract: Use WinRAR (Windows) to extract the .package file(s) (if included, ts4script as well) from the .rar or .zip file(s).
3. Cut and paste the .package file(s) (if included, ts4script as well) into your Mods folder
  • Windows XP: Documents and Settings\(Current User Account)\My Documents\Electronic Arts\The Sims 4\Mods\
  • Windows Vista/7/8/8.1: Users\(Current User Account)\Documents\Electronic Arts\The Sims 4\Mods\

Need more information?
  • Anyone can use both .rar and .zip files easily! On Windows, use WinRAR.
  • If you don't have a Mods folder, just make one.
  • Mod still not working? Make sure you have script mods enabled
 
858 Comments / Replies (Who?) - 556 Feedback Posts, 268 Thanks Posts
Hide Thanks Posts for this thread (Show only feedback)
Page 3 of 35
Lab Assistant
#51 Old 14th Sep 2014 at 3:43 AM
Quote:
Originally Posted by siuni
absolutely wonderful
Only bug now is that alter needs no longer works. At least for me. Idk for anyone else.


Need work fine for me, but if you want to do the decay needs disabled you need to type testingcheats on first or they will not work.
Test Subject
#52 Old 14th Sep 2014 at 3:58 AM
Quote:
Originally Posted by cyberops
Need work fine for me, but if you want to do the decay needs disabled you need to type testingcheats on first or they will not work.

Oh I see! I just automatically assumed it would be on with the mod from the start. Ahaha.
I'll check in a bit.
Thank you

Edit: yeaah have to still type in testingcheats enabled/true for alter needs to work. Luckily I changed my hotkeys to laziness cheats. Ahaha.
Lab Assistant
#53 Old 14th Sep 2014 at 5:09 AM
Default Scripts checked?
Quote:
Originally Posted by MJudd157
I did everything right, but it's not working... no mods will work in my game for some reason,... help?


Go to your "Game Options" under settings, then got to "other" make sure you have "scripts" checked then click apply changes. Restart game. After that you should be fine. Same thing was happening to me, then I found out I didn't have scripts enabled. Hope this helps.
Test Subject
THANKS POST
#54 Old 14th Sep 2014 at 5:20 AM
ty for the Mod
Lab Assistant
THANKS POST
#55 Old 14th Sep 2014 at 5:37 AM
Sweet MOD! Just wish I could fill motives/needs without still having to type it in. But otherwise works beautifully.
Test Subject
THANKS POST
#56 Old 14th Sep 2014 at 5:55 AM
besides still needing to type testingcheats true at every lot change this was just what I was looking for
Test Subject
THANKS POST
#57 Old 14th Sep 2014 at 6:06 AM
what is raise error and what is debug ?
Test Subject
#58 Old 14th Sep 2014 at 6:09 AM
Quote:
Originally Posted by ralib1
what is raise error and what is debug ?


I was wondering about the same thing.
Top Secret Researcher
THANKS POST
#59 Old 14th Sep 2014 at 6:15 AM
thaaaaaaaaank you!!!!!!
Test Subject
#60 Old 14th Sep 2014 at 8:04 AM
Thanks for this mod. As far as I can see, it works fine, but I have some blank buttons in the menu, cause I don´t have an english game. Is it possible, to add different languages, like german?
Test Subject
#61 Old 14th Sep 2014 at 8:15 AM
I just ran into an issue the Reset Object (Rebug) doesn't work anymore and Transport your Sim is gone too.
Lab Assistant
#62 Old 14th Sep 2014 at 8:19 AM
Quote:
Originally Posted by The Star Treker
I just ran into an issue the Reset Object (Rebug) doesn't work anymore and Transport your Sim is gone too.


I will say it again, make sure to tupe testingcheats on first to enable everyhing
Test Subject
THANKS POST
#63 Old 14th Sep 2014 at 8:32 AM
awesome! i no longer have to swap out the python33.dll
Test Subject
#64 Old 14th Sep 2014 at 9:21 AM
Quote:
Originally Posted by cyberops
I will say it again, make sure to tupe testingcheats on first to enable everyhing


This is weird both cheats didn't work at first but now they're working. I don't know why they didn't earlier. I did type in testingcheats true but they didn't work and somehow now are. Maybe I wasn't clicking on the right specific spot where they can work.
Test Subject
#65 Old 14th Sep 2014 at 9:51 AM
So how can I can make the "cancel action" to work?
Test Subject
THANKS POST
#66 Old 14th Sep 2014 at 9:59 AM
Thank you; I like the mod keep up the good work and keep it up to date
Test Subject
THANKS POST
#67 Old 14th Sep 2014 at 10:32 AM
Thanks, and. There's nothing to work with non-English version ?
I've blank bubble with French version...
Instructor
#68 Old 14th Sep 2014 at 11:01 AM
Thanks for the script.
I have been using my modified pithon33, but the interactions wouldn't end. Now with this one, as soon as I cancel the interaction, It's immediately cancelled.
But as some users have said, for the regular cheat category, (the ones unlocked in the game (Need cheats)) we still need to enter testingcheats true.
The pie menu shows up, but won't apply the cheat if testingcheats true aren't in the console.
Thanks again
Test Subject
THANKS POST
#69 Old 14th Sep 2014 at 11:42 AM
yeaaah!! works fine...
Field Researcher
THANKS POST
#70 Old 14th Sep 2014 at 1:58 PM
awesome
Test Subject
#71 Old 14th Sep 2014 at 2:52 PM Last edited by FFrucht : 14th Sep 2014 at 3:26 PM.
Quote:
Originally Posted by MrXJKz
Thanks, and. There's nothing to work with non-English version ?
I've blank bubble with French version...


Same for me with German. Only white empty bubbles.


Also: since installing the mod, I can't cancel actions from my sims anymore.
Test Subject
THANKS POST
#72 Old 14th Sep 2014 at 3:26 PM
Thanks for sharing.
Test Subject
THANKS POST
#73 Old 14th Sep 2014 at 3:26 PM
doesn`t work :-(
do ihave to enter a cheat before it works?
Test Subject
THANKS POST
#74 Old 14th Sep 2014 at 4:20 PM
Nice work, thank you
Test Subject
THANKS POST
#75 Old 14th Sep 2014 at 4:30 PM
I had to remove the thing, which sucks because the mod itself worked. The problem I had was that once my sim started an action, there was no way to cancel said action. So if it wasn't a short term action they never stopped. It's to bad too. I really loved this mod.
Page 3 of 35