11509 Commits

Author SHA1 Message Date
0606ca3008
Initial Client Implimented in GUI.
The code is implimented in this commit and is launchable with the BUILD_CLIENT compile option.
Everything should be launchable by running the one function within
src/nyqubel-client/client.hpp: start_nyqubel_client()
2024-02-13 10:47:58 -05:00
88809475cc
Fix a missing include failing to build with a non-unity build 2024-02-13 10:33:47 -05:00
dyexlzc
20d5cf0bfc
fix minecart bugs. (#5516)
* fix minecart bugs.

* Replace magical number in minecart

---------

Co-authored-by: dyexlzc <dyexlzc@gmail.com>
2023-11-20 10:12:52 +00:00
sleirsgoevy
ca705be264
Fix empty chunk serializer for protocol 47 (#5514)
(Minecraft 1.8)

Co-authored-by: Sergey Lisov <sleirsgoevy@gmial.com>
2023-10-18 20:32:02 +00:00
Spongecade
ebeb164d2b
Update Minecraft Wiki links to new domain (#5532)
* Update Minecraft Wiki links to new domain

* Added Spongecade to contributors

* Sorted Spongecade
2023-09-27 20:07:42 +02:00
KingCol13
1d4e036e39
Only enable werror for debug (#5501) 2023-09-27 17:56:25 +00:00
LhAllant
02cb4ef41e
Changed large apple tree probability (#5523) 2023-09-26 21:59:33 +00:00
Debucquoy Anthony tonitch
7db4e20fd7
adding endermite (#5460)
* First Draft of adding endermite

* Update src/Mobs/Endermite.h

Co-authored-by: x12xx12x <44411062+12xx12@users.noreply.github.com>

* Adding Protocols + SpawnEgg

TODO: don't forget to put the endermite in core plugin for the summon
command

* Adding endermite to monster.ini

* Adding 5% change of spawning endermite when throwing enderpearl

* Spawn endermite at last position instead of Hit Position + .cache to .gitignore

* fixup! Spawn endermite at last position instead of Hit Position + .cache to .gitignore

* destroy endermite if 2 min, not if name is set

* Syntax

* Adding Enderman targeting endermite + fixing syntax

* Fixing compile error + return error [but crash on enderman spawn]

* Fix crash but enderman doesn't target

* Enderman targeting endermite finished

* checking style because i'm a noob at git...

* fixup! checking style because i'm a noob at git...

* Added endermite egg meta to docs

* Final touches

Removed unnecesary imports
fixed callback to run only in sight distance and actually check sigtlines

* Fixed error after not pulling branch

---------

Co-authored-by: x12xx12x <44411062+12xx12@users.noreply.github.com>
Co-authored-by: Debucquoy <debucqquoy.anthony@gmail.com>
2023-09-26 21:54:37 +00:00
Mat
a819f37fa1 Update Core 2023-09-26 21:11:04 +03:00
bariscodefx
eda440e0db
Update MCS_CLIENT_VERSIONS (#5529)
* Update MCS_CLIENT_VERSIONS

* Update remaining protocol version macros.

---------

Co-authored-by: Alexander Harkness <me@bearbin.net>
2023-08-21 13:49:46 +02:00
x12xx12x
770d838f37
Added that ds_store file to gitignore (#5521)
* Added that ds_store file to gitignore

* Update .gitignore

Co-authored-by: Janmm14 <Janmm14@users.noreply.github.com>

---------

Co-authored-by: Alexander Harkness <me@bearbin.net>
Co-authored-by: Janmm14 <Janmm14@users.noreply.github.com>
2023-08-15 07:52:42 +00:00
Bond-009
f2c41d1227
Fix tools build on FreeBSD (#5525)
Regession from #5085

```
[ 79%] Building CXX object Tools/ProtoProxy/CMakeFiles/ProtoProxy.dir/Connection.cpp.o
/home/bond/dev/cuberite/Tools/ProtoProxy/Connection.cpp:337:26: error: use of undeclared identifier 'AF_INET'
        m_ServerSocket = socket(AF_INET, SOCK_STREAM, IPPROTO_TCP);
                                ^
/home/bond/dev/cuberite/Tools/ProtoProxy/Connection.cpp:337:35: error: use of undeclared identifier 'SOCK_STREAM'
        m_ServerSocket = socket(AF_INET, SOCK_STREAM, IPPROTO_TCP);
                                         ^
/home/bond/dev/cuberite/Tools/ProtoProxy/Connection.cpp:337:48: error: use of undeclared identifier 'IPPROTO_TCP'
        m_ServerSocket = socket(AF_INET, SOCK_STREAM, IPPROTO_TCP);
                                                      ^
/home/bond/dev/cuberite/Tools/ProtoProxy/Connection.cpp:342:2: error: unknown type name 'sockaddr_in'
        sockaddr_in localhost;
        ^
/home/bond/dev/cuberite/Tools/ProtoProxy/Connection.cpp:343:25: error: use of undeclared identifier 'AF_INET'
        localhost.sin_family = AF_INET;
                               ^
/home/bond/dev/cuberite/Tools/ProtoProxy/Connection.cpp:346:53: error: unknown type name 'sockaddr'
        if (connect(m_ServerSocket, reinterpret_cast<const sockaddr *>(&localhost), sizeof(localhost)) != 0)
                                                           ^
/home/bond/dev/cuberite/Tools/ProtoProxy/Connection.cpp:362:29: error: use of undeclared identifier 'recv'
        int res = static_cast<int>(recv(m_ServerSocket, Buffer, sizeof(Buffer), 0));  // recv returns int on windows, ssize_t on linux
                                   ^
/home/bond/dev/cuberite/Tools/ProtoProxy/Connection.cpp:402:29: error: use of undeclared identifier 'recv'
        int res = static_cast<int>(recv(m_ClientSocket, Buffer, sizeof(Buffer), 0));  // recv returns int on Windows, ssize_t on Linux
                                   ^
/home/bond/dev/cuberite/Tools/ProtoProxy/Connection.cpp:451:29: error: use of undeclared identifier 'send'
        int res = static_cast<int>(send(a_Socket, reinterpret_cast<const char *>(a_Data.data()), a_Data.size(), 0));  // Windows uses int for a_Size, Linux uses size_t; but Windows doesn't complain. Return type is int on Windows and ssize_t on Linux
                                   ^
[ 79%] Building CXX object CMakeFiles/Cuberite.dir/Unity/unity_38_cxx.cxx.o
9 errors generated.
```
2023-08-12 14:41:52 +00:00
Mattes D
7e83dd073e Fixed a wrong format string.
Thanks to dyexlzc for noticing.
2023-06-21 12:08:14 +02:00
Seppe Degryse
4fe144de35
Replaced hand-escaped JSON (#5508) 2023-06-08 08:13:08 +02:00
x12xx12x
5da44fa4b9
Update clang-tidy.sh (#5477) 2023-06-05 20:37:47 +00:00
x12xx12x
26b7e5ad9e
Add Class and Function Identifier Macro (#5481)
This adds a Macro which simply identifies the function and class name for error messages. Examples taken from the MojangAPI class [Choosen because I worked on that]

processing is done during compile time. Should be cross compatible
2023-05-29 16:31:18 +02:00
Mattes D
20f3cb34ae Anvil: Refactored to use shared_ptr. 2023-05-26 23:00:17 +02:00
Mattes D
889eba1df5 Anvil: Allow loading chunks without HeightMap. 2023-05-26 23:00:17 +02:00
Mattes D
c5412becd1 Added cChunkCoords fmtlib formatter. 2023-05-26 23:00:17 +02:00
NiLSPACE
17d5278d59
Added a warning if the webadmin is enabled without any users. (#5499) 2023-05-25 09:34:39 +02:00
x12xx12x
a4668c000c
Updated LTO Check to new standard. (#5476)
The due to LTO the Release build didn't link. The official cmake page suggest it to do it like this
https://cmake.org/cmake/help/latest/module/CheckIPOSupported.html
2023-05-19 16:52:35 +02:00
Niels Breuker
d9aed92fb4 UrlClient: Fixed invalid Content-Length header. 2023-05-19 16:25:12 +02:00
Mattes D
f673e59b21 UrlClientTest: Added tests for root CA verification. 2023-05-19 16:25:12 +02:00
Mattes D
77f3cfbba8 UrlClient: Fixed blocking request's error return value. 2023-05-19 16:25:12 +02:00
Mattes D
ea35d7d23e MojangAPI: Removed an unused TLS root CA. 2023-05-19 16:25:12 +02:00
Mattes D
d9b2833e27 UrlClientTest: Added timeout to all tests. 2023-05-19 16:25:12 +02:00
Mattes D
97c49c6f29 cTCPLink and cUrlClient accept list of trusted root CAs for TLS. 2023-05-19 16:25:12 +02:00
Mattes D
c2e0344110 cTCPLink: Use the original connection hostname for SNI. 2023-05-19 16:25:12 +02:00
x12xx12x
800f1c0bc5 Auth SSL Fixes
- Fixed Login Breaking bug
- Auth and MojangAPI now use UrlClient
- fixed bug in UrlClient where one letter was missing in the HTTP Header
- added function to verify Urls from config files and error handling on bad Urls in config for Auth
2023-05-19 16:25:12 +02:00
Mattes D
c9522fb740 Removed all Printf-family functions from StringUtils.
Replaced them with fmt::format calls, including changes to the format strings. Also changed the format strings to use FMT_STRING, so that the format is checked compile-time against the arguments.
Also fixed code-style violations already present in the code.
2023-05-16 23:50:37 +02:00
Alexander Harkness
15513578c4
Try a timeout for jobs. 2023-04-17 20:35:53 +00:00
Michal Havlíček
669392d44a
Implement slime chunks. (#5484)
* Implement slime chunks.

* add cWorld::IsSlimeChunk

* add documentation for cWorld::IsSlimeChunk
2023-04-08 00:11:10 +02:00
stevenzr
dcad86e776
refactor: removed m_MojangAPI from RankManager (#5483)
* refactor: removed m_MojangAPI from RankManager

* docs: updated CONTRIBUTORS
2023-04-04 22:32:09 +02:00
2b71270b1b
Implimented a few Core Plugin commands
I simply ported a few core commands to C++, it was pretty easy once the
infastructure was setup. Since its already setup for lua, its very easy
to write C++ code that is just as good!

I plan on finishing the Core Commands then/after changing cuberite to
have its compatibility enforcers.
2023-03-29 17:46:41 -04:00
3ac283ad5c
Implimented CMDManager to stand in for the missing PluginManager
Since I ripped out lua, we still need commands for basic existance
within the cube world. I want to live comfortably so I setup the system
to be easily adaptable and added to to make more commands in the future.
2023-03-29 17:40:27 -04:00
x12xx12x
ceaebd00d8
Small Team Creation Fixes (#5479)
- Add additional explanation for team creation
- error message if team creation fails because team already exists

fixes #5466
2023-03-26 22:25:54 +00:00
Jomar Milan
fddbf65e28
Handle newlines in cIniFile (#5447)
* Handle newlines during read and write in cIniFile

When reading the ini file, replace \n with newline. When writing,
replace the newline with \n.

* Use ReplaceString instead of regex in IniFile

* Update cIniFile description

* Removed duplicate variable

* Revert "Removed duplicate variable"

This reverts commit de11bac047d871dfbffec28b72f72a2935bd339e.

* Removed duplicate variable

Now without plugin changes

---------

Co-authored-by: x12xx12x <44411062+12xx12@users.noreply.github.com>
2023-03-22 11:20:59 +01:00
Tiger Wang
c747b4911e
Removed C style arrays from the BlockEntity folder (#5005)
* Removed C style arrays from the BlockEntity folder

* Update for loops with size_t where there are no item grids involved

* Fixed some casts in BrewingstandEntity.cpp

---------

Co-authored-by: bibo38 <bibo38@github.com>
Co-authored-by: x12xx12x <44411062+12xx12@users.noreply.github.com>
2023-03-22 11:20:16 +01:00
1457b3df5b
Removal of Lua and systems that use Lua
I am removing lua specifically because I am not intending on supporting
it on any way. I will manage everything manually in c++, the base is
already there since the entire codebase is built for lua, it can be used
the same way in c++.
This does alienate the type of people that can contribute, this is
intended more as a personal project to attempt matching vanilla
minecraft. Im not intending on running some kind of massive server so
this does just fine.
Lua wasnt even that intertwined with cuberite, but I still want to rid
it for ease of development. Sorry for any hurt feelings.
2023-03-20 17:00:07 -04:00
6c4b2e9186
Implement GPL3+ and Apache2.0 Dual License.
Commit is being made to allow additions of GPL3+ code previously
un-addable. With these changes, contributions back to cuberite are
possible with the backporting exemtion, as well as adding stuff in
minetest with minetest code properly being read through and implimented
to upgrade it to GPL3 from GPL2.

project still has Apache2.0 license and credits to all its contributers, but now has the freedom of GPL3+ and all the code that can be implimented and shared with it.
2023-03-20 11:49:56 -04:00
Mattes D
cb2201daba
Added small embedded devices to README
A nonsense change pretty much only to trigger a rebuild due to missing binaries on the build server.
2023-03-08 09:23:42 +01:00
Michal Havlíček
847884b6a8
TNT minecarts exploding when riding over activator rails (#5469)
* TNT Minecarts exploding via activator rails

* Fuse animation

* Add TNT minecart explosion source to APIDesc
2023-01-25 20:50:08 +00:00
Michal Havlíček
7fdfb86441
Allow certain blocks to be placed on top of upside-down stairs/slabs (#5468)
* Placing certain blocks on top of upside down slabs and stairs

* remove TODO

* fix style errors

* IsAnyStairType helper function

* Block placement on stairs and slabs
2023-01-25 20:46:34 +00:00
Mattes D
b037636756
Changed Windows instructions to build out-of-source. 2022-12-26 16:54:25 +01:00
Tiger Wang
8a763d3bed
MojangAPI: Update certificates (#5456)
* MojangAPI: Update certificates

* Fixes 2115 (again).
* Fixes #4832.

* 🌺
2022-11-18 13:28:21 +00:00
Alexander Harkness
a7f287e572
Remove Travis from GETTING-STARTED.md 2022-11-15 22:48:44 +00:00
Mattes D
70daa63478
Added support for favicons of any filesize. (#5457) 2022-11-09 15:18:05 +00:00
Mattes D
fd36c0493a Fixed nonsensical comment. 2022-11-09 10:32:56 +01:00
Tiger Wang
7a73fd467c
Protocol: Use correct calculation for delta movements (#5455)
* Protocol: Use correct calculation for delta movements
2022-11-08 22:14:45 +00:00
Tiger Wang
5907df6808 Chunk: Optimise idle ticking
* Instead of chunks ticking player objects, and the player object in turn ticking its client handle, let the world tick the client handles. This means we no longer need to maintain a special-case for chunks that shouldn't be ticking, but still need to process players. Partially reverts to the state before 054a89dd.
2022-11-03 00:52:37 +00:00