Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wiki pages #51

Merged
merged 2 commits into from
Dec 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 34 additions & 0 deletions content/accessing-android-data-directory.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
---
title: Accessing Android Data Directory
aliases:
- /Accessing_Android_Data_Directory
---

# Accessing Android Data Directory
Starting with Minetest 5.4.2, the Android version now stores its user data in its scoped app storage at `/storage/emulated/0/Android/data/net.minetest.net/files/Minetest`. This is caused by a restriction of recent Android API levels and Google Play policies and it is unfortunately impossible to store it in the old more accessible `/storage/emulated/0/Minetest/` location.

While it is officially intended by Google to not be accessible to regular users, there are still ways to circumvent it and still access the folder.

Total Commander workaround (Android <=12)
-----------------------------------------

[Total Commander](https://play.google.com/store/apps/details?id=com.ghisler.android.TotalCommander&hl=en_GB&gl=US) (and possibly other file managers) have a method to workaround the restrictions put in place by Google, by taking advantage of a bug in Android 12 and below that allows file managers to be given permission to `/Android/data/`.

See [https://forum.minetest.net/viewtopic.php?f=18&t=27684](https://forum.minetest.net/viewtopic.php?f=18&t=27684)

Through ADB (Needs computer)
----------------------------

You can access the scoped storage through ADB, a debugging tool part of the [Android platform tools](https://developer.android.com/studio/releases/platform-tools). In order to use ADB, you will need to enable USB debugging from the Android developer settings and connect your phone to a computer. On Linux, it should work out of the box. However on Windows you will need to find so called "ADB drivers" from your phone's manufacturer.

ADB is primarily a command-line tool, and you usually would want to use the `adb pull` and `adb push` commands similar to working with something like SCP. ADB also supports tab autocompletion on the remote side, so you can look at the directory structure on your phone while typing out a command. Some example commands:

* **Pushing a world from your computer onto your phone:** `adb push cool_world/ /storage/emulated/0/Android/data/net.minetest.minetest/files/Minetest/worlds/`

* **Manually installing a mod not available on ContentDB:** `adb push indev_mod/ /storage/emulated/0/Android/data/net.minetest.minetest/files/Minetest/mods/`

* **Backing up a world to your computer:** `adb pull /storage/emulated/0/Android/data/net.minetest.minetest/files/Minetest/worlds/cool_world/ cool_world_android_backup/`

* **Backing up your entire Android user data to your computer:** `adb pull /storage/emulated/0/Android/data/net.minetest.minetest/files/Minetest/ minetest_android_backup/`

The `adb shell` command is also available allowing you to launch a shell on your phone, use `cd /storage/emulated/0/Android/data/net.minetest.minetest/files/Minetest` to navigate into the user data and manage it with regular Linux terminal commands.
67 changes: 67 additions & 0 deletions content/backup-solutions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
---
title: Backup Solutions
aliases:
- /Backup_Solutions
---

# Backup Solutions
Backing up Luanti data can be a real pain due to the size and complexity of some worlds and mods. We have written this guide to provide you with some information regarding backing up data.

World Backups
-------------

[Worlds](https://wiki.luanti.org/Worlds "Worlds") will usually be contained in the Luanti data directory under the `worlds` directory.

Inside, one can see the individual worlds. For the structure of the worlds directory, see \[[the relevant wiki page](https://wiki.minetest.net/Worlds#World_directory_content)\].

To back up a world, these are some solutions:


World Backup Solutions


* Solution: Copying the directoy
* Details: By taking the world directory and copying it somewhere else, a simple backup may be achieved.
* Strengths and weaknesses: Will double the space taken by the world and is not very efficent
* Solution: Git
* Details: Using a git repository to contain the world
* Strengths and weaknesses: Again, git will take the world and save it under the .git directory for keepeing. It can be good for documenting changes but is not reccomended for most usecases
* Solution: Compression
* Details: Using a compression algorithm to make the world smaller
* Strengths and weaknesses: Makes a smaller file, reducing total space taken, but can be slow or memory-intensive on some devices.


Mod Backups
-----------

Due to the constantly-changing nature of mods (which both makes them securer and insecurer), creating a backup is not reccomended. Mods will eventually grow out of date and you will both miss out on the latest features and security fixes.

Mods can be backed up in the same way as worlds, or you could use the following script:

One can write down git repositories in a file and use the following script to download them again:

```
import os

# Read the file containing the list of repositories
with open('repositories.txt') as f:
repositories = f.readlines()

# Loop through the repositories and clone each one
for repo in repositories:
# Remove any whitespace or newlines from the repository URL
repo = repo.strip()

# Clone the repository using Git
os.system(f'git clone {repo}')
```


This approach can work quite well if you want the latest features and to be able to update things.

User Data
---------

Other user data is important.

`minetest.conf` in the root directory will contain all the setting you changed, and the `screenshots` directory contains any photos you made.
25 changes: 25 additions & 0 deletions content/building.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
---
title: Building
aliases:
- /Building
---

# Building

**Building**—also called **placing**—is the activity of placing blocks next to other blocks. It is one of the most basic things you can do in Luanti.

Building requires the “interact” [privilege](https://wiki.luanti.org/Privileges "Privileges") (a default privilege).

To build, one must wield something which can be built, [point](https://wiki.luanti.org/Pointing "Pointing") to something which can be built to and press the build key (Right mouse button by default). Most [blocks](https://wiki.luanti.org/Blocks "Blocks") can be built. Building is, unlike [mining](https://wiki.luanti.org/Mining "Mining"), always instantly done. On blocks which can be [used](https://wiki.luanti.org/Using "Using") (e.g. [Chest](https://wiki.luanti.org/Chest "Chest"), [Furnace](https://wiki.luanti.org/Furnace "Furnace"), [Sign](https://wiki.luanti.org/Sign "Sign"), etc.), you have to press [Sneak](https://wiki.luanti.org/Sneaking "Sneaking")+Right-click instead.

Minetest Game
-------------

By building a [slab](https://wiki.luanti.org/Slab "Slab") onto another slab of the same material, a full block of the same material is created. It is possible to build _inside_ some nodes which entirely destroys them. [Air](https://wiki.luanti.org/Air "Air"), can always be replaced, as well as liquids like [water](https://wiki.luanti.org/Water "Water"), too. Many [plants](https://wiki.luanti.org/Category:Plants "Category:Plants") like [grass](https://wiki.luanti.org/Grass "Grass") can also be built inside.

For [Tree](https://wiki.luanti.org/Tree "Tree"), [Acacia Tree](https://wiki.luanti.org/Acacia_Tree "Acacia Tree"), etc. and [Cactus](https://wiki.luanti.org/Cactus "Cactus"), the initial facing direction will be from the block face you placed the block on. E.g. if you placed a tree on the floor, it will stand vertically, and if you placed it at the side of a block, it will be horizontal. By holding down the Sneak key while building, you can reverse the placement behaviour: Placing a block vertically rotates it horizontally, and vice-versa.

See also
--------

* [Using](https://wiki.luanti.org/Using "Using")
14 changes: 14 additions & 0 deletions content/calinous-law.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
title: Calinou's Law
aliases:
- /Calinou%27s_Law
---

# Calinou's Law
**Calinou's Law** is a supposition about the density of ores in Luanti. It states, approximately:

The more ores that are registered, the more likely you will be to find nothing BUT ores by the time you dig down to -31 km.

In theory, one could reach a state in a game where there are indeed nothing but minerals and no plain stone at some depth by adding enough ore-bearing mods, however this particular idea refers more to the issue some people have of going on a mining expedition and coming back so loaded down with ores that one has no room in their inventory for anything else, such as cobblestone. Calinou's Law is this phenomenon taken to its logical extreme.

Compare "rainbow caves" phenomenon, wherein there are so many minerals in a given area that cave walls take on a multicolor or "rainbow" appearance.