Creation Kit Scripts.zip

1 view
Skip to first unread message

Kanisha Dezarn

unread,
Aug 5, 2024, 5:24:41 AM8/5/24
to tersstanrelef
Heyso I just started writing scripts, right? watched all the tutorials on youtube, wrote a custom object reference enable script, which may or may not work. I don't know, because everytime I load a script in the CK, it says

Okay. Google it. read everything you can find. So I did. I found out that it comes from not having the Base scripts unzipped. but I do. I even reinstalled the CK to have it unzip the base scripts again, and still i get the Script Reload Error. Driving me up a wall here. Can't select references to define properties because the CK won't load the script in the property window.


OP - "I found out that it comes from not having the Base scripts unzipped. but I do. I even reinstalled the CK to have it unzip the base scripts again, and still i get the Script Reload Error."


I had this happen. It's from the Bethesda.Net Launcher only partially installing the files. I think it's caused by some conflict between where Steam wants to put the files and where Beth wants to put them. In this case Beth is correct, but it frequently means the initial install of the CK gets borked. Anyway:


LOL Not long after typing my reply I had the CK suddenly refuse to do anything with scripts. Had to follow my own recommendations, use Beth launcher to scan and repair so that when I started the CK it asked me if I wanted to unzip the Base.zip script sources. Tell it yes, and overwrite.


So, just so we have this all documented, and so Todd can see it- after using the CK to unzip the scripts.zip file, TWICE, I had to manually unzip it to my desktop to find that there were like 4000 scripts that just weren't present in my game directory. Where did CK put them? who knows.


Whose f***ing idea was it to make a game that can run without 50% of its scripts present in the "scripts" folder?! The more I learn about the structure of this engine, the more I despise it. I can open the game, I can play with 500 mods and 0 crashes, but f***in' TRY TO WRITE A 10 LINE SCRIPT AND THE CREATION KIT LIGHTS ON FIRE. Because the game runs fine, it just... it like, uses a different place for the scripts than the thing THAT WE USED TO MAKE IT. 0 sense out of 100.


It might also be a good idea to get familiar with the JavaScript Build Setup tutorial for setting up a development environment to use ESNext syntax. It gives a very in-depth explanation of how to use the build and start scripts.


When using the start or build commands, the source code directory ( the default is ./src) and its subdirectories are scanned for the existence of block.json files. If one or more are found, they are treated a entry points and will be output into corresponding folders in the build directory. This allows for the creation of multiple blocks that use a single build process. The source directory can be customized using the --webpack-src-dir flag and the output directory with the --output-path flag.


The entry points for your project get detected by scanning all script fields in block.json files located in the src directory. The script fields in block.json should pass relative paths to block.json in the same folder.


The fallback entry point is src/index.js (other supported extensions: .jsx, .ts, and .tsx) in case there is no block.json file found. In that scenario, the output generated will be written to build/index.js.


Experimental support for the block.json viewScriptModule field is available via the

--experimental-modules option. With this option enabled, script and module fields will all be

compiled. The viewScriptModule field is analogous to the viewScript field, but will compile a module

and should be registered in WordPress using the Modules API.


Checks if the current node, npm (or yarn) versions match the given semantic version ranges. If the given version is not satisfied, information about installing the needed version is printed and the program exits with an error code.


It uses check-node-version behind the scenes with the recommended configuration provided. The default requirements are set to the same Node.js and npm versions as listed in the installation section for this package. You can specify your own ranges as described in check-node-version docs. Learn more in the Advanced Usage section.


It uses eslint with the set of recommended rules defined in @wordpress/eslint-plugin npm package. You can override default rules with your own as described in eslint docs. Learn more in the Advanced Usage section.


It uses npm-package-json-lint with the set of recommended rules defined in @wordpress/npm-package-json-lint-config npm package. You can override default rules with your own as described in npm-package-json-lint wiki. Learn more in the Advanced Usage section.


It uses markdownlint with the .markdownlint.json configuration. This configuration tunes the linting rules to match WordPress standard, you can override with your own config, see markdownlint-cli for command-line parameters.


When you run commands similar to the npm run lint:css:src example above, be sure to include the quotation marks around file globs. This ensures that you can use the powers of globby (like the ** globstar) regardless of your shell. See more examples.


It uses stylelint with the @wordpress/stylelint-config configuration per the WordPress CSS Coding Standards. You can override them with your own rules as described in stylelint user guide. Learn more in the Advanced Usage section.


The command detects project dependencies that have name starting with @wordpress/ by scanning the package.json file. By default, it executes npm install @wordpress/package1@latest @wordpress/package2@latest ... --save to change the package versions to the latest one. You can chose a different dist-tag than latest by using the --dist-tag option when running the command.


In the case where the plugin author wants to customize the files included in the zip file, they can provide the files field in the package.json file as documented in the npm-packlist package, example:


Puppeteer is a Node library which provides a high-level API to control Chrome or Chromium over the DevTools Protocol. Puppeteer runs headless by default, but can be configured to run full (non-headless) Chrome or Chromium.


When tests fail, both a screenshot and an HTML snapshot will be taken of the page and stored in the artifacts/ directory at the root of your project. These snapshots may help debug failed tests during development or when running tests in a CI environment.


It uses Jest behind the scenes and you are able to use all of its CLI options. You can also run ./node_modules/.bin/wp-scripts test:e2e --help or npm run test:e2e:help (as mentioned above) to view all of the available options. Learn more in the Advanced Usage section.


It uses Jest behind the scenes and you are able to use all of its CLI options. You can also run ./node_modules/.bin/wp-scripts test:unit --help or npm run test:unit:help (as mentioned above) to view all of the available options. By default, it uses the set of recommended options defined in @wordpress/jest-preset-default npm package. You can override them with your own options as described in Jest documentation. Learn more in the Advanced Usage section.


This script automatically detects the best config to start Playwright, but sometimes you may need to specify custom options.

To do so, you can add a file called playwright.config.ts or playwright.config.js in the top-level directory of your package (at the same level as your package.json).


When tests fail, snapshots will be taken of the page and stored in the artifacts/ directory at the root of your project. These snapshots may help debug failed tests during development or when running tests in a CI environment.


Follow the instructions for debugging Node.js with your favorite supported browser or IDE. When the instructions say to use node --inspect script.js or node --inspect-brk script.js, simply use wp-scripts --inspect script or wp-scripts --inspect-brk script instead.


A breakpoint will be set at the first line of the script (this is done to give you time to open the developer tools and to prevent Jest from executing before you have time to do so). Click the resume button in the upper right panel of the dev tools to continue execution. When Jest executes the test that contains the debugger statement, execution will pause and you can examine the current scope and call stack.


The code executed in the node context includes all of the test files excluding code within page.evaluate functions. The page.evaluate functions and the rest of your app code is executed within the browser context.


To also debug the browser context, run wp-scripts --inspect-brk test-e2e --puppeteer-devtools. The --puppeteer-devtools option (or the PUPPETEER_DEVTOOLS="true" environment variable when used with PUPPETEER_HEADLESS="false") will disable headless mode and launch the browser with the devtools already open. Breakpoints can then be set in the browser context using these devtools.

3a8082e126
Reply all
Reply to author
Forward
0 new messages