Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/Gunivers/Bookshelf
Browse files Browse the repository at this point in the history
  • Loading branch information
VForiel committed Aug 3, 2023
2 parents 92275f2 + efdf772 commit 97377e1
Show file tree
Hide file tree
Showing 4 changed files with 45 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,10 @@
"minecraft:air",
"minecraft:water",
"minecraft:lava",
"minecraft:iron_bars"
"minecraft:iron_bars",
"minecraft:cave_air",
"minecraft:void_air",
"minecraft:light",
"minecraft:moving_piston"
]
}
}
13 changes: 13 additions & 0 deletions docs/.readthedocs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
version: 2

build:
os: ubuntu-22.04
tools:
python: "3.9"

sphinx:
configuration: docs/conf.py

python:
install:
- requirements: docs/requirements.txt
2 changes: 2 additions & 0 deletions docs/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@ This version contain breaking changes. In the following changelog, they are iden
- (score) `bs.temperature` $\rightarrow$ `bs.biome.temp`
- (tag) `bs.canRain` $\rightarrow$ `bs.biome.CanRain`
- (tag) `bs.canSnow` $\rightarrow$ `bs.biome.CanSnow`
- 💥 `bs.location:get_relative` and `bs.location:add` now use `bs.loc.[rx,ry,rz]` scores
- 💥 "accuracy" folders was renamed to "scale" and files inside was renamed "10-X" to "X"

### 🐛 Bug fixes

Expand Down
28 changes: 24 additions & 4 deletions docs/faq.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,3 @@
---
html_theme.sidebar_secondary.remove: true
---

# ❓ FAQ

## Can I use the lib in my map/server project?
Expand All @@ -16,6 +12,30 @@ Also, don't hesitate to share us your creation in order to let us know how you u

The lib is under a license that allows you to use and modify it for your personal use and distribute a map or a datapack that uses the lib without any problem as long as you don't make money on it.

## Is this lib compatible with other datapacks?

Yes! The lib respond to constraints that allow it to be compatible with most of datapacks. All Bookshelf scores, tags namespace and others start with `bs.` and use fakeplayers when it's possible to avoid conflicts.

## Is the lib heavy?

### CPU usage

By principle, a lib is just a set of tools that you can call. If you don't, this set of tool will do nothing by it's own. It will not impact the CPU performances in any way if you don't use it. This impact will depend of the functions you will call and the frequency of these calls. The documentation contain warning and performance tips below functions that can be heavy.

### Memory usage

In term of memory usage, Minecraft parse the entire datapack when the game load, so the number of files doesn't matter and instructions are very very very very light in memory so you can have a lot of them without seeing a big diffference in RAM usage. Moreover, the lib is fully modulare, allowing you to only takes modules that you will use.

### Disk usage

The lib is compressed in a zip file so it is only few Mb. Still to big for you? No problem, remember that the entire lib is modular, so you can select only the modules you will use. Also, you should download the lib from github releases or Bookshelf manager, not directly via the repository. In fact, there is an entire map, documentation and generators in the reporistory that you don't need to download if you just want to use the lib. Releases et Bookshelf manager are made to give you only usefull files.

## Are the functions optimized?

The lib is mainly focused on accessibility and multi-purpose usage. There is then a lot of things that are considered which can sometimes lead to choices that are not the most optimized in a given contexte, but that better fit the lib objectives. However, as long as there is no dilemma between accessibility and optimization, the lib will always try to be as optimized as possible.

Also, we are always open to suggestions and pull requests that can improve the lib. If you have an idea to improve the lib (optimization, accessibility or anything else), don't hesitate to share it with us!


```{button-link} https://discord.gg/E8qq6tN
:color: primary
Expand Down

0 comments on commit 97377e1

Please sign in to comment.