1307 Commits

Author SHA1 Message Date
IntegratedQuantum
b882e81c73 Always use explicit direction 2025-07-27 14:48:27 +02:00
IntegratedQuantum
be9069c8df push pop isEmpty 2025-07-26 15:18:30 +02:00
IntegratedQuantum
b5f255c9a2 Move the guidelines to /docs 2025-07-26 14:28:44 +02:00
ikabod-kee
29796daba5
Game Design Principles Update (#1650)
I went ahead and rephrased much of the Game Design Principles to make
them clearer.

---------

Co-authored-by: IntegratedQuantum <43880493+IntegratedQuantum@users.noreply.github.com>
Co-authored-by: Krzysztof Wiśniewski <argmaster.world@gmail.com>
Co-authored-by: IntegratedQuantum <jahe788@gmail.com>
2025-07-26 14:25:00 +02:00
codemob
2fa5e0bae2
basic swim movement (#1665)
Adds basic water control. Starts #85.

---------

Co-authored-by: IntegratedQuantum <43880493+IntegratedQuantum@users.noreply.github.com>
Co-authored-by: IntegratedQuantum <jahe788@gmail.com>
2025-07-26 14:03:41 +02:00
Krzysztof Wiśniewski
e4030386d6
Binary storage for inventories (#1662)
Related to: #1642
Resolves: #1290

---------

Co-authored-by: IntegratedQuantum <43880493+IntegratedQuantum@users.noreply.github.com>
Co-authored-by: OneAvargeCoder193 <mgiakimenko@outlook.com>
2025-07-26 13:52:53 +02:00
codemob
55dc104c37
Use an approximation of the heightmap derivative to "erode" some layers of ground_structure (#1699)
Fixes #188
2025-07-25 22:04:45 +02:00
codemob
a47c8d14a1
Prevent settings from breaking when no previous file is present. (#1719)
Fix #1718
2025-07-25 18:09:51 +02:00
IntegratedQuantum
08c78ff48d Fix double free detection of the StackAllocator 2025-07-25 17:28:59 +02:00
EN
432e476d0f
add .mushroom tag and make mushroom logs cuttable (#1717)
Added ".mushroom" tags suggested here #1713 
Also made the mushroom logs ".cuttable" to match the rest of the
mushroom blocks.
2025-07-24 16:49:17 +02:00
IntegratedQuantum
ab691cec73 Use GarbageCollection for LightMapFragments 2025-07-23 22:29:50 +02:00
IntegratedQuantum
6089c58e55 Fix getBlockFromAnyLod to include the chunk at highestLod
fixes #1710
2025-07-23 21:32:42 +02:00
codemob
468f959c54
Allow searching by tag in the creative inventory (#1700)
fixes #1659

---------

Co-authored-by: IntegratedQuantum <43880493+IntegratedQuantum@users.noreply.github.com>
2025-07-23 21:22:50 +02:00
codemob
8a0eeaa9ae
Use mineable, choppable, diggable, and cuttable instead of stone, wood, sand, and leaf. (#1711)
Fixes #1604 
Fixes #1601
fixes #1712
2025-07-23 20:06:40 +02:00
IntegratedQuantum
709abbd5bd Add an issue template link and a file for info about content suggestions 2025-07-22 20:28:50 +02:00
IntegratedQuantum
6baf7fc067
Garbage Collection - The Great Return (#1680)
This is a first attempt to get rid of of reference counting #1413

Basically all threads execute a global sync point, this allows
determining a time when all temporary resources (such as meshes on the
client side used in lighting on other threads) have been freed with 100%
certainty.

Remaining work:
- [x] Implement the sync point
- [x] Implement free lists and free the resources
- [x] Determine if this is worth it performance wise
  - [x] Use this for chunk meshes
- [x] Remove reference counting and the locks on the chunk storage data
structure
- [x] Measure performance of gathering many light samples and compare it
with master → around 15% reduction in time
- [x] Cleanup some unused things (mesh free list)
2025-07-21 22:20:17 +02:00
IntegratedQuantum
a8470ea78a Always compile with --prominent-compile-errors
So far I couldn't see any downsides from doing this.
2025-07-21 18:37:48 +02:00
IntegratedQuantum
1794515c92 Print modifiers, modifier restrictions and tags in item tooltips.
fixes #1587
2025-07-21 17:07:29 +02:00
codemob
df0af7afbc
Preserve unknown entries in settings (#1696)
Fixes #1675
2025-07-20 23:29:50 +02:00
IntegratedQuantum
7aa35798be Fix chisel behavior for blocks with resistance
Until we have a proper tool for it #760 it should break the corners in one hit independently of resistance
2025-07-20 22:46:37 +02:00
IntegratedQuantum
31d62f77ee Set the selected window to null in toggleGameMenu
This caused a bug when pressing escape instead of left-click to return to the game.

fixes #1691
fixes #1655
2025-07-20 22:41:51 +02:00
IntegratedQuantum
fe687be59f Rename player model to "snale"
fixes #1697
2025-07-20 22:32:53 +02:00
codemob
f2dc3faec2
Place certain blocks on water (#1672)
Fixes #1218

---------

Co-authored-by: IntegratedQuantum <43880493+IntegratedQuantum@users.noreply.github.com>
2025-07-20 11:10:16 +02:00
OneAvargeCoder193
32760169f7
Make the new cactus block craft the cactus arm instead of the old one. (#1694)
fixes #1693
2025-07-20 09:49:38 +02:00
IntegratedQuantum
bd5ea763cb Fix undefined behavior in text rendering (TextBuffer.width was initialized with undefined and never changed for draw.print)
(hopefully) finally fixes #595
2025-07-18 23:59:39 +02:00
IntegratedQuantum
c297fe0dfc Panic before the OpenGL buffer surpasses 2 GiB
fixes #1671
2025-07-18 23:58:29 +02:00
IntegratedQuantum
362f540825 Remove on-demand player inventory loading and fix a possible exploit 2025-07-16 17:22:36 +02:00
IntegratedQuantum
aae66ea77f
Update Zig to use the new Writergate version (#1664)
For reference: https://github.com/ziglang/zig/pull/24329

some commits have been extracted from #1583, but the x86_64 backend has
been disabled due to its horrible performance.

Remaining work:
- [x] Wait for official builds on ziglang.org and upload them to our
repository
- [x] Add workaround for https://github.com/ziglang/zig/pull/24466
- [x] Fix TODO comment about ANSI support in stdout
- [x] Check for compile-time performance changes → it went from 13.1 to
11.9 seconds 🎉
2025-07-15 23:00:29 +02:00
IntegratedQuantum
6811f21682 Don't fetch controller mappings in debug mode, decreasing compile-time by 5 seconds (25%)
see also: https://github.com/ziglang/zig/issues/24435
2025-07-13 21:47:55 +02:00
codemob
684d154a6d
Added invert mouse Y setting (#1666)
Fixes #1296.
2025-07-13 12:19:58 +02:00
IntegratedQuantum
701627fdbf fix formatting 2025-07-10 20:41:17 +02:00
IntegratedQuantum
fc1897de92 Banish those large assets into a separate repository
A first step towards #763 to unblock the addition of large assets.
2025-07-10 20:35:15 +02:00
Krzysztof Wiśniewski
76c0d885a5
QoL changes for creative inventory (#1635)
Although major UI changes are planned, they are expected in rather far
future. Unfortunately current state of creative inventory makes it
really frustrating to use when building and when testing newly added
blocks. Therefore I have implemented a dead simple search bar which
filters out all items with IDs that don't contain the searched phrase. I
also made a sin of (subjectively) improving the look of item list by
padding last row of item list with empty immutable slots if it was not
filled with items found.

![Screenshot 2025-06-20
025239](https://github.com/user-attachments/assets/17f6ca67-fc65-4588-b76e-c5cb0fb65ff1)

![Screenshot 2025-06-20
025312](https://github.com/user-attachments/assets/e7af7498-4415-45d8-a72c-ef155683e91e)

![Screenshot 2025-06-20
025245](https://github.com/user-attachments/assets/6dbf2b30-c075-491a-803f-b1dd92efa49c)
2025-07-07 22:23:33 +02:00
OneAvargeCoder193
ffcdf5e91f
Enable placing logs on transparent blocks (#1660)
fixes #1579
2025-07-07 16:57:05 +02:00
IntegratedQuantum
5a80a2d281
Speed boost when breaking a block based on leftover damage (#1658)
This makes the DPS statistic more accurate and reduces the impact from
off-by-one errors as described in #1643

fixes #1656 

@ikabod-kee please check this out
2025-07-06 21:49:45 +02:00
Krzysztof Wiśniewski
19fe9508d5
Binary Item storage (#1473)
## Description

This pull request implements binary storage for items to allow more
compact storage of inventories for ECS and block entities.

## Links

Depends on: #1494 
Depends on: #1478

---------

Co-authored-by: OneAvargeCoder193 <mgiakimenko@outlook.com>
Co-authored-by: OneAvargeCoder193 <85588535+OneAvargeCoder193@users.noreply.github.com>
Co-authored-by: IntegratedQuantum <43880493+IntegratedQuantum@users.noreply.github.com>
2025-07-06 12:44:42 +02:00
IntegratedQuantum
a8ffa97ebc Buoyancy, volume friction and volume mobility
fixes #83
fixes #84
first prototype of #85
2025-07-05 16:56:29 +02:00
IntegratedQuantum
4b856619b5
Trying out miniaudio (#1652)
It does seem to offer a higher level interface, including spatial audio.

However this proof of concept only uses the low level interface, which
is pretty similar to port audio so far, also performance-wise.
Only technical difference so far seems to be that we can actually deinit
it without crashing.

@ikabod-kee since you got better ears for this, could you check if you
notice anything that got better or worse with this transition?
Particularly, I'd like to know if you notice any improvements with
respect to #571.

Remaining work if accepted:
- [x] Include this in the libs and precompile it instead of adding it
here
- [x] remove portaudio from the libs
- [x] make a new libs release and use it here
- [x] Remove remaining references of portaudio from the source

fixes #415
fixes #571
2025-07-05 11:49:18 +02:00
IntegratedQuantum
dd506e197e Don't allow two players of the same name to join (except from testing worlds)
fixes #1636
2025-07-01 22:47:36 +02:00
Krzysztof Wiśniewski
54aab15a4e
Add SBB rotation parameter (#1530)
## Description

This pull request adds `rotation` parameter to `cubyz:sbb` simple
structure with default value `.random` which allows specifying fixed or
randomized rotation for structures generated. Rotation for structure is
only propagate through the strcuture children only for vertical child
blocks. Additionally, a `rotation` parameter was added to structure
building block children definition to allow overriding / re-enabling
random rotation for children of strcuture. Default value for that
parameter is `inherit` which takes the rotation of parent (only for
vertical child blocks until interrupted). Valid values for rotation are
`0`, `90`, `180`, `270`, `random`, `inherit`, all accepted as a string,
numeric values also accepted as floats and integers.

## Links

Resolves: #1529

---------

Co-authored-by: IntegratedQuantum <43880493+IntegratedQuantum@users.noreply.github.com>
2025-06-28 16:38:36 +02:00
Krzysztof Wiśniewski
254546c789
Use enum instead of packed struct for *Index objects (#1640)
Resolves: #1600

---------

Co-authored-by: IntegratedQuantum <43880493+IntegratedQuantum@users.noreply.github.com>
2025-06-28 15:45:34 +02:00
IntegratedQuantum
24a1fcdc69
Use world-space dithering as well as a better dither matrix to handle transparency in mipmapping/anisotropic filtering (#1641)
- [x] Prototype
- [x] Remove old code
- [x] ~~Apply this form of dithering to other shaders as well (item
drop)~~ → old dither looks better for items and display model
- [x] Can we finally remove the dither seed?
- [x] Check performance impact → it's slightly (insignificantly) faster
even
2025-06-26 20:14:54 +02:00
IntegratedQuantum
ba5711f607 Fix remaining shaders affected by a8b36f3ca450d83e9fd2e903bb998b5f4169b7ad 2025-06-20 22:37:58 +02:00
IntegratedQuantum
a8b36f3ca4 Don't use vector types in the GPU buffer.
I decided to pack the corner positions, everything else would have made it more ugly.

fixes the most relevant part of #1634
2025-06-19 22:04:26 +02:00
Krzysztof Wiśniewski
9c33f8184d
Fix amber ore (#1633)
Amber ore was not adjusted to #1509
2025-06-19 16:46:28 +02:00
IntegratedQuantum
74ceef2902
Use issue forms (#1631)
makes the issue template UI nicer than it is right now

related: #1625
2025-06-18 16:04:21 +02:00
Yiheng Wu
f75f3d40e4
Calculate font unit per pixel dynamically (#1629)
This PR turns font unit per pixel (a "magic number") into actually
computed value. Previously the "font unit per pixel" is hardcoded as
float `4.0`, because `units_per_EM` field of unscii is 64, and default
font size is 16. If another font is loaded, layout will be corrupted by
invalid scaling of `glyphPositions`. Note that only transformation from
font unit to pixel is affected, no visual change is made, and width of
glyph(character) is not changed.
2025-06-18 15:37:50 +02:00
Krzysztof Wiśniewski
fe09535244
Add coniferous trees the way I like them (#1377)
I still need more variants of lushy branches, also the average branch
variants seem a bit bare, too bare IMO, tho maybe these are things we
could tweak later?

![Screenshot 2025-06-02
000603](https://github.com/user-attachments/assets/b190ec37-a897-4373-ade2-da4bd53d761c)
![Screenshot 2025-06-02
000620](https://github.com/user-attachments/assets/4c63b49a-6b74-47a5-aabb-f0731a1b8377)
![Screenshot 2025-06-02
000636](https://github.com/user-attachments/assets/2bb1cbc6-8307-4289-aab7-309faae93f25)
2025-06-17 18:23:47 +02:00
OneAvargeCoder193
4898012311
Use comptime modding for rotation loading (#1509)
Related to: #1507
closes #1533 

I'm pretty sure that the rest of the moving into a comptime mod
interface can be done in a future pr

---------

Co-authored-by: Krzysztof Wiśniewski <argmaster.world@gmail.com>
2025-06-17 18:13:48 +02:00
IntegratedQuantum
b7da179eab
Create issue templates 2025-06-16 19:52:28 +02:00