### Development Server Setup Source: https://github.com/multitheftauto/wiki.multitheftauto.com/blob/main/_autodocs/README.md Commands to install dependencies and start the development server for the web project. ```bash cd web npm install npm run dev # Server at http://localhost:3000 ``` -------------------------------- ### Preprocessing Phase Example Source: https://github.com/multitheftauto/wiki.multitheftauto.com/blob/main/_autodocs/content-structure.md The `web/scripts/preprocess.js` script copies assets and generates Lua syntax highlighting before the build starts. ```bash assets/ → copies to → web/src/assets/ ``` -------------------------------- ### Install Dependencies Source: https://github.com/multitheftauto/wiki.multitheftauto.com/blob/main/web/README.md Installs all necessary project dependencies. Run this command after cloning the repository or when updating dependencies. ```bash npm install ``` -------------------------------- ### Start Local Development Server Source: https://github.com/multitheftauto/wiki.multitheftauto.com/blob/main/web/README.md Starts a local development server for real-time previewing of changes. The server typically runs at `localhost:4321`. ```bash npm run dev ``` -------------------------------- ### Install Dependencies Source: https://github.com/multitheftauto/wiki.multitheftauto.com/blob/main/migrate/oldwiki/README.md Install the required Python packages using pip. ```bash pip install -r requirements.txt ``` -------------------------------- ### Referencing Code Examples from Repository Source: https://github.com/multitheftauto/wiki.multitheftauto.com/blob/main/_autodocs/content-structure.md Code examples are managed as separate files within the repository, referenced by path and description. ```yaml examples: - path: "examples/createBlip-1.lua" description: "Create a red blip" side: "server" ``` -------------------------------- ### Download and Install msvc-wine Components Source: https://github.com/multitheftauto/wiki.multitheftauto.com/blob/main/web/src/content/docs/articles/wine-build.mdx Download and install the default packages and MFC for msvc-wine. Use the --dest option to specify the installation directory and --accept-license to bypass the license prompt. ```shell ./vsdownload.py --dest /path/to/msvc-wine-install-dir/ --accept-license ./vsdownload.py --dest /path/to/msvc-wine-install-dir/ --accept-license Microsoft.VisualStudio.Component.VC.ATLMFC ./install.sh /path/to/msvc-wine-install-dir/ ``` -------------------------------- ### Meta.xml Configuration for Resource Browser Example Source: https://github.com/multitheftauto/wiki.multitheftauto.com/blob/main/web/src/pages/reference/Resource_Web_Access.mdx Example meta.xml configuration including AJAX resource, script, default HTML, and an exported HTTP function. ```xml ``` -------------------------------- ### YAML Schema for Collection Item Metadata Source: https://github.com/multitheftauto/wiki.multitheftauto.com/blob/main/_autodocs/content-structure.md Example of YAML metadata for associating functions with specific element types and constructors. ```yaml server: name: "createPlayer" oop: element: "player" constructorclass: "Player" ``` -------------------------------- ### Get Asset Audio Path Source: https://github.com/multitheftauto/wiki.multitheftauto.com/blob/main/_autodocs/api-reference/general-utilities.md Asynchronously retrieves an audio asset from the bundled assets. Supports MP3, OGG, and WAV formats. Must be awaited. ```typescript import { getAssetAudioPath } from '@src/utils/general'; const audioUrl = await getAssetAudioPath('sound.mp3'); // Use audioUrl in