Fix up Readme and Formspec typo

master
ExeVirus 2020-12-22 21:13:22 -05:00
parent ab099890cf
commit efd76d1afc
3 changed files with 43 additions and 20 deletions

View File

@ -5,35 +5,43 @@ Explainations are better left for the mod:
![In-Game Guidebook](readme_assets/guidebook.jpg) ![In-Game Guidebook](readme_assets/guidebook.jpg)
### Quick description: ## Elements
- 4 Elements, each are a floating entity in game world, physicaly interact. - 4 Elements, each are a floating entity in game world, and are clicked on by players
- These spawn as player walks throughout world. More spawn on newly generated chunks, especially farther from spawn. - These spawn as player walks throughout world. More spawn farther from spawn.
- They spawn by biome in default. Otherwise, they spawn anywhere. They are right-clicked to capture. - They spawn by biome in default. Otherwise, they spawn anywhere.
- They also make sound, this is how you normally find them. They produce a small amount of light. - They also make sound, this is how you normally find them. They produce a small amount of light.
Used in a crafting shop kind of block. It lets a player search by name. ## Shop
The player then is able to "buy" that node using the stacked elements (which are tracked by player).
All players can (setting) start with the guidebook, and pouch. One explains the system, the other displays the current total number of elements a player has. Either a chat command (/shop) and/or a craftable block (all set via settings)
------Default Players "spend" elements to purchase adventure items/nodes. These are ideally things only obtainable through the adventure shop.
In default, the player crafts the adventure_shop via normal crafting. This can also be disabled via setting, and a server owner can decide where to place the shop(s) via creative mode.
In default, the player can also craft the adventure_guidebook, and adventure_purse.
-------- ## Starting Items
All players can (via a setting) start with the guidebook, and pouch. One explains the system, the other displays the current total number of elements a player has.
Without default, the player can do a command to bring up the formspec for both purse and guidebook:
/adventure_guidebook
/adventure_purse
Without default, the shop can be crafted with the /make_shop command, which requires 10 of each element to create. ## Pouch and Guidebook
--------
For both, when a player captures one element, the player gets a small text dialog showing them how much of element they have captured.
Adventure core ships with some built-in nodes a player can create in the shop, as well as a (if enabled) craftable shop node. #### If default (minetest game) is present:
- the player crafts the adventure_shop via normal crafting. This can also be disabled via setting, and a server owner can decide where to place the shop(s) via creative mode.
- the player can also craft the adventure_guidebook, and adventure_pouch.
### if default is *not* present:
The player can do a command to bring up the formspec for both pouch and guidebook:
/guidebook
/pouch
In this mode, the shop can be crafted (if enabled) with the /make_shop command, which requires 10 of each element to create.
## Built-in Nodes
*Adventure core* ships with some built-in nodes a player can create in the shop, as well as a (if enabled) craftable *shop node*.
Built-in ones, 6 static mesh nodes: Built-in ones, 6 static mesh nodes:
1. A small bridge 1. A small bridge
@ -44,9 +52,24 @@ Built-in ones, 6 static mesh nodes:
6. Axe Stump 6. Axe Stump
------ ------
Adventure core works by a player registering a node_name and element requirement, The node inventory image from the node_def/item_def is used as the picture, except for nodes with a mesh drawtype, these are displayed with a viewable mesh!
## Integrating with adventure core
To register your nodes and items with the adventure core shop, merely *depend* on adventure_core in your depends.txt, and use the following function to register:
```
adv_core.register_object(object_name, lfire, lwater, learth, lair)
```
Where object name would be: "default:apple" etc. and lfire,lwater... are the element costs.
There are other functions that expose the element system so you can use it for your own rewards system:
```
adv_core.spawn_element(element_type, pos) --Element_type can be: "fire" "water" "earth" "air"
adv_core.reward_player(name, fire, water, earth, air, notify) --notify is 'true' or 'false', and will tell the player when the action occurs
adv_core.take_from_player(name, fire, water, earth, air, notify)
adv_core.player_can_afford(name, fire, water, earth, air) --returns true if they can
adv_core.player_can_afford_object(name, object_name) --returns true if they can

View File

@ -36,7 +36,7 @@ function adv_core.guide_formspec(name)
if adv_core.setting("enable_chat_commands",true) then if adv_core.setting("enable_chat_commands",true) then
table.insert(formspec, "type '/pouch' in chat, or\n") table.insert(formspec, "type '/pouch' in chat, or\n")
end end
table.insert(formspec, "craft a 'guidebook'.\n") table.insert(formspec, "craft a 'pouch'.\n")
table.insert(formspec, "<global halign=center>\n There is also a Adventure shop!\n") table.insert(formspec, "<global halign=center>\n There is also a Adventure shop!\n")
if adv_core.setting("enable_adventure_shop",true) then if adv_core.setting("enable_adventure_shop",true) then
if adv_core.setting("enable_chat_commands",true) then if adv_core.setting("enable_chat_commands",true) then

Binary file not shown.

Before

Width:  |  Height:  |  Size: 79 KiB

After

Width:  |  Height:  |  Size: 52 KiB