quake 3 commands | Cell 5 | Cell 7 | Search

The Quake 3 game launch script is a macOS script that utilizes the open command to launch Quake 3 games with various settings and configurations. The script includes common arguments such as setting game paths and enabling cheats, as well as game-specific settings like disabling triangle rendering and binding key commands.

Run example

npm run import -- "https://quake.games/set%20name%20player_name"

https://quake.games/set%20name%20player_name

open -n ./ioquake3-1.36.app --args +set fs_game baseq3 +exec ./client.cfg

open -n /Users/briancullinan/planet_quake/build/release-darwin-x86_64/ioquake3.app --args +set fs_basepath /Applications/ioquake3 +set fs_homepath /Users/briancullinan/.q3a +set fs_restrict 0 +set sv_pure 0 +set sv_cheats 1 +set cheats 1 +set developer 1 +set logfile 1 +set fs_game baseq2vm +map base2-a

open -n /Users/briancullinan/planet_quake/build/release-darwin-x86_64/ioquake3.app --args +set fs_basepath /Applications/ioquake3 +set fs_homepath /Users/briancullinan/.q3a +set fs_restrict 0 +set sv_pure 0 +set sv_cheats 1 +set cheats 1 +set developer 1 +set logfile 1 +set fs_game baseq2vm +set r_showtris 0 +devmap base2-a

open -n ./build/release-darwin-x86_64/ioquake3.app --args +set fs_basepath /Users/briancullinan/.q3a/unpacked +set fs_homepath /Users/briancullinan/.q3a/unpacked +set fs_restrict 0 +set sv_pure 0 +set sv_cheats 1 +set cheats 1 +set developer 1 +set logfile 1 +set fs_game baseq3-combined-converted +devmap "Full stadium 2"


open -n /Users/briancullinan/planet_quake/build/release-darwin-x86_64/ioquake3.app --args +set fs_basepath /Users/briancullinan/.q3a/unpacked +set fs_homepath /Users/briancullinan/.q3a +set fs_restrict 0 +set sv_pure 0 +set sv_cheats 1 +set cheats 1 +set developer 1 +set logfile 1 +set fs_game baseq3-combined-converted


./build/debug-darwin-x86_64/quake3e +set fs_basepath /Applications/ioquake3 +set fs_game baseq3 +set sv_pure 0 +set net_enable 1 +set recentPassword "recentPassword" +set timescale 8 +set developer 1 +set dedicated 0 +bind leftarrow rewind +bind rightarrow forward +demo baseq3_1_map_2_matches

What the code could have been:

bash
#!/bin/bash

# Define function to start ioquake3 with basic settings
start_ioquake3() {
    local fs_game=$1
    local map=$2
    local fs_homepath=$3
    local fs_basepath=$4
    local devmap=$5
    local r_showtris=$6
    local logfile=$7
    local cheats=$8
    local sv_cheats=$9
    local developer=${10}

    local args=(
        "+set fs_game ${fs_game}"
        "+map ${map}"
        "+set fs_homepath ${fs_homepath}"
        "+set fs_basepath ${fs_basepath}"
    )

    if [ -n "${devmap}" ]; then
        args+=("+devmap ${devmap}")
    fi

    if [ -n "${r_showtris}" ] && [ "${r_showtris}"!= "0" ]; then
        args+=("+set r_showtris 1")
    else
        args+=("+set r_showtris 0")
    fi

    if [ -n "${logfile}" ] && [ "${logfile}"!= "0" ]; then
        args+=("+set logfile 1")
    else
        args+=("+set logfile 0")
    fi

    if [ -n "${cheats}" ] && [ "${cheats}"!= "0" ]; then
        args+=("+set cheats 1")
    else
        args+=("+set cheats 0")
    fi

    if [ -n "${sv_cheats}" ] && [ "${sv_cheats}"!= "0" ]; then
        args+=("+set sv_cheats 1")
    else
        args+=("+set sv_cheats 0")
    fi

    if [ -n "${developer}" ] && [ "${developer}"!= "0" ]; then
        args+=("+set developer 1")
    else
        args+=("+set developer 0")
    fi

    # Start ioquake3 with arguments
    open -n "./ioquake3-1.36.app" --args "${args[@]}"
}

# Start ioquake3 with baseq3 game
start_ioquake3 "baseq3" "baseq3-a" "/Users/briancullinan/.q3a" "/Applications/ioquake3" "" "0" "0" "0" "0"

# Start ioquake3 with baseq2vm game
start_ioquake3 "baseq2vm" "base2-a" "/Users/briancullinan/.q3a" "/Applications/ioquake3" "" "0" "1" "1" "1"

# Start ioquake3 with baseq3-combined-converted game
start_ioquake3 "baseq3-combined-converted" "baseq3-map-1" "/Users/briancullinan/.q3a/unpacked" "/Users/briancullinan/.q3a/unpacked" "Full stadium 2" "0" "1" "1" "1"

# Start ioquake3 with baseq3-combined-converted game (no r_showtris)
start_ioquake3 "baseq3-combined-converted" "baseq3-map-1" "/Users/briancullinan/.q3a/unpacked" "/Users/briancullinan/.q3a/unpacked"

# Start quake3e with specific settings
./build/debug-darwin-x86_64/quake3e "+set fs_basepath /Applications/ioquake3" "+set fs_game baseq3" "+set sv_pure 0" "+set net_enable 1" "+set recentPassword'recentPassword'" "+set timescale 8" "+set developer 1" "+set dedicated 0" "+bind leftarrow rewind" "+bind rightarrow forward" "+demo baseq3_1_map_2_matches"

Breakdown of Quake 3 Game Launch Script

This script is used to launch Quake 3 games on a macOS system. It utilizes the open command to launch the game executable with various arguments to customize the game settings.

Launch Script Structure

The script consists of multiple lines, each launching a Quake 3 game executable with different settings.

Arguments Used

The following arguments are commonly used across multiple launch commands:

Game-Specific Settings

Each launch command has unique settings that are specific to the game being launched. These settings include:

Conclusion

This script launches Quake 3 games on a macOS system with various settings and configurations. It utilizes the open command to launch the game executable and passes arguments to customize the game settings.