Forum Discussion
11 years ago
Update my script posted in the ModTheSims thread probably for last time as game is close to release. I've been able to use it fairly well with a properly configured Intellij for browsing the source. I suspect that is enough for most modders to get by for a while. Surprisingly only had to create about a dozen stubs that are probably the C++ classes in the engine to load the code in python which means that they skewed toward a lot of the source in python files rather than just exposing wrappers which is likely good for modders.
Regarding time estimates, I only expect someone to give a reasonably accurate estimate if its an activity they have done before. Too often I'm asked to estimate something like "How long will it take to create a dashboard for tracking convoluted company metric x?" but without any of the useful stuff like what visualization tool do you want it in and where is the data and what is x anyway?
Edit: Doesn't seem like the most popular thread but some findings on the hot reloader (maybe this should be its own thread). Looks like it will not be enabled by default event if __debug__ is True as we are loading from zip files which sets SCRIPT_ROOT to None where that variable controls the root folder for reloading. I suspect some monkey patchable may be sufficient to troubleshoot stuff in the future but not out of the box. Some interesting files for those that are interested: core.zip\paths.py, core.zip\sims4\core_services.py, core.zip\sims4\core_services.py. Looks like user script mods will load from either zip or as loose py files though only the later are reloadable.
I actually cannot determine how user scripts are loaded at the moment as it looks like it uses USER_SCRIPT_ROOTS which currently is pointed squarely at core.zip. Some other zip files that are of interest are the tests.zip, debug.zip, lib.zip, build.zip which might be usable to bootstrap loading custom scripts since they do not exist in the deployed game. Hopefully I'm just overlooking something obvious but looks like they expect either all source files or all zip files and not a mixture. That might be reasonable for the developers but my not be so good for us. I'm sure that they will help out when we starting hitting these blocks.
Regarding time estimates, I only expect someone to give a reasonably accurate estimate if its an activity they have done before. Too often I'm asked to estimate something like "How long will it take to create a dashboard for tracking convoluted company metric x?" but without any of the useful stuff like what visualization tool do you want it in and where is the data and what is x anyway?
Edit: Doesn't seem like the most popular thread but some findings on the hot reloader (maybe this should be its own thread). Looks like it will not be enabled by default event if __debug__ is True as we are loading from zip files which sets SCRIPT_ROOT to None where that variable controls the root folder for reloading. I suspect some monkey patchable may be sufficient to troubleshoot stuff in the future but not out of the box. Some interesting files for those that are interested: core.zip\paths.py, core.zip\sims4\core_services.py, core.zip\sims4\core_services.py. Looks like user script mods will load from either zip or as loose py files though only the later are reloadable.
I actually cannot determine how user scripts are loaded at the moment as it looks like it uses USER_SCRIPT_ROOTS which currently is pointed squarely at core.zip. Some other zip files that are of interest are the tests.zip, debug.zip, lib.zip, build.zip which might be usable to bootstrap loading custom scripts since they do not exist in the deployed game. Hopefully I'm just overlooking something obvious but looks like they expect either all source files or all zip files and not a mixture. That might be reasonable for the developers but my not be so good for us. I'm sure that they will help out when we starting hitting these blocks.
About The Sims 4 Mods & Custom Content
Find expert tips, troubleshooting help, tutorials for mods and custom content, and The Sims 4 patch files in our forum.
4,843 PostsLatest Activity: 4 months agoRelated Posts
Recent Discussions
- 9 hours ago
- 2 days ago