Fix links

master
rubenwardy 2018-07-15 19:36:35 +01:00
parent dc7746db33
commit 7a78ee8643
No known key found for this signature in database
GPG Key ID: A1E29D52FF81513C
27 changed files with 77 additions and 74 deletions

View File

@ -92,7 +92,7 @@ Replace spaces with underscores ( _ )
---
title: Player Physics
layout: default
root: ../
root: ..
---
Introduction

View File

@ -1,7 +1,7 @@
---
title: Folder Structure
layout: default
root: ../../
root: ../..
idx: 1.1
description: Learn how to make a mod folder, including init.lua, depends.txt and more.
redirect_from: /en/chapters/folders.html
@ -23,7 +23,7 @@ Each mod has its own folder where all its Lua code, textures, models, and sounds
are placed. These folders need to be placed in a mod location such as
minetest/mods.
![Find the mod's folder]({{ page.root }}/static/folder_modfolder.jpg)
![Find the mod's folder]({{ page.root }}//static/folder_modfolder.jpg)
A "mod name" is used to refer to a mod. Each mod should have a unique mod name.
Mod names can include letters, numbers, and underscores. A good mod name should

View File

@ -1,7 +1,7 @@
---
title: Lua Scripts
layout: default
root: ../../
root: ../..
idx: 1.2
description: A basic introduction to Lua, including a guide on global/local scope.
redirect_from: /en/chapters/lua.html

View File

@ -3,7 +3,7 @@ title: Introduction
layout: default
homepage: true
no_header: true
root: ../
root: ..
idx: 0.1
---

View File

@ -1,7 +1,7 @@
---
title: Inventories
layout: default
root: ../../
root: ../..
idx: 5.2
redirect_from: /en/chapters/inventories.html
---
@ -49,7 +49,7 @@ There are three types of inventory:
* **Detached Inventories**: An inventory which is not attached to a node or player.
<figure>
<img src="{{ page.root }}/static/inventories_lists.png" alt="The player inventory formspec, with annotated list names.">
<img src="{{ page.root }}//static/inventories_lists.png" alt="The player inventory formspec, with annotated list names.">
<figcaption>
This image shows the two inventories visible when you press i.
The gray boxes are inventory lists.<br />
@ -104,7 +104,7 @@ minetest.create_detached_inventory("inventory_name", callbacks)
{% endhighlight %}
This creates a detached inventory or, if the inventory already exists, it is cleared.
You can also supply a [table of callbacks]({{ page.root }}lua_api.html#detached-inventory-callbacks).
You can also supply a [table of callbacks]({{ page.root }}/lua_api.html#detached-inventory-callbacks).
## InvRef and Lists

View File

@ -1,7 +1,7 @@
---
title: ItemStacks
layout: default
root: ../../
root: ../..
idx: 5.1
redirect_from: /en/chapters/itemstacks.html
---
@ -135,5 +135,5 @@ print(dump(meta:get_string("foo")))
## More Methods
Have a look at the
[list of methods for an ItemStack]({{ page.root }}lua_api.html#methods_5).
[list of methods for an ItemStack]({{ page.root }}/lua_api.html#methods_5).
There are a lot more available than talked about here.

View File

@ -1,7 +1,7 @@
---
title: Creating Textures
layout: default
root: ../../
root: ../..
idx: 2.2
description: An introduction to making textures in your editor of choice, an a guide on GIMP.
redirect_from: /en/chapters/creating_textures.html
@ -73,11 +73,11 @@ obvious.
When using GIMP, the pencil tool can be selected from the Toolbox:
<figure>
<img src="{{ page.root }}/static/pixel_art_gimp_pencil.png" alt="Pencil in GIMP">
<img src="{{ page.root }}//static/pixel_art_gimp_pencil.png" alt="Pencil in GIMP">
</figure>
It's also advisable to select the Hard edge checkbox for the eraser tool:
<figure>
<img src="{{ page.root }}/static/pixel_art_gimp_rubber.png" alt="Eraser in GIMP">
<img src="{{ page.root }}//static/pixel_art_gimp_rubber.png" alt="Eraser in GIMP">
</figure>

View File

@ -1,7 +1,7 @@
---
title: Node Drawtypes
layout: default
root: ../../
root: ../..
idx: 2.3
description: Guide to all drawtypes, including node boxes/nodeboxes and mesh nodes.
redirect_from: /en/chapters/node_drawtypes.html
@ -43,7 +43,7 @@ This article is not complete yet. The following drawtypes are missing:
## Normal
<figure class="right_image">
<img src="{{ page.root }}/static/drawtype_normal.png" alt="Normal Drawtype">
<img src="{{ page.root }}//static/drawtype_normal.png" alt="Normal Drawtype">
<figcaption>
Normal Drawtype
</figcaption>
@ -102,7 +102,7 @@ minetest.register_node("myair:air", {
## Liquid
<figure class="right_image">
<img src="{{ page.root }}/static/drawtype_liquid.png" alt="Liquid Drawtype">
<img src="{{ page.root }}//static/drawtype_liquid.png" alt="Liquid Drawtype">
<figcaption>
Liquid Drawtype
</figcaption>
@ -185,7 +185,7 @@ the same as the above example.
## Glasslike
<figure class="right_image">
<img src="{{ page.root }}/static/drawtype_glasslike.png" alt="Glasslike Drawtype">
<img src="{{ page.root }}//static/drawtype_glasslike.png" alt="Glasslike Drawtype">
<figcaption>
Glasslike Drawtype
</figcaption>
@ -195,7 +195,7 @@ When you place multiple glasslike nodes together, you'll notice that the interna
edges are hidden, like this:
<figure>
<img src="{{ page.root }}/static/drawtype_glasslike_edges.png" alt="Glasslike's Edges">
<img src="{{ page.root }}//static/drawtype_glasslike_edges.png" alt="Glasslike's Edges">
<figcaption>
Glasslike's Edges
</figcaption>
@ -220,7 +220,7 @@ This makes the node's edge go around the whole thing with a 3D effect, rather
than individual nodes, like the following:
<figure>
<img src="{{ page.root }}/static/drawtype_glasslike_framed.png" alt="Glasslike_framed's Edges">
<img src="{{ page.root }}//static/drawtype_glasslike_framed.png" alt="Glasslike_framed's Edges">
<figcaption>
Glasslike_Framed's Edges
</figcaption>
@ -250,7 +250,7 @@ minetest.register_node("default:glass", {
## Allfaces
<figure class="right_image">
<img src="{{ page.root }}/static/drawtype_allfaces.png" alt="Allfaces drawtype">
<img src="{{ page.root }}//static/drawtype_allfaces.png" alt="Allfaces drawtype">
<figcaption>
Allfaces drawtype
</figcaption>
@ -311,7 +311,7 @@ minetest.register_node("foobar:torch", {
## Nodebox
<figure class="right_image">
<img src="{{ page.root }}/static/drawtype_nodebox.gif" alt="Nodebox drawtype">
<img src="{{ page.root }}//static/drawtype_nodebox.gif" alt="Nodebox drawtype">
<figcaption>
Nodebox drawtype
</figcaption>
@ -438,7 +438,7 @@ minetest.register_node("default:ladder_wood", {
## Plantlike
<figure class="right_image">
<img src="{{ page.root }}/static/drawtype_plantlike.png" alt="Plantlike Drawtype">
<img src="{{ page.root }}//static/drawtype_plantlike.png" alt="Plantlike Drawtype">
<figcaption>
Plantlike Drawtype
</figcaption>
@ -466,7 +466,7 @@ Firelike is similar to plantlike, except that it is designed to "cling" to walls
and ceilings.
<figure>
<img src="{{ page.root }}/static/drawtype_firelike.png" alt="Firelike nodes">
<img src="{{ page.root }}//static/drawtype_firelike.png" alt="Firelike nodes">
<figcaption>
Firelike nodes
</figcaption>

View File

@ -1,7 +1,7 @@
---
title: Nodes, Items, and Crafting
layout: default
root: ../../
root: ../..
idx: 2.1
description: Learn how to register node, items, and craft recipes using register_node, register_item, and register_craft.
redirect_from: /en/chapters/nodes_items_crafting.html

View File

@ -1,7 +1,7 @@
---
title: Active Block Modifiers
layout: default
root: ../../
root: ../..
idx: 3.2
description: Learn how to make ABMs to change blocks.
redirect_from: /en/chapters/abms.html

View File

@ -1,7 +1,7 @@
---
title: Basic Map Operations
layout: default
root: ../../
root: ../..
idx: 3.1
description: Basic operations like set_node and get_node
redirect_from: /en/chapters/environment.html

View File

@ -1,7 +1,7 @@
---
title: Lua Voxel Manipulators
layout: default
root: ../../
root: ../..
idx: 3.4
description: Learn how to use LVMs to speed up map operations.
redirect_from: /en/chapters/lvm.html

View File

@ -1,7 +1,7 @@
---
title: Node Metadata
layout: default
root: ../../
root: ../..
idx: 3.3
description: Using get_meta to obtain a NodeMetaRef.
redirect_from: /en/chapters/node_metadata.html

View File

@ -1,7 +1,7 @@
---
title: Chat and Commands
layout: default
root: ../../
root: ../..
idx: 4.2
description: Registering a chatcommand and handling chat messages with register_on_chat_message
redirect_from: /en/chapters/chat.html

View File

@ -1,7 +1,7 @@
---
title: Chat Command Builder
layout: default
root: ../../
root: ../..
idx: 4.3
description: Use ChatCmdBuilder to make a complex chat command
redirect_from: /en/chapters/chat_complex.html

View File

@ -1,7 +1,7 @@
---
title: Formspecs
layout: default
root: ../../
root: ../..
idx: 4.5
redirect_from: /en/chapters/formspecs.html
---
@ -9,7 +9,7 @@ redirect_from: /en/chapters/formspecs.html
## Introduction
<figure class="right_image">
<img src="{{ page.root }}/static/formspec_example.png" alt="Furnace Inventory">
<img src="{{ page.root }}//static/formspec_example.png" alt="Furnace Inventory">
<figcaption>
Screenshot of furnace formspec, labelled.
</figcaption>
@ -96,7 +96,7 @@ and to see if the callback is relevant.
This example shows a formspec to a player when they use the /formspec command.
<figure class="right_image">
<img src="{{ page.root }}/static/formspec_name.png" alt="Name Formspec">
<img src="{{ page.root }}//static/formspec_name.png" alt="Name Formspec">
<figcaption>
The formspec generated by<br />
the example's code

View File

@ -1,7 +1,7 @@
---
title: HUD
layout: default
root: ../../
root: ../..
idx: 4.6
redirect_from: /en/chapters/hud.html
---
@ -33,7 +33,7 @@ The HUD doesn't accept user input. For that, you should use a [Formspec](formspe
<figure class="right_image">
<img
width="300"
src="{{ page.root }}/static/hud_diagram_center.svg"
src="{{ page.root }}//static/hud_diagram_center.svg"
alt="Diagram showing a centered text element">
</figure>
@ -60,7 +60,7 @@ make a text element left, center, or right justified.
<figure>
<img
width="500"
src="{{ page.root }}/static/hud_diagram_alignment.svg"
src="{{ page.root }}//static/hud_diagram_alignment.svg"
alt="Diagram showing alignment">
</figure>
@ -75,7 +75,7 @@ score panel like so:
<figure>
<img
src="{{ page.root }}/static/hud_final.png"
src="{{ page.root }}//static/hud_final.png"
alt="screenshot of the HUD we're aiming for">
</figure>
@ -159,7 +159,7 @@ This results in the following:
<figure>
<img
src="{{ page.root }}/static/hud_text.png"
src="{{ page.root }}//static/hud_text.png"
alt="screenshot of the HUD we're aiming for">
</figure>
@ -183,7 +183,7 @@ You will now have this:
<figure>
<img
src="{{ page.root }}/static/hud_background_img.png"
src="{{ page.root }}//static/hud_background_img.png"
alt="screenshot of the HUD so far">
</figure>
@ -292,4 +292,4 @@ end)
## Other Elements
Read [lua_api.txt]({{ page.root }}lua_api.html#hud-element-types) for a complete list of HUD elements.
Read [lua_api.txt]({{ page.root }}/lua_api.html#hud-element-types) for a complete list of HUD elements.

View File

@ -1,7 +1,7 @@
---
title: Player Physics
layout: default
root: ../../
root: ../..
idx: 4.4
redirect_from: /en/chapters/player_physics.html
---
@ -38,7 +38,7 @@ minetest.register_chatcommand("antigravity", {
## Available Overrides
player:set_physics_override() is given a table of overrides.\\
According to [lua_api.txt]({{ page.root }}lua_api.html#player-only-no-op-for-other-objects),
According to [lua_api.txt]({{ page.root }}/lua_api.html#player-only-no-op-for-other-objects),
these can be:
* speed: multiplier to default walking speed value (default: 1)

View File

@ -1,7 +1,7 @@
---
title: Privileges
layout: default
root: ../../
root: ../..
idx: 4.1
description: Registering privs.
redirect_from: /en/chapters/privileges.html

View File

@ -1,7 +1,7 @@
---
title: "SFINV: Inventory Formspec"
layout: default
root: ../../
root: ../..
idx: 4.7
redirect_from: /en/chapters/sfinv.html
---
@ -57,7 +57,7 @@ The fourth parameter, currently set as `true`, determines whether or not the
player's inventory is shown.
<figure>
<img src="{{ page.root }}/static/sfinv_hello_world.png" alt="Furnace Inventory">
<img src="{{ page.root }}//static/sfinv_hello_world.png" alt="Furnace Inventory">
<figcaption>
Your first sfinv page! Not exactly very exciting, though.
</figcaption>
@ -109,7 +109,7 @@ There's nothing new about the above code, all the concepts are covered above and
in previous chapters.
<figure>
<img src="{{ page.root }}/static/sfinv_admin_fs.png" alt="Player Admin Page">
<img src="{{ page.root }}//static/sfinv_admin_fs.png" alt="Player Admin Page">
<figcaption>
The player admin page created above.
</figcaption>

View File

@ -1,7 +1,7 @@
---
title: Intro to Clean Architectures
layout: default
root: ../../
root: ../..
idx: 6.3
---
@ -159,7 +159,7 @@ to the Minetest API at all.
<figure class="right_image">
<img
width="100%"
src="{{ page.root }}/static/mvc_diagram.svg"
src="{{ page.root }}//static/mvc_diagram.svg"
alt="Diagram showing a centered text element">
</figure>

View File

@ -1,7 +1,7 @@
---
title: Common Mistakes
layout: default
root: ../../
root: ../..
idx: 6.1
redirect_from: /en/chapters/common_mistakes.html
---

View File

@ -1,7 +1,7 @@
---
title: Automatic Error Checking
layout: default
root: ../../
root: ../..
idx: 6.2
description: Use LuaCheck to find errors
redirect_from: /en/chapters/luacheck.html

View File

@ -1,7 +1,7 @@
---
title: Read More
layout: default
root: ../../
root: ../..
idx: 6.6
redirect_from: /en/chapters/readmore.html
---
@ -12,7 +12,7 @@ After you've read this book, take a look at the following
### Minetest Modding
* Minetest's Lua API Reference - [HTML version]({{ page.root }}lua_api.html) |
* Minetest's Lua API Reference - [HTML version]({{ page.root }}/lua_api.html) |
[Text version](https://github.com/minetest/minetest/blob/master/doc/lua_api.txt).
* Explore the [Developer Wiki](http://dev.minetest.net/Main_Page).
* Look at [existing mods](https://forum.minetest.net/viewforum.php?f=11).

View File

@ -1,7 +1,7 @@
---
title: Releasing a Mod
layout: default
root: ../../
root: ../..
idx: 6.5
redirect_from: /en/chapters/releasing.html
---
@ -194,7 +194,7 @@ Click browse and select the zipped file. It is recommended that you
enter the version of your mod in the comment field.
<figure>
<img src="{{ page.root }}/static/releasing_attachments.png" alt="Upload Attachment">
<img src="{{ page.root }}//static/releasing_attachments.png" alt="Upload Attachment">
<figcaption>
Upload Attachment tab.
</figcaption>
@ -267,7 +267,7 @@ The subject of topic must be in one of these formats:
### Profit
<figure>
<img src="{{ page.root }}/static/releasing_profit.png" alt="Profit">
<img src="{{ page.root }}//static/releasing_profit.png" alt="Profit">
<figcaption style="display:none;">
Profit
</figcaption>

View File

@ -1,7 +1,7 @@
---
title: Automatic Unit Testing
layout: default
root: ../../
root: ../..
idx: 6.4
---

View File

@ -18,11 +18,10 @@ layout: compress
{% assign language = pathsplit[1] %}
{% if language == "en" %}
{% assign links = site.en | sort: "idx" %}
{% assign links = site.en | sort: "idx" %}
{% else %}
{% assign language = "en" %}
{% assign links = site.en | sort: "idx" %}
{% assign language = "en" %}
{% assign links = site.en | sort: "idx" %}
{% endif %}
{% assign num = 0 %}
@ -30,19 +29,23 @@ layout: compress
<div id="container">
<nav>
{% for link in links %}
{% assign idsplit = link.id | split: '/' %}
{% assign section = idsplit[2] %}
<li><a href="{{ link.url }}"
class="{% if page.title == link.title %}selected{% endif %}{% if section != last_section and section != 'index' %} hr {% endif %}">
{% if section != "index" %}{{ num }} - {% endif %}
{{ link.title }}</a></li>
{% assign idsplit = link.id | split: '/' %}
{% assign section = idsplit[2] %}
<li>
<a href="{{ page.root }}{{ link.url }}"
class="{% if page.title == link.title %}selected{% endif %}{% if section != last_section and section != 'index' %} hr {% endif %}">
{% if section != "index" %}{{ num }} - {% endif %}
{{ link.title }}
</a>
</li>
{% assign last_section = section %}
{% assign num = num | plus:1 %}
{% endfor %}
{% endfor %}
<li><a href="{{ page.root }}lua_api.html" class="hr">Lua Modding API Reference</a></li>
<li><a href="https://github.com/rubenwardy/minetest_modding_book/archive/examples.zip">Download Examples</a></li>
</nav>
<li><a href="{{ page.root }}/lua_api.html" class="hr">Lua Modding API Reference</a></li>
<li><a href="https://github.com/rubenwardy/minetest_modding_book/archive/examples.zip">Download Examples</a></li>
</nav>
<main>
<article {% if page.homepage %}class="homepage"{% endif %}>
@ -64,8 +67,8 @@ layout: compress
{% endfor %}
<ul class="prevnext">
<li>{% if prev %}<a href="{{ prev.url}}">&lt; {{ prev.title }}</a>{% endif %}</li>
<li>{% if next %}<a href="{{ next.url}}">{{ next.title }} &gt;</a>{% endif %}</li>
<li>{% if prev %}<a href="{{ page.root }}{{ prev.url}}">&lt; {{ prev.title }}</a>{% endif %}</li>
<li>{% if next %}<a href="{{ page.root }}{{ next.url}}">{{ next.title }} &gt;</a>{% endif %}</li>
</ul>
<footer>
@ -76,8 +79,8 @@ layout: compress
</footer>
</article>
</main>
<link rel="stylesheet" href="{{ page.root }}static/style.css">
<link rel="stylesheet" href="{{ page.root }}/static/style.css">
<script async src="https://code.jquery.com/jquery-1.11.2.min.js"></script>
<script async src="{{ page.root }}static/script.js"></script>
<script async src="{{ page.root }}/static/script.js"></script>
</body>
</html>