Commit Graph
24 Commits
Author SHA1 Message Date
Advocaite f2b20d1863 DB updater: accept Windows and Linux hashes, never re-run the baselines (#54)
#52 hashed SQL files with CRLF turned into LF, which fixed Windows-made
databases on Linux but broke databases built on Linux the same way: they
stored the raw hash, so the world baselines looked changed and baseline_01
was re-run. Its first 135 statements reset creature, gameobject, the loot
tables, npc_vendor, creature_trainer, pools and more to the baseline rows,
then player_classlevelstats failed (8 values, the table has 9 columns now)
and the server stopped on every start.

- Either hash (CRLF->LF or raw bytes) means "already applied": the file is
  only re-hashed to the CRLF->LF hash, never run. Renames are matched on
  both hashes. Works for Windows-made, Linux-made and moved databases.
- The world baselines are never applied again: they are a dump of the
  world at their place in the update order and are not safe to re-run on
  a finished database. A changed baseline is logged as an error and
  re-hashed; the "earlier custom file was applied again" cascade skips
  them too.

Tested on Linux with worldserver -u: raw (Linux) hashes stored -> re-hash
only; changed baseline -> error + re-hash, not run; changed custom file ->
re-applied; table checksums unchanged throughout.

A Linux world database already damaged by #52 is best rebuilt (it holds
no player data): DROP DATABASE world and let worldserver set it up again.
2026-10-14 10:01:10 +08:00
Advocaite 691c2362c7 Hosting: Linux server setup, Windows/Linux SQL hash fix, remote hosting docs (#52)
- DB updater: SQL files are hashed with CRLF turned into LF on every
  platform. Text mode did that only on Windows, so files with CRLF bytes
  in their git copy (the world baselines: line breaks inside text strings)
  hashed differently on Linux, and a database made on Windows (dev, repack,
  release dump) re-ran the 65 MB baseline there and failed halfway. The
  hash is the one Windows has always stored, so no existing database sees
  a change. No SQL file contains 0x1A, so text mode's Ctrl+Z stop never
  applied either.
- contrib/linux/configure_server.sh: writes bnetserver.conf and
  worldserver.conf for a public server from the .dist files (bind 0.0.0.0,
  Classic client keys incl. Network.EnterEncryptedModeRegionGroup, which
  the .dist lacks, DB warnings to file only)
- doc/LinuxServerSetup.md: setup of a clean Ubuntu 24.04 server (4 GB
  droplet, 48 min build, no GCC errors), tested by logging in from a home
  PC, with every problem found on the way
- README: "Hosting for other players" checklist (BindIP, realm address,
  hosts entry on the server too, per-player CA trust, ports), the repack's
  host-for-others.bat, and the dead ServerGuide.md link replaced
2026-10-14 00:47:23 +08:00
Advocaite d0dde7b468 Classic 1.60: Zephras story quests, SQL updater rewrite, companion pets, gathering and combat fixes
Story and world
- Scripted Zephras story chain: Talaanis crystal scene, Valennia muster, the Ayessa spire battle (Lorthuna, Rohash, storms, rift, portal back to Valanaar), Rohashi winds launch, secluded house, injured cave druids
- Phases and quest chain fixes (Prepare for Battle, Confront Lorthuna, The Fate of Zephras), Al'Aketh hill fight, peacekeeper/Ayessa factions
- Talk-to quest objectives credit on gossip and questgiver hello
- Phase shift flags are 1 byte (client crash accepting Prepare for Battle)
- Reputation: Classic standing packet (change field), no reputation for the other side's faction
- Wisps fly (Floating), inns rested (6 missing vanilla taverns, server side inn triggers on Zephras)
- Teleports for every new Forever map

Database updater
- Applies SQL over its own multi statement connection (the mysql client silently stopped reading files)
- Reapplies every later custom file once an earlier one is reapplied
- No apostrophes in SQL comments; reapplied the fixes the sniff import had undone

Professions and items
- Skinning loot for Zephras beasts, skill-ups for herbalism, mining and skinning (no parent skill line, no content tuning)
- Vanilla chests (herbs, veins, treasure) consumed on loot (ChestFlags)
- Profession books 247840/247841/247846, gathering extras (Pristine Leather, Frilled Lichen, Pyrite, seeds)
- Companion pets: journal packet (Classic int64), creatures and models for the new Forever pets
- .legacy points command to test the Legacy trees

Combat
- Player, pet and trap spells use flat base points (Scorch), vanilla 14 AP per DPS
- Spell crits 150%, no extra spell crit against lower level targets
2026-10-05 08:01:14 +08:00
Shauren dcb2857f38 Core/Database: Update PCH content to include most commonly used headers 2025-06-11 20:41:47 +02:00
Shauren b288fceb79 Core/Updater: Fix gcc warning 2024-05-06 00:38:05 +02:00
Shauren cfa838df5d Core/Misc: Support boost 1.85 2024-04-22 11:52:58 +02:00
Shauren d791afae1d Core/Logging: Switch from fmt::sprintf to fmt::format (c++20 standard compatible api) 2023-01-08 21:16:53 +01:00
Peter Keresztes Schmidt ad340466d0 Misc: Use [[fallthrough]] attribute instead of comment to mark intentional fallthroughs (#25054)
Related: #25006
(cherry picked from commit 85b5b842ca6c05d4e51081e6c3282940a80f3761)
2022-01-23 22:02:03 +01:00
Shauren b231903932 Core/Misc: Port all the refactors sneaked in master to 3.3.5 include cleanup port 2020-09-04 13:38:24 +02:00
Treeston e9392ad287 Core/Authserver: Authserver cleanup (PR#25093)
- Fix a handful of 1/256 bugs with most significant byte zero in BigNumber
- Get rid of (most of) the C-style arrays in authserver
- CryptoRandom as a unified source for cryptographic randomness
- Bring our other crypto APIs into 2020
- BigNumber usability improvements
- Authserver is now actually readable as a result of all of the above

(cherry picked from commit 210176fd915cf4ba16f428d3c1a249a71f4aa7a7)
2020-08-03 19:39:00 +02:00
Peter Keresztes Schmidt bab5fd87a3 Core/Misc: Replace Trinity::make_unique with std (#24869) 2020-06-23 08:54:12 +02:00
Shauren 4d69cc1c56 Core/Misc: GCC build and warning fixes 2020-05-21 22:15:58 +02:00
Aokromes b0bf1275ee New Year 2020-01-02 06:44:10 +01:00
vincent-michael 5620eb9463 Update copyright note for 2019
auto happy = new year(2019);
2019-01-01 10:14:33 +01:00
vincent-michael 7d00ae4045 Update copyright note for 2018
auto happy = new year(2018);
2018-01-01 00:40:17 +01:00
Shauren 7e538980a2 Core/Database: Include cleanup 2017-05-12 18:50:27 +02:00
vincent-michael 86b98686a9 Update copyright note for 2017
Happy new year
2017-01-01 16:23:13 +01:00
Trond B Krokli 186375d997 Core/DB/Updater: English grammar corrections (#17207)
Improve English text in strings and comments in UpdateFetcher.cpp
- replace incorrect text with the intended words in some output strings
- corrections in the comments to point out the intention of the code
2016-05-29 15:06:07 +01:00
Naios a679829050 Core/Cryptography: Move the SHA1 calculate helper to the SHA1 header
(cherry picked from commit 3271f328de35f940f682a0dbe1d9466e29190182)
2016-04-18 22:11:16 +02:00
Shauren 70412e7e25 Core/Misc: MSVC warning fixes 2016-04-05 00:15:56 +02:00
Naios c43b808665 Core/Updater: Convert an assertion into a fatal error
* The error is triggered when it fails to open an update for hashing
* See 'https://community.trinitycore.org/topic/12352-worldserver-crashes-on-database-update/'
  for details
* And a minor cleanup in the UpdateFetcher
2016-02-21 15:52:50 +01:00
Naios 716c952cb9 Core/Updater: Use a different method for file reading
* Current method causes issues under CentOS 6 and could possibly
  lead to cutted buffer content when reading in textmode.
* Closes #16209

(cherry picked from commit ae1a5c6c2b82918850cb7b851e2f7dff33a40c57)
2016-02-20 20:32:34 +01:00
Vincent-Michael 478cc756eb Update copyright note for 2016
Happy new year (Again new year with idiots ...)
2016-01-01 00:34:25 +01:00
StormBytePP 1d2aafd39b Core/Build: Merge common library and move database out of shared 2015-08-21 17:52:42 +02:00