]> git.xonotic.org Git - xonotic/xonotic.wiki.git/blob - SMB-modpack.md
Update Compiling: add libtool dependency
[xonotic/xonotic.wiki.git] / SMB-modpack.md
1 Developed and maintained by **[Mario](https://github.com/MarioSMB)** and **[TimePath](https://github.com/TimePath)**.
2
3 The **[modpack](https://github.com/MarioSMB/modpack)** was **[TimePath](https://github.com/TimePath)**'s experiment to split "custom" features into a secluded codebase. <br/>
4 It makes it used to create games based on the Xonotic template.
5
6 The modpack build works using a submodule from '_xonotic-data.pk3dir_' from the official gamelogic development repository.
7
8 Uses **update.sh** and **build.sh** shell script files. 
9
10 ### You can create mods from the modpack like: 
11 ### **[Quake](https://github.com/MarioSMB/modpack/tree/quake)**
12 <img src="uploads/a622ef2d5c0c5ca81d6f044c452293eb/quake_mod_sample.jpg" alt="quake_mod_sample" width=550 />
13
14 ### **[Prydon Gate](https://github.com/MarioSMB/modpack/tree/prydon)**
15 <img src="uploads/2dd93a2f8ce7b22400c32535c9fad392/prydon_mod_sample.jpg" alt="prydon_mod_sample" width=550 />
16
17 ### **[Suwa Moriya 64](https://github.com/MarioSMB/modpack/tree/moriya)**
18 <img src="uploads/33a69c4499702fbf8592766ebae04c34/suwa_moriya_64_mod_sample.jpg" alt="suwa_moriya_64_mod_sample" width=550 />
19
20 # How submodule works, update.sh and build.sh
21
22 Uses '_update.sh_' to obtain the content of '_gmqcc_', '_xonotic-data.pk3dir_' in '_xonotic_' folder and '_csprogs_' in '_.cache_' folder. Clearly, needs gmqcc to be able to compile, this means that '_build.sh_' calls gmqcc to compile the code.
23
24 ## Submodule and update.sh
25
26 The submodule of this modpack was created using: 
27 ```sh
28 git submodule add https://gitlab.com/xonotic/xonotic-data.pk3dir xonotic
29 ```
30
31 The submodule in the repository is used when need to update the code from '_xonotic-data.pk3dir_', to do this if you've a fork or a copy of SMB modpack repository, you'll have to update using (note: in your local computer, you should have used '_update.sh_' to download fully the content of '_xonotic-data.pk3dir_' in '_xonotic_' folder):
32 ```sh
33 git submodule update --remote --merge
34 ```
35
36 It'll update the content where is in the official gamelogic development repository in your modpack repository.
37
38 Inside '_update.sh_', there is a line: 
39 ```sh
40 git submodule update --init --depth 100
41 ```
42
43 Means that when you use '_update.sh_' with this line, the submodule content will be downloaded in your local computer where you've cloned the modpack repository.
44
45 To run '_update.sh_' script, you should go to the current directory where is this script and execute:
46 ```sh
47 ./update.sh
48 ```
49
50 ### Commit with submodule
51
52 Additionally, after done `git submodule update --remote --merge`, if you want to commit:
53 ```sh
54 git status
55 git add xonotic
56 git commit -m "Update submodule xonotic test"
57 git push origin master #depends what origin and what branch of repository you're using to do your commits
58 ```
59 ## build.sh
60
61 '_build.sh_' compiles all repository code using gmqcc if already downloaded from '_update.sh_', looks inside '_mod_' folder the similar contents of '_xonotic-data.pk3dir/qcsrc_' where there are: '_client_', '_common_', '_menu_' and '_server_' folders.
62
63 What this does is relate the directory path to the submodule '_xonotic_' directory inside the '_qcsrc_' folder. Thanks to this, makes possible to look at the '_mod_' folder having to relate the submodule directory '_xonotic/qcsrc_'.
64
65 To run '_build.sh_' script, you should go to the current directory where is this script and execute:
66 ```sh
67 ./build.sh
68 ```
69
70 For speed up compilation, you can run with:
71 ```sh
72 ZIP=: ./build.sh
73 ```
74
75 That executes without compression (without getting `csprogs-*.pk3` file).